mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-08 21:00:05 +02:00
59 lines
1.4 KiB
Bash
59 lines
1.4 KiB
Bash
SUMMARY="Generate Your Projects (GYP) is a build automation tool"
|
|
DESCRIPTION="GYP is created by Google to generate native IDE project files \
|
|
(such as Visual Studio and Xcode) for building the Chromium web browser."
|
|
HOMEPAGE="https://gyp.gsrc.io/"
|
|
COPYRIGHT="2009 Google Inc."
|
|
LICENSE="BSD (3-clause)"
|
|
REVISION="2"
|
|
srcGitRev="c6d8b9f7ee355cff1531b0f369cd338a50baeb07"
|
|
SOURCE_URI="https://github.com/chromium/gyp/archive/$srcGitRev.tar.gz"
|
|
CHECKSUM_SHA256="b4be9a3baccc2d0457aa24e56d96eb703263b7ff7323ecce9177b75385fdfd88"
|
|
SOURCE_DIR="gyp-$srcGitRev"
|
|
PATCHES="gyp-$portVersion.patchset"
|
|
|
|
ARCHITECTURES="any"
|
|
|
|
pythonVersion=3.10
|
|
pyVer=${pythonVersion//.}
|
|
|
|
PROVIDES="
|
|
gyp = $portVersion
|
|
cmd:gyp = $portVersion
|
|
"
|
|
REQUIRES="
|
|
haiku
|
|
six_python$pyVer
|
|
cmd:python3
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku_devel
|
|
setuptools_python$pyVer
|
|
"
|
|
BUILD_PREREQUIRES="
|
|
cmd:python3
|
|
"
|
|
|
|
PATCH()
|
|
{
|
|
# Some day, python will mean python3. Not yet thou, so we patch all the things!
|
|
find ./ -name '*.py' -type f -print0 | xargs -0 sed -i 's|#!/usr/bin/env python|#!/bin/python3|'
|
|
find ./ -name '*.py' -type f -print0 | xargs -0 sed -i 's|#!/usr/bin/python|#!/bin/python3|'
|
|
find ./ -name '*.py' -type f -print0 | xargs -0 sed -i 's|python -c|python3 -c|'
|
|
}
|
|
|
|
BUILD()
|
|
{
|
|
python3 setup.py build
|
|
}
|
|
|
|
INSTALL()
|
|
{
|
|
installLocation=$prefix/lib/python$pythonVersion/vendor-packages/
|
|
export PYTHONPATH=$installLocation:$PYTHONPATH
|
|
mkdir -p $installLocation
|
|
|
|
python3 setup.py install \
|
|
--prefix=$prefix
|
|
}
|