summaryrefslogtreecommitdiff
path: root/init
diff options
context:
space:
mode:
authorAlexander M Pickering <alex@cogarr.net>2024-11-22 13:07:01 -0600
committerAlexander M Pickering <alex@cogarr.net>2024-11-22 13:07:01 -0600
commitb58292174e9efa683a32c350efbd1bde2921fd60 (patch)
tree0bbcfc3fc7ff90218033a4549e85c30fb607798b /init
parent7d45715c41e141b819d5d0c6c94fbb2521fc64c7 (diff)
downloadlua-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-xinit27
1 files changed, 27 insertions, 0 deletions
diff --git a/init b/init
index 642d265..3f9af63 100755
--- a/init
+++ b/init
@@ -1 +1,28 @@
1#!/bin/sh -ex 1#!/bin/sh -ex
2
3cd lua-compat-5.3
4cp rockspecs/compat53-scm-1.rockspec .
5cp rockspecs/bit32-scm-1.rockspec .
6luarocks config variables.CFLAGS " $CFLAGS"
7luarocks make --pack-binary-rock compat53-scm-1.rockspec
8luarocks make --pack-binary-rock bit32-scm-1.rockspec
9obj1="compat53-scm-1.$(luarocks config arch).rock"
10obj2="bit32-scm-1.$(luarocks config arch).rock"
11cp $obj1 /root
12cp $obj2 /root
13cd /root
14if [ -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
28fi