pantry/projects/mesonbuild.com/package.yml
2022-09-14 17:45:56 -04:00

48 lines
1.1 KiB
YAML

distributable:
url: https://github.com/mesonbuild/meson/releases/download/{{ version }}/meson-{{ version }}.tar.gz
strip-components: 1
versions:
github: mesonbuild/meson/tags
dependencies:
python.org: 3
gnu.org/bash: '>=2' # for our venv/relocation scripts: feel free to fix that
build:
script: |
python3 -m venv {{prefix}}/libexec
cd "{{prefix}}"
libexec/bin/pip install -v --no-deps --no-binary :all: --ignore-installed meson
mkdir bin
mv libexec/bin/meson libexec/bin/meson.py
cd bin
ln -s ../libexec/bin/meson meson
cd ../libexec/bin
fix-shebangs.ts *
cp {{ pkg.pantry-prefix}}/shim meson
rm Activate.ps1 activate.csh activate.fish
sed -i.bak 's|VIRTUAL_ENV=".*"|VIRTUAL_ENV="$(cd "$(dirname "${BASH_SOURCE[0]}")"/.. \&\& pwd)"|' activate
rm activate.bak
for x in python*; do
ln -sf ../../../../python.org/v3/bin/$x $x
done
#FIXME tea provides: {{ deps.python.org.version.major }}
test:
dependencies:
ninja-build.org: 1
tea.xyz/gx/cc: c99
script: |
meson ..
test -f build.ninja
working-directory: build