mirror of
https://github.com/ivabus/pantry
synced 2025-06-08 08:20:32 +03:00
(mostly) fix relocation of perl (#125)
This commit is contained in:
parent
c0356585df
commit
e9aa4edbc7
2 changed files with 22 additions and 6 deletions
|
@ -14,22 +14,38 @@ build:
|
|||
script: |
|
||||
./Configure $ARGS
|
||||
make --jobs {{ hw.concurrency }} install
|
||||
|
||||
# TODO not complete some parts are still not relocatable
|
||||
cd "{{prefix}}"/bin
|
||||
for x in *; do
|
||||
case $x in
|
||||
perl|perl{{version}})
|
||||
;;
|
||||
*)
|
||||
sed -i.bak 's|^#!{{prefix}}/bin/|#!/usr/bin/env |' $x
|
||||
sed -i.bak 's|exec {{prefix}}/bin/|exec |' $x
|
||||
esac
|
||||
done
|
||||
|
||||
rm -f {{prefix}}/bin/*.bak
|
||||
|
||||
# relocatable fixes from: https://github.com/skaji/relocatable-perl
|
||||
|
||||
env:
|
||||
ARGS:
|
||||
- -d # use defaults
|
||||
- -e # non interactive
|
||||
- -Dprefix={{prefix}}
|
||||
- -Duseshrplib
|
||||
- -Duselargefiles
|
||||
- -Dusethreads
|
||||
# we don’t want versioned, platformed prefixes
|
||||
#NOTE maybe this will break something though…
|
||||
- -Dprivlib={{prefix}}/lib
|
||||
- -Darchlib={{prefix}}/lib
|
||||
- -Duseshrplib=false
|
||||
# makes perl “more” relocatable
|
||||
- -Duserelocatableinc
|
||||
|
||||
test:
|
||||
script: |
|
||||
perl $FIXTURE
|
||||
shasum --version
|
||||
fixture: |
|
||||
print 'Perl is not an acronym, but JAPH is a Perl acronym!'
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@ args:
|
|||
- --allow-net
|
||||
- --allow-run
|
||||
- --allow-read
|
||||
- --allow-write=/opt
|
||||
- --allow-write={{tea.prefix}}
|
||||
- --allow-env
|
||||
- --import-map={{ srcroot }}/import-map.json
|
||||
---*/
|
||||
|
|
Loading…
Reference in a new issue