improved SDK support
authorVictor Kirhenshtein <victor@netxms.org>
Wed, 11 Jun 2014 14:15:59 +0000 (11:15 -0300)
committerVictor Kirhenshtein <victor@netxms.org>
Wed, 11 Jun 2014 14:15:59 +0000 (11:15 -0300)
Makefile.am
configure.ac

index f4bbb41..0f26d05 100644 (file)
@@ -14,5 +14,5 @@ SUBDIRS = m4 contrib src doc tools
 SUBDIRS += @TOP_LEVEL_MODULES@
 
 install-exec-hook:
+       if test "x@BUILD_SDK@" = "xyes"; then cp config.h $(DESTDIR)$(includedir); mkdir -p $(DESTDIR)$(pkgdatadir)/sdk; cp libtool $(DESTDIR)$(pkgdatadir)/sdk; cp config/install-sh $(DESTDIR)$(pkgdatadir)/sdk; fi
        if test "x@BUILD_SERVER@" = "xyes"; then LD_LIBRARY_PATH="$(DESTDIR)$(libdir):${LD_LIBRARY_PATH}" $(DESTDIR)$(bindir)/nxmibc -d $(DESTDIR)$(pkgdatadir)/mibs -o $(DESTDIR)$(pkgdatadir)/mibs/netxms.mib; fi
-       if test "x@BUILD_SDK@" = "xyes"; then cp config.h $(DESTDIR)$(includedir); fi
index 7fb5ce0..f086175 100644 (file)
@@ -79,6 +79,7 @@ RUNTIME_PREFIX=""
 HPUX_HPPA="no"
 XMPP_SUPPORT="yes"
 LDAP_SUPPORT="yes"
+DISABLE_READLINE="no"
 
 
 #--------------------------------------------------------------------
@@ -368,6 +369,12 @@ AC_ARG_ENABLE(iconv,
        DISABLE_ICONV="yes"
 ])
 
+AC_ARG_ENABLE(readline,
+[AS_HELP_STRING(--disable-readline,do not use libreadline)],
+[
+       DISABLE_READLINE="yes"
+])
+
 AC_ARG_ENABLE(encryption,
 [AS_HELP_STRING(--disable-encryption,disable encryption support)],
 [
@@ -1277,7 +1284,9 @@ AC_CHECK_LIB(kstat, kstat_open)
 
 if test "x$BUILD_SERVER" = "xyes" ; then
    AC_CHECK_LIB(termcap, tgetstr, [SERVER_LIBS="$SERVER_LIBS -ltermcap"], [AC_CHECK_LIB(ncurses, tgetstr, [SERVER_LIBS="$SERVER_LIBS -lncurses"], AC_CHECK_LIB(curses, tgetstr, [SERVER_LIBS="$SERVER_LIBS -lcurses"]))])
-   AC_CHECK_LIB(readline, readline, [SERVER_LIBS="$SERVER_LIBS -lreadline"], [AC_CHECK_LIB(edit, readline, [SERVER_LIBS="$SERVER_LIBS -ledit"])])
+   if test "x$DISABLE_READLINE" = "xno"; then
+      AC_CHECK_LIB(readline, readline, [SERVER_LIBS="$SERVER_LIBS -lreadline"], [AC_CHECK_LIB(edit, readline, [SERVER_LIBS="$SERVER_LIBS -ledit"])])
+   fi
    SAVED_LDFLAGS="$LDFLAGS"
    LDFLAGS="$LDFLAGS $SERVER_LIBS"