[libvirt PATCH 269/351] meson: tools: introduce nss directory

Pavel Hrdina phrdina at redhat.com
Thu Jul 16 09:58:25 UTC 2020


Signed-off-by: Pavel Hrdina <phrdina at redhat.com>
---
 tools/Makefile.am     | 33 ---------------------------------
 tools/meson.build     |  4 ++++
 tools/nss/meson.build | 11 +++++++++++
 3 files changed, 15 insertions(+), 33 deletions(-)
 create mode 100644 tools/nss/meson.build

diff --git a/tools/Makefile.am b/tools/Makefile.am
index 9c91cac9ccf..3d9d042d2f3 100644
--- a/tools/Makefile.am
+++ b/tools/Makefile.am
@@ -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 \
diff --git a/tools/meson.build b/tools/meson.build
index 36c05d43d9c..52d997d2e73 100644
--- a/tools/meson.build
+++ b/tools/meson.build
@@ -282,3 +282,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
index 00000000000..b83a63c9c34
--- /dev/null
+++ b/tools/nss/meson.build
@@ -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
-- 
2.26.2




More information about the libvir-list mailing list