-adjusting makefile to install NSS libraries of GNS
authorChristian Grothoff <christian@grothoff.org>
Thu, 31 May 2012 14:23:27 +0000 (14:23 +0000)
committerChristian Grothoff <christian@grothoff.org>
Thu, 31 May 2012 14:23:27 +0000 (14:23 +0000)
configure.ac
src/gns/Makefile.am
src/gns/nss/Makefile.am

index 3da8dfb6d659acbc419a783ae04509474392081a..c75b52f4c7bc1145e37b5c88bf10df38b7da3bf3 100644 (file)
@@ -1013,6 +1013,7 @@ src/fs/Makefile
 src/fs/fs.conf
 src/gns/Makefile
 src/gns/gns.conf
+src/gns/nss/Makefile
 src/hello/Makefile
 src/include/Makefile
 src/include/gnunet_directories.h
index 7b584c8ef80b969d020707afd83a8f1e76be3531..1146950d82e98a095196715a2e974f719a81fd92 100644 (file)
@@ -1,6 +1,6 @@
 INCLUDES = -I$(top_srcdir)/src/include
 
-#SUBDIRS=nss
+SUBDIRS = . nss
 
 if MINGW
   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
index a75a856702afd59fd5860b9c8568acfb568af604..c5e415dbfde01beb81d867e5deeb235abe3f8fbc 100644 (file)
 
 EXTRA_DIST = map-file
 
-# This cool debug trap works on i386/gcc only
-AM_CFLAGS='-DDEBUG_TRAP=__asm__("int $$3")'
-
 AM_LDFLAGS=-avoid-version -module -export-dynamic
 
-lib_LTLIBRARIES = 
+nssdir = /lib/
+LIBTOOL = $(SUDO_BINARY) $(SHELL) $(top_builddir)/libtool
 
-lib_LTLIBRARIES += \
+if !MINGW
+nss_LTLIBRARIES = \
        libnss_gns.la \
        libnss_gns4.la \
        libnss_gns6.la
+endif
 
 sources = util.c util.h query.h query.c
 
@@ -46,12 +46,9 @@ libnss_gns6_la_SOURCES=$(libnss_gns_la_SOURCES)
 libnss_gns6_la_CFLAGS=$(libnss_gns_la_CFLAGS) -DNSS_IPV6_ONLY=1
 libnss_gns6_la_LDFLAGS=$(libnss_gns_la_LDFLAGS)
 
-install-exec-hook:
-       rm -f $(DESTDIR)$(libdir)/libnss_gns.la 
-       rm -f $(DESTDIR)$(libdir)/libnss_gns4.la 
-       rm -f $(DESTDIR)$(libdir)/libnss_gns6.la 
+install-data-hook:
+       $(SUDO_BINARY) $(SHELL) $(top_builddir)/libtool --finish $(nssdir)
+       $(SUDO_BINARY) rm -f $(nssdir)/libnss_gns.la $(nssdir)/libnss_gns4.la $(nssdir)/libnss_gns6.la 
 
 uninstall-hook:
-       rm -f $(DESTDIR)$(libdir)/libnss_gns.so.2 
-       rm -f $(DESTDIR)$(libdir)/libnss_gns4.so.2 
-       rm -f $(DESTDIR)$(libdir)/libnss_gns6.so.2 
+       $(SUDO_BINARY) rm -f $(nssdir)/libnss_gns.so.2 $(nssdir)/libnss_gns4.so.2 $(nssdir)/libnss_gns6.so.2