]> git.sur5r.net Git - kconfig-frontends/commitdiff
configure: introduce mconf-specific ncurses CPPFLAGS
authorYann E. MORIN" <yann.morin.1998@free.fr>
Mon, 4 Mar 2013 22:42:10 +0000 (23:42 +0100)
committerYann E. MORIN" <yann.morin.1998@free.fr>
Mon, 4 Mar 2013 22:42:10 +0000 (23:42 +0100)
Use that to pass the CURSES_LOC definition.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
configure.ac
frontends/mconf/Makefile.am
libs/lxdialog/Makefile.am

index f177892386a7304cab3ab90efc6eac066c2f803b..4e02c50ee8f66d8982b405103a2040209b66a935 100644 (file)
@@ -257,13 +257,13 @@ AC_SUBST([intl_LIBS])
 # Check for ncurses, for the mconf & nconf frontends
 AS_IF(
     [test "$need_curses" = "yes" -o "$need_curses" = "auto"],
-    [AC_SUBST([CURSES_LOC])
+    [AC_SUBST([ncurses_mconf_CPPFLAGS])
      AC_SUBST([ncurses_LIBS])
      LIBS_old="$LIBS"
      LIBS=
      AC_CHECK_HEADERS(
         [ncursesw/curses.h ncurses/ncurses.h ncurses/curses.h ncurses.h curses.h],
-        [CURSES_LOC=$ac_header; break])
+        [CURSES_LOC=$ac_header; ncurses_mconf_CPPFLAGS=-DCURSES_LOC=\\\"$ac_header\\\"; break])
      AS_IF(
         [test -z "$CURSES_LOC"],
         [AS_IF(
index 39bb77b2803ca3824c5d3b31562b7e7855fa0599..5ea3c484454bf9c1598b7f493237e932b3b53c0c 100644 (file)
@@ -2,7 +2,7 @@ bin_PROGRAMS = mconf
 
 mconf_SOURCES = mconf.c
 mconf_CPPFLAGS = $(AM_CPPFLAGS)                 \
-                 -DCURSES_LOC='"$(CURSES_LOC)"' \
+                 ${ncurses_mconf_CPPFLAGS}      \
                  $(intl_CPPFLAGS)               \
                  -I$(top_srcdir)/libs           \
                  -I$(top_srcdir)/libs/parser
index 271b220f91d6fe8c0dcbc35abb88b995069a9528..73b084ee3077008197557fe595cc081173c3716b 100644 (file)
@@ -9,7 +9,7 @@ libkconfig_lxdialog_a_SOURCES = \
     util.c                      \
     yesno.c
 
-libkconfig_lxdialog_a_CPPFLAGS = $(AM_CPPFLAGS)                   \
-                                 -DCURSES_LOC='"${CURSES_LOC}"'   \
+libkconfig_lxdialog_a_CPPFLAGS = $(AM_CPPFLAGS)               \
+                                 ${ncurses_mconf_CPPFLAGS}    \
                                  $(intl_CPPFLAGS)
 liblxdialog_a_CFLAGS = $(AM_CFLAGS) $(kf_CFLAGS)