Lines 2-31
Link Here
|
2 |
# $FreeBSD: head/lang/tolua/Makefile 384105 2015-04-16 12:40:15Z bapt $ |
2 |
# $FreeBSD: head/lang/tolua/Makefile 384105 2015-04-16 12:40:15Z bapt $ |
3 |
|
3 |
|
4 |
PORTNAME= tolua |
4 |
PORTNAME= tolua |
5 |
PORTVERSION= 5.2.0 |
5 |
PORTVERSION= 5.2.4 |
6 |
CATEGORIES= lang |
6 |
CATEGORIES= lang |
7 |
MASTER_SITES= http://www.tecgraf.puc-rio.br/~celes/tolua/ \ |
7 |
MASTER_SITES= http://www.tecgraf.puc-rio.br/~celes/tolua/ \ |
8 |
ftp://ftp.tecgraf.puc-rio.br/pub/users/celes/tolua/ |
8 |
ftp://ftp.tecgraf.puc-rio.br/pub/users/celes/tolua/ |
9 |
|
9 |
|
10 |
MAINTAINER= ports@FreeBSD.org |
10 |
MAINTAINER= ports@FreeBSD.org |
11 |
COMMENT= toLua: accessing C/C++ code from Lua |
11 |
COMMENT= Tool to integrate C/C++ code with Lua |
12 |
|
12 |
|
13 |
USES= gmake lua |
13 |
USES= gmake lua pkgconfig |
14 |
|
14 |
MAKE_ARGS= CC="${CC}" CCPP="${CXX}" WARN="-Wall" \ |
15 |
MAKE_ARGS= CC="${CC}" CCPP="${CXX}" \ |
15 |
INC="${CPPFLAGS}" LIB="${LDFLAGS}" \ |
16 |
LUAINC="${LUA_INCDIR}" \ |
16 |
CFLAGS="${CFLAGS} ${CPPFLAGS}" \ |
17 |
LUALIB="${LUA_LIBDIR}" \ |
17 |
CPPFLAGS="${CXXFLAGS} ${CPPFLAGS}" |
18 |
WARN="${CFLAGS}" |
18 |
|
|
|
19 |
CPPFLAGS+= -I${WRKSRC}/include \ |
20 |
$$(pkg-config --cflags lua-${LUA_VER}) |
21 |
LDFLAGS+= -L${WRKSRC}/lib \ |
22 |
$$(pkg-config --libs lua-${LUA_VER}) |
19 |
|
23 |
|
20 |
post-patch: |
24 |
post-patch: |
21 |
@${REINPLACE_CMD} -e 's|make|$${MAKE}|' ${WRKSRC}/${MAKEFILE} |
25 |
@${REINPLACE_CMD} -e \ |
22 |
@${REINPLACE_CMD} -e 's|llua|llua-${LUA_VER}|' \ |
26 |
's|cd \(.*\); make|$${MAKE} -C \1|' ${WRKSRC}/Makefile |
23 |
${WRKSRC}/src/bin/${MAKEFILE} \ |
27 |
@${REINPLACE_CMD} -e \ |
24 |
${WRKSRC}/src/tests/${MAKEFILE} |
28 |
's|-llua||' ${WRKSRC}/src/bin/Makefile |
|
|
29 |
@${REINPLACE_CMD} -e \ |
30 |
's|-llua||' ${WRKSRC}/src/tests/Makefile |
25 |
|
31 |
|
26 |
do-install: |
32 |
do-install: |
27 |
${INSTALL_PROGRAM} ${WRKSRC}/bin/tolua ${STAGEDIR}${PREFIX}/bin |
33 |
(cd ${WRKSRC}/bin && ${INSTALL_PROGRAM} tolua \ |
28 |
${INSTALL_DATA} ${WRKSRC}/include/tolua.h ${STAGEDIR}${PREFIX}/include |
34 |
${STAGEDIR}${PREFIX}/bin) |
29 |
${INSTALL_DATA} ${WRKSRC}/lib/libtolua.a ${STAGEDIR}${PREFIX}/lib |
35 |
(cd ${WRKSRC}/include && ${INSTALL_DATA} tolua.h \ |
|
|
36 |
${STAGEDIR}${PREFIX}/include) |
37 |
(cd ${WRKSRC}/lib && ${INSTALL_DATA} libtolua.a \ |
38 |
${STAGEDIR}${PREFIX}/lib) |
30 |
|
39 |
|
31 |
.include <bsd.port.mk> |
40 |
.include <bsd.port.mk> |