Ravenports generated: 26 Nov 2019 23:39
[ravenports.git] / bucket_CF / lua53
1 # Buildsheet autogenerated by ravenadm tool -- Do not edit.
2
3 NAMEBASE=               lua53
4 VERSION=                5.3.5
5 KEYWORDS=               lang
6 VARIANTS=               standard
7 SDESC[standard]=        Light, powerful language for app. extension
8 HOMEPAGE=               http://www.lua.org/
9 CONTACT=                nobody
10
11 DOWNLOAD_GROUPS=        main
12 SITES[main]=            http://www.lua.org/ftp/
13 DISTFILE[1]=            lua-5.3.5.tar.gz:main
14 DF_INDEX=               1
15 SPKGS[standard]=        single
16
17 OPTIONS_AVAILABLE=      none
18 OPTIONS_STANDARD=       none
19
20 USES=                   readline
21
22 DISTNAME=               lua-5.3.5
23
24 LICENSE=                MIT:single
25 LICENSE_FILE=           MIT:{{WRKDIR}}/LICENSE
26 LICENSE_SCHEME=         solo
27
28 FPC_EQUIVALENT=         lang/lua53
29
30 BUILD_WRKSRC=           {{WRKSRC}}/src
31 MAKE_ARGS=              MYCFLAGS="{{CFLAGS}} {{CPPFLAGS}}"
32                         MYLDFLAGS="{{LDFLAGS}}"
33                         MYLIBS="-L{{LOCALBASE}}/lib -lreadline"
34                         CC="{{CC}}"
35                         ARFLAGS=rl
36                         LUA_T=lua53
37                         LUAC_T=luac53
38                         LUA_A=liblua-5.3.a
39                         LUALIB=liblua-5.3
40                         LUA_SO=liblua-5.3.{{LIBEXT}}
41                         LUA_SONAME=liblua-5.3.{{LIBEXT}}
42                         TO_BIN="lua53 luac53"
43                         TO_LIB="liblua-5.3.a liblua-5.3.{{LIBEXT}}"
44                         INSTALL_TOP={{STAGEDIR}}{{PREFIX}}
45                         INSTALL_INC={{STAGEDIR}}{{PREFIX}}/include/lua53
46                         INSTALL_EXEC="{{INSTALL_PROGRAM}}"
47
48 PLIST_SUB=              LUA_VER=5.3
49                         SUFFIX=53
50 SUB_FILES=              lua-5.3.pc
51 SUB_LIST=               version=5.3.5
52                         includedir={{PREFIX}}/include/lua53
53                         libdir={{PREFIX}}/lib
54                         soname=lua-5.3
55
56 CFLAGS=                 -fPIC
57 LDFLAGS=                -lm
58                         -pthread
59
60 post-patch:
61         ${REINPLACE_CMD} -e 's,rand *(,random(,g' ${WRKSRC}/src/lmathlib.c
62         ${REINPLACE_CMD} -e "/LUA_ROOT/s|/usr/local|${PREFIX}|" \
63                 ${WRKSRC}/src/luaconf.h ${WRKSRC}/src/lua.c
64         ${REINPLACE_CMD} -e 's|man/man1|share/man/man1|' ${WRKSRC}/Makefile
65
66 post-install:
67         ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/liblua-5.3.${LIBEXT}
68         ${MV} ${STAGEDIR}${MANPREFIX}/man/man1/lua.1 \
69                 ${STAGEDIR}${MANPREFIX}/man/man1/lua53.1
70         ${MV} ${STAGEDIR}${MANPREFIX}/man/man1/luac.1 \
71                 ${STAGEDIR}${MANPREFIX}/man/man1/luac53.1
72         ${INSTALL_DATA} ${WRKDIR}/lua-5.3.pc \
73                 ${STAGEDIR}${PREFIX}/lib/pkgconfig
74
75 post-extract:
76         ${AWK} '/\/\*\*/ {start=1} /^$$/{start=0} {if (start) print}' \
77                 ${WRKSRC}/src/lua.h > ${WRKDIR}/LICENSE
78
79 [FILE:1209:descriptions/desc.single]
80 Lua is a programming language originally designed for extending
81 applications, but also frequently used as a general-purpose, stand-alone
82 language. Lua combines simple procedural syntax (similar to Pascal) with
83 powerful data description constructs based on associative arrays and
84 extensible semantics. Lua is dynamically typed, interpreted from bytecodes,
85 and has automatic memory management with garbage collection, making it
86 ideal for configuration, scripting, and rapid prototyping.
87
88 A fundamental concept in the design of Lua is to provide meta-mechanisms
89 for implementing features, instead of providing a host of features directly
90 in the language. For example, although Lua is not a pure object-oriented
91 language, it does provide meta-mechanisms for implementing classes and
92 inheritance. Lua's meta-mechanisms bring an economy of concepts and keep
93 the language small, while allowing the semantics to be extended in
94 unconventional ways. Extensible semantics is a distinguishing feature of
95 Lua.
96
97 Lua is implemented as a small library of C functions, written in ANSI C,
98 and compiles unmodified in all known platforms. The implementation goals
99 are simplicity, efficiency, portability, and low embedding cost.
100
101
102 [FILE:95:distinfo]
103 0c2eed3f960446e1a3e4b9a1ca2f3ff893b6ce41942cf54d5dd59ab4b3b058ac       303543 lua-5.3.5.tar.gz
104
105
106 [FILE:299:manifests/plist.single]
107 bin/
108  lua%%SUFFIX%%
109  luac%%SUFFIX%%
110 include/lua%%SUFFIX%%/
111  lauxlib.h
112  lua.h
113  lua.hpp
114  luaconf.h
115  lualib.h
116 lib/
117  liblua-%%LUA_VER%%.a
118  liblua-%%LUA_VER%%.so
119 lib/pkgconfig/lua-%%LUA_VER%%.pc
120 share/man/man1/
121  lua%%SUFFIX%%.1.gz
122  luac%%SUFFIX%%.1.gz
123 @dir lib/lua/%%LUA_VER%%
124 @dir share/lua/%%LUA_VER%%
125
126
127 [FILE:1227:patches/patch-src_Makefile]
128 --- src/Makefile.orig   2018-06-25 17:46:36 UTC
129 +++ src/Makefile
130 @@ -6,12 +6,12 @@
131  # Your platform. See PLATS for possible values.
132  PLAT= none
133  
134 -CC= gcc -std=gnu99
135 -CFLAGS= -O2 -Wall -Wextra -DLUA_COMPAT_5_2 $(SYSCFLAGS) $(MYCFLAGS)
136 +CC?= gcc -std=gnu99
137 +CFLAGS= -Wall -Wextra -DLUA_COMPAT_5_2 $(SYSCFLAGS) $(MYCFLAGS)
138  LDFLAGS= $(SYSLDFLAGS) $(MYLDFLAGS)
139  LIBS= -lm $(SYSLIBS) $(MYLIBS)
140  
141 -AR= ar rcu
142 +AR= ar
143  RANLIB= ranlib
144  RM= rm -f
145  
146 @@ -19,8 +19,8 @@ SYSCFLAGS=
147  SYSLDFLAGS=
148  SYSLIBS=
149  
150 -MYCFLAGS=
151 -MYLDFLAGS=
152 +MYCFLAGS?=
153 +MYLDFLAGS?=
154  MYLIBS=
155  MYOBJS=
156  
157 @@ -43,7 +43,7 @@ LUAC_T=       luac
158  LUAC_O=        luac.o
159  
160  ALL_O= $(BASE_O) $(LUA_O) $(LUAC_O)
161 -ALL_T= $(LUA_A) $(LUA_T) $(LUAC_T)
162 +ALL_T= $(LUA_A) $(LUA_T) $(LUAC_T) $(LUA_SO)
163  ALL_A= $(LUA_A)
164  
165  # Targets start here.
166 @@ -55,8 +55,14 @@ o:   $(ALL_O)
167  
168  a:     $(ALL_A)
169  
170 +$(LUALIB).so: $(CORE_O) $(LIB_O)
171 +       $(CC) -o $@ $(CFLAGS) $(LDFLAGS) $(MYLDFLAGS) -shared -Wl,-soname=$(LUA_SONAME) $?
172 +
173 +$(LUALIB).dylib: $(CORE_O) $(LIB_O)
174 +       $(CC) -o $@ $(CFLAGS) $(LDFLAGS) $(MYLDFLAGS) -dynamiclib -current_version 1.0 -install_name '$(PREFIX)/lib/$(LUA_SONAME)' $?
175 +
176  $(LUA_A): $(BASE_O)
177 -       $(AR) $@ $(BASE_O)
178 +       $(AR) $(ARFLAGS) $@ $(BASE_O)
179         $(RANLIB) $@
180  
181  $(LUA_T): $(LUA_O) $(LUA_A)
182
183
184 [FILE:186:patches/patch-src__liolib.c]
185 --- src/liolib.c.orig   2015-04-03 18:41:57 UTC
186 +++ src/liolib.c
187 @@ -16,6 +16,7 @@
188  #include <stdio.h>
189  #include <stdlib.h>
190  #include <string.h>
191 +#include <unistd.h>
192  
193  #include "lua.h"
194  
195
196
197 [FILE:217:files/lua-5.3.pc.in]
198 version=%%version%%
199 libdir=%%libdir%%
200 includedir=%%includedir%%
201 soname=%%soname%%
202
203 Name: Lua
204 Description: An Extensible Extension Language
205 Version: ${version}
206 Libs: -L${libdir} -l${soname} -lm
207 Cflags: -I${includedir}
208
209
210 [FILE:309:files/special.mk]
211 .if ${OPSYS} == "FreeBSD"
212 BUILD_TARGET=   bsd     # was 'freebsd'
213 .elif !empty(OPSYS:M*BSD*) || ${OPSYS} == "DragonFly"
214 BUILD_TARGET=   bsd
215 .elif ${OPSYS} == "Linux"
216 BUILD_TARGET=   linux
217 .elif ${OPSYS} == "Darwin"
218 BUILD_TARGET=   macosx
219 .elif ${OPSYS} == "SunOS"
220 BUILD_TARGET=   solaris
221 .else
222 BUILD_TARGET=   generic
223 .endif
224