nano: enable ncursesw support
authorGustavo Zacarias <gustavo@zacarias.com.ar>
Wed, 17 Sep 2014 13:08:18 +0000 (10:08 -0300)
committerPeter Korsgaard <peter@korsgaard.com>
Wed, 17 Sep 2014 21:01:36 +0000 (23:01 +0200)
Enable support for ncurses widechar by specifying the proper
ncursesw-config when it's enabled, otherwise keep the old trick in place
when it's not to avoid automatically picking up the host/distro one.

Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
package/nano/nano.mk

index 9557a93bbc8d801386cd94b35008557915230382..038aaa5b82ed06c8000684b2ddc514d9bd665fd0 100644 (file)
@@ -9,11 +9,16 @@ NANO_VERSION = $(NANO_VERSION_MAJOR).6
 NANO_SITE = http://www.nano-editor.org/dist/v$(NANO_VERSION_MAJOR)
 NANO_LICENSE = GPLv3+
 NANO_LICENSE_FILES = COPYING
-NANO_MAKE_ENV = CURSES_LIB="-lncurses"
 NANO_CONF_OPT = --without-slang
-NANO_CONF_ENV = ac_cv_prog_NCURSESW_CONFIG=false
 NANO_DEPENDENCIES = ncurses
 
+ifeq ($(BR2_PACKAGE_NCURSES_WCHAR),y)
+       NANO_CONF_ENV += ac_cv_prog_NCURSESW_CONFIG="$(STAGING_DIR)/usr/bin/ncursesw5-config"
+else
+       NANO_CONF_ENV += ac_cv_prog_NCURSESW_CONFIG=false
+       NANO_MAKE_ENV += CURSES_LIB="-lncurses"
+endif
+
 ifeq ($(BR2_PACKAGE_FILE),y)
        NANO_DEPENDENCIES += file
 else