Ncurses fix paths & test (#3121)

* fix hardcoded paths

* test

* dirname "$0"
This commit is contained in:
Andrew 2023-08-27 00:39:12 +03:00 committed by GitHub
parent 0441e7d8ad
commit fbba37b856
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -31,6 +31,13 @@ build:
rmdir ncursesw rmdir ncursesw
ln -sf . ncursesw ln -sf . ncursesw
# fix hardcoded paths
sed -i.bak 's|{{prefix}}|\${pcfiledir}/../..|g' {{prefix}}/lib/pkgconfig/*.pc
rm {{prefix}}/lib/pkgconfig/*.bak
sed -i.bak 's|{{prefix}}|\$(dirname "\$0")/..|g' {{prefix}}/bin/ncursesw{{version.major}}-config
rm {{prefix}}/bin/ncursesw{{version.major}}-config.bak
env: env:
PCDIR: ${{prefix}}/lib/pkgconfig PCDIR: ${{prefix}}/lib/pkgconfig
ARGS: ARGS:
@ -50,7 +57,13 @@ runtime:
# ^^ we delegate to the system first since they may apply platform specific info # ^^ we delegate to the system first since they may apply platform specific info
test: test:
script: true #FIXME dependencies:
freedesktop.org/pkg-config: ^0.29
script: |
ncursesw6-config --version | grep {{version.marketing}}
ncursesw6-config --terminfo-dirs | grep '{{prefix}}'
pkg-config --modversion ncursesw | grep {{version.marketing}}
pkg-config --libs ncursesw | grep '{{prefix}}'
provides: provides:
- bin/captoinfo - bin/captoinfo