-
Notifications
You must be signed in to change notification settings - Fork 290
/
Copy pathlua5.3.yaml
123 lines (104 loc) · 2.97 KB
/
lua5.3.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
package:
name: lua5.3
version: 5.3.6
epoch: 4
description: "powerful lightweight programming language"
copyright:
- license: MIT
environment:
contents:
packages:
- autoconf
- automake
- build-base
- busybox
- ca-certificates-bundle
- libtool
- linenoise-dev
pipeline:
- uses: fetch
with:
uri: https://www.lua.org/ftp/lua-${{package.version}}.tar.gz
expected-sha256: fc5fd69bb8736323f026672b1b7235da613d7177e72558893a0bdcd320466d60
- uses: patch
with:
patches: lua-5.3-make.patch
- uses: patch
with:
patches: lua-5.3-module_paths.patch
- uses: patch
with:
patches: linenoise.patch
- runs: |
cat >configure.ac <<-EOF
top_builddir=.
AC_INIT(src/luaconf.h)
AC_PROG_LIBTOOL
AC_OUTPUT
EOF
libtoolize --force --install
aclocal
autoconf
sed -i '/#define LUA_USE_READLINE/d' src/luaconf.h
- runs: |
./configure --prefix=/usr
- runs: |
make -C src V=5.3 \
CFLAGS="$CFLAGS -DLUA_USE_LINUX -DLUA_COMPAT_5_2 -DLUA_USE_LINENOISE" \
SYSLDFLAGS="$LDFLAGS" \
RPATH="/usr/lib" \
LIB_LIBS="-lpthread -lm -ldl -llinenoise" \
alpine_all
- runs: |
make V=5.3 \
INSTALL_TOP="${{targets.destdir}}"/usr \
INSTALL_INC="${{targets.destdir}}"/usr/include/lua5.3 \
INSTALL_LIB="${{targets.destdir}}"/usr/lib/lua5.3 \
alpine_install
chmod 755 "${{targets.destdir}}"/usr/lib/lua5.3/*.so*
- runs: |
for i in "${{targets.destdir}}"/usr/bin/* ; do
mv "$i" "$i"5.3
done
for i in "${{targets.destdir}}"/usr/lib/lua5.3/*.so.*; do
ln -s lua5.3/${i##*/} "${{targets.destdir}}"/usr/lib/${i##*/}
done
for i in lua luac; do
install -D -m 644 doc/$i.1 "${{targets.destdir}}"/usr/share/man/man1/"$i""$_luaver".1
done
install -d "${{targets.destdir}}"/usr/lib/pkgconfig
cat > "${{targets.destdir}}"/usr/lib/pkgconfig/lua5.3.pc <<-EOF
# lua.pc -- pkg-config data for Lua
V=5.3
R=${{package.version}}
prefix=/usr
INSTALL_BIN=\${prefix}/bin
INSTALL_INC=\${prefix}/include
INSTALL_LIB=\${prefix}/lib
INSTALL_MAN=\${prefix}/man/man1
INSTALL_LMOD=\${prefix}/share/lua/\${V}
INSTALL_CMOD=\${prefix}/lib/lua/\${V}
exec_prefix=\${prefix}
libdir=\${exec_prefix}/lib/${{package.name}}
includedir=\${exec_prefix}/include/${{package.name}}
Name: Lua
Description: An extensible extension language
Version: ${{package.version}}
Requires:
Libs: -L\${libdir} -llua -lm
Cflags: -I\${includedir}
EOF
- uses: strip
subpackages:
- name: "lua5.3-doc"
description: "lua documentation"
pipeline:
- uses: split/manpages
- name: "lua5.3-dev"
description: "lua development headers"
pipeline:
- uses: split/dev
update:
enabled: true
release-monitor:
identifier: 328511