diff options
| author | Alexander M Pickering <alex@cogarr.net> | 2024-11-22 13:07:01 -0600 |
|---|---|---|
| committer | Alexander M Pickering <alex@cogarr.net> | 2024-11-22 13:07:01 -0600 |
| commit | b58292174e9efa683a32c350efbd1bde2921fd60 (patch) | |
| tree | 0bbcfc3fc7ff90218033a4549e85c30fb607798b /init | |
| parent | 7d45715c41e141b819d5d0c6c94fbb2521fc64c7 (diff) | |
| download | lua-compat-53-packaging-b58292174e9efa683a32c350efbd1bde2921fd60.tar.gz lua-compat-53-packaging-b58292174e9efa683a32c350efbd1bde2921fd60.tar.bz2 lua-compat-53-packaging-b58292174e9efa683a32c350efbd1bde2921fd60.zip | |
Start working on 53 compat
Diffstat (limited to 'init')
| -rwxr-xr-x | init | 27 |
1 files changed, 27 insertions, 0 deletions
| @@ -1 +1,28 @@ | |||
| 1 | #!/bin/sh -ex | 1 | #!/bin/sh -ex |
| 2 | |||
| 3 | cd lua-compat-5.3 | ||
| 4 | cp rockspecs/compat53-scm-1.rockspec . | ||
| 5 | cp rockspecs/bit32-scm-1.rockspec . | ||
| 6 | luarocks config variables.CFLAGS " $CFLAGS" | ||
| 7 | luarocks make --pack-binary-rock compat53-scm-1.rockspec | ||
| 8 | luarocks make --pack-binary-rock bit32-scm-1.rockspec | ||
| 9 | obj1="compat53-scm-1.$(luarocks config arch).rock" | ||
| 10 | obj2="bit32-scm-1.$(luarocks config arch).rock" | ||
| 11 | cp $obj1 /root | ||
| 12 | cp $obj2 /root | ||
| 13 | cd /root | ||
| 14 | if [ -z $(echo $CFLAGS | grep -o -E -- '( |^)-g( |$)') ]; then | ||
| 15 | # Release build, delete docs/ and tests/ | ||
| 16 | zip -d $obj1 docs/ docs/* tests/ tests/* | ||
| 17 | zip -d $obj2 docs/ docs/* tests/ tests/* | ||
| 18 | # And pack the library with upx | ||
| 19 | unzip $obj1 lib/* | ||
| 20 | upx --no-progress lib/* | ||
| 21 | zip -r "$obj1" lib | ||
| 22 | rm -rf lib | ||
| 23 | |||
| 24 | unzip $obj2 lib/* | ||
| 25 | upx --no-progress lib/* | ||
| 26 | zip -r "$obj2" lib | ||
| 27 | rm -rf lib | ||
| 28 | fi | ||
