aboutsummaryrefslogtreecommitdiffstats
path: root/package/lua/patches-host/100-no_readline.patch
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2009-10-28 13:56:33 +0000
committerJo-Philipp Wich <jow@openwrt.org>2009-10-28 13:56:33 +0000
commitd82615bfc074f10331b0e7c4873677052b51d6c5 (patch)
tree8170574c706fedaba38512d38052521798db04de /package/lua/patches-host/100-no_readline.patch
parent04f57c7f8708ed3f81199e01beb600159918fec7 (diff)
downloadupstream-d82615bfc074f10331b0e7c4873677052b51d6c5.tar.gz
upstream-d82615bfc074f10331b0e7c4873677052b51d6c5.tar.bz2
upstream-d82615bfc074f10331b0e7c4873677052b51d6c5.zip
[package] lua: add the 100-no_readline.patch to host build
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@18195 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/lua/patches-host/100-no_readline.patch')
-rw-r--r--package/lua/patches-host/100-no_readline.patch49
1 files changed, 49 insertions, 0 deletions
diff --git a/package/lua/patches-host/100-no_readline.patch b/package/lua/patches-host/100-no_readline.patch
new file mode 100644
index 0000000000..209c302bb7
--- /dev/null
+++ b/package/lua/patches-host/100-no_readline.patch
@@ -0,0 +1,49 @@
+--- a/src/luaconf.h
++++ b/src/luaconf.h
+@@ -38,7 +38,6 @@
+ #if defined(LUA_USE_LINUX)
+ #define LUA_USE_POSIX
+ #define LUA_USE_DLOPEN /* needs an extra library: -ldl */
+-#define LUA_USE_READLINE /* needs some extra libraries */
+ #endif
+
+ #if defined(LUA_USE_MACOSX)
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -17,6 +17,7 @@
+ MYCFLAGS=
+ MYLDFLAGS=
+ MYLIBS=
++# USE_READLINE=1
+
+ # == END OF USER SETTINGS. NO NEED TO CHANGE ANYTHING BELOW THIS LINE =========
+
+@@ -75,7 +76,7 @@
+ @echo "MYLIBS = $(MYLIBS)"
+
+ # convenience targets for popular platforms
+-
++RFLAG=$(if $(USE_READLINE),-DLUA_USE_READLINE)
+ none:
+ @echo "Please choose a platform:"
+ @echo " $(PLATS)"
+@@ -90,16 +91,16 @@
+ $(MAKE) all MYCFLAGS="-DLUA_USE_POSIX -DLUA_USE_DLOPEN" MYLIBS="-Wl,-E"
+
+ freebsd:
+- $(MAKE) all MYCFLAGS="-DLUA_USE_LINUX" MYLIBS="-Wl,-E -lreadline"
++ $(MAKE) all MYCFLAGS="-DLUA_USE_LINUX" $(RFLAG)" MYLIBS="-Wl,-E$(if $(USE_READLINE), -lreadline)"
+
+ generic:
+ $(MAKE) all MYCFLAGS=
+
+ linux:
+- $(MAKE) all MYCFLAGS=-DLUA_USE_LINUX MYLIBS="-Wl,-E -ldl -lreadline -lhistory -lncurses"
++ $(MAKE) all MYCFLAGS="-DLUA_USE_LINUX $(RFLAG)" MYLIBS="-Wl,-E -ldl $(if $(USE_READLINE), -lreadline -lhistory -lncurses)"
+
+ macosx:
+- $(MAKE) all MYCFLAGS=-DLUA_USE_LINUX MYLIBS="-lreadline"
++ $(MAKE) all MYCFLAGS=-DLUA_USE_LINUX $(if $(USE_READLINE), MYLIBS="-lreadline")
+ # use this on Mac OS X 10.3-
+ # $(MAKE) all MYCFLAGS=-DLUA_USE_MACOSX
+