]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
meson: tools: introduce nss directory
authorPavel Hrdina <phrdina@redhat.com>
Wed, 17 Jun 2020 23:54:09 +0000 (01:54 +0200)
committerPavel Hrdina <phrdina@redhat.com>
Mon, 3 Aug 2020 07:27:05 +0000 (09:27 +0200)
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
tools/Makefile.am
tools/meson.build
tools/nss/meson.build [new file with mode: 0644]

index 9c91cac9ccf21e7b5ea1655c8d75ff219d356539..3d9d042d2f3cae3e6399cdaf476cca6062c2d825 100644 (file)
@@ -23,10 +23,6 @@ STANDALONE_CPPFLAGS = -I$(top_srcdir)
 
 noinst_LTLIBRARIES =
 
-install-data-local: install-nss
-
-uninstall-local: uninstall-nss
-
 if WITH_WIRESHARK_DISSECTOR
 
 ws_plugin_LTLIBRARIES = wireshark/src/libvirt.la
@@ -57,35 +53,6 @@ wireshark/src/libvirt/protocol.h: wireshark/util/genxdrstub.pl \
 
 endif WITH_WIRESHARK_DISSECTOR
 
-if WITH_BSD_NSS
-LIBVIRT_NSS_SYMBOL_FILE = \
-       $(srcdir)/nss/libvirt_nss_bsd.syms
-LIBVIRT_GUEST_NSS_SYMBOL_FILE = \
-       $(LIBVIRT_NSS_SYMBOL_FILE)
-NSS_SO_VER = 1
-
-install-nss:
-       ( cd $(DESTDIR)$(libdir) && \
-         rm -f nss_libvirt.so.$(NSS_SO_VER) && \
-         $(LN_S) libnss_libvirt.so.$(NSS_SO_VER) nss_libvirt.so.$(NSS_SO_VER) && \
-         rm -f nss_libvirt_guest.so.$(NSS_SO_VER) && \
-         $(LN_S) libnss_libvirt_guest.so.$(NSS_SO_VER) \
-         nss_libvirt_guest.so.$(NSS_SO_VER))
-
-uninstall-nss:
-       -rm -f $(DESTDIR)$(libdir)/nss_libvirt.so.$(NSS_SO_VER)
-       -rm -f $(DESTDIR)$(libdir)/nss_libvirt_guest.so.$(NSS_SO_VER)
-else ! WITH_BSD_NSS
-LIBVIRT_NSS_SYMBOL_FILE = \
-       $(srcdir)/nss/libvirt_nss.syms
-LIBVIRT_GUEST_NSS_SYMBOL_FILE = \
-       $(srcdir)/nss/libvirt_guest_nss.syms
-NSS_SO_VER = 2
-
-install-nss:
-uninstall-nss:
-endif ! WITH_BSD_NSS
-
 LIBVIRT_NSS_SOURCES = \
        nss/libvirt_nss.c \
        nss/libvirt_nss.h \
index 765532f3b1c4bcb1d22561c5e0ec8f7ea74506a5..7a872f2b661d27ba01b28e0151abf8af068c5b6c 100644 (file)
@@ -290,3 +290,7 @@ endif
 if bash_completion_dep.found()
   subdir('bash-completion')
 endif
+
+if conf.has('WITH_NSS')
+  subdir('nss')
+endif
diff --git a/tools/nss/meson.build b/tools/nss/meson.build
new file mode 100644 (file)
index 0000000..b83a63c
--- /dev/null
@@ -0,0 +1,11 @@
+if conf.has('WITH_BSD_NSS')
+  nss_sym_file = 'libvirt_nss_bsd.syms'
+  nss_guest_sym_file = nss_sym_file
+  nss_so_ver = '1'
+  nss_prefix = ''
+else
+  nss_sym_file = 'libvirt_nss.syms'
+  nss_guest_sym_file = 'libvirt_guest_nss.syms'
+  nss_so_ver = '2'
+  nss_prefix = 'lib'
+endif