diff options
author | bapt <bapt@FreeBSD.org> | 2015-01-17 09:37:59 +0800 |
---|---|---|
committer | bapt <bapt@FreeBSD.org> | 2015-01-17 09:37:59 +0800 |
commit | e312b18278d1386257692484c1c12abbbbf6649b (patch) | |
tree | 7bbcefecae6ee8f8408c7190f21926a7bbf62575 | |
parent | 3f2fe40a14fb78148f1d898c8974d5b757a2a44a (diff) | |
download | freebsd-ports-gnome-e312b18278d1386257692484c1c12abbbbf6649b.tar.gz freebsd-ports-gnome-e312b18278d1386257692484c1c12abbbbf6649b.tar.zst freebsd-ports-gnome-e312b18278d1386257692484c1c12abbbbf6649b.zip |
Link on libedit instead of readline
Reduce overlinking on liblua
Enforce libedit from ports
-rw-r--r-- | lang/lua51/Makefile | 2 | ||||
-rw-r--r-- | lang/lua52/Makefile | 12 |
2 files changed, 9 insertions, 5 deletions
diff --git a/lang/lua51/Makefile b/lang/lua51/Makefile index 5300cc05bfd0..221f1f55a60f 100644 --- a/lang/lua51/Makefile +++ b/lang/lua51/Makefile @@ -31,7 +31,7 @@ LDFLAGS+= -lm -pthread BUILD_WRKSRC= ${WRKSRC}/src MAKE_ARGS+= MYCFLAGS="${CFLAGS} ${CPPFLAGS} -DLUA_USE_LINUX" \ MYLDFLAGS="${LDFLAGS}" \ - MYLIBS="-Wl,-E -ledit" \ + MYLIBS="-Wl,-E -L${LOCALBASE}/lib -ledit" \ CC="${CC}" \ LUA_T=lua51 \ LUAC_T=luac51 \ diff --git a/lang/lua52/Makefile b/lang/lua52/Makefile index 79efb17512e5..20af2d0f39ac 100644 --- a/lang/lua52/Makefile +++ b/lang/lua52/Makefile @@ -3,7 +3,7 @@ PORTNAME= lua PORTVERSION= 5.2.3 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= lang MASTER_SITES= http://www.lua.org/ftp/ PKGNAMESUFFIX= 52 @@ -14,7 +14,7 @@ COMMENT= Small, compilable scripting language providing easy access to C code LICENSE= MIT LUA_VER= 5.2 -USES= readline +LIB_DEPENDS= libedit.so.0:${PORTSDIR}/devel/libedit USE_LDCONFIG= yes # Overriding __MAKE_CONF makes sure that we don't re-parse @@ -26,10 +26,12 @@ USE_LDCONFIG= yes MAKE_ARGS= __MAKE_CONF=${NONEXISTENT} # liblua.so requires libm, so make sure it has an explicit dependency # so that applications need not second-guess lua's dependencies. +CPPFLAGS+= -I${LOCALBASE}/include LDFLAGS+= -lm -pthread BUILD_WRKSRC= ${WRKSRC}/src MAKE_ARGS+= MYCFLAGS="${CFLAGS} ${CPPFLAGS} -DLUA_USE_LINUX" \ - MYLDFLAGS="${LDFLAGS} -Wl,-E -lreadline" \ + MYLDFLAGS="${LDFLAGS}" \ + MYLIBS="-Wl,-E -L${LOCALBASE}/lib -ledit" \ CC="${CC}" \ LUA_T=lua52 \ LUAC_T=luac52 \ @@ -62,7 +64,9 @@ CFLAGS_powerpc= -fPIC post-patch: @${REINPLACE_CMD} -e 's,rand *(,random(,g' \ ${WRKSRC}/src/lmathlib.c - @${REINPLACE_CMD} -e "/LUA_ROOT/s|/usr/local|${LUA_PREFIX}|" \ + @${REINPLACE_CMD} -e "/LUA_ROOT/s|/usr/local|${LUA_PREFIX}| ; \ + s,readline/,editline/,g ; \ + /history\.h/d" \ ${WRKSRC}/src/luaconf.h post-install: |