dialog: fix configure test against ncurses
authorFlorian Fainelli <florian@openwrt.org>
Sat, 8 Mar 2014 00:56:42 +0000 (00:56 +0000)
committerFlorian Fainelli <florian@openwrt.org>
Sat, 8 Mar 2014 00:56:42 +0000 (00:56 +0000)
When building on x86_64 hosts, the configure script will try to add /lib64 from
the host to the linker command, which will usually result in failing the
ncurses library test, fix this by checking whether we are cross-compiling or
not.

Signed-off-by: Florian Fainelli <florian@openwrt.org>
SVN-Revision: 39802

utils/dialog/Makefile
utils/dialog/patches/001-cross_compile.patch [new file with mode: 0644]

index 872ab835ade20ec83d704bddc20ca557eda6a46b..8c4737a40d0e125db78d1ecb053ec3186f5d0a16 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2006-2012 OpenWrt.org
+# Copyright (C) 2006-2014 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=dialog
 PKG_VERSION:=1.1-20120706
-PKG_RELEASE:=1
+PKG_RELEASE:=2
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tgz
 PKG_SOURCE_URL:=ftp://invisible-island.net/dialog
diff --git a/utils/dialog/patches/001-cross_compile.patch b/utils/dialog/patches/001-cross_compile.patch
new file mode 100644 (file)
index 0000000..f2f079f
--- /dev/null
@@ -0,0 +1,11 @@
+--- a/configure
++++ b/configure
+@@ -11827,7 +11827,7 @@ linux*)
+               if test -d /lib64
+               then
+-if test -n "/lib64" ; then
++if test -n "/lib64" -a test $cross_compiling = "no"; then
+   for cf_add_libdir in /lib64
+   do
+     if test $cf_add_libdir = /usr/lib ; then