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