]> xenbits.xensource.com Git - libvirt.git/commitdiff
examples: Try harder to uninstall nwfilter
authorMichal Privoznik <mprivozn@redhat.com>
Tue, 19 Apr 2016 09:13:00 +0000 (11:13 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Wed, 20 Apr 2016 15:33:55 +0000 (17:33 +0200)
We have this code in our Makefile that tries to remove
/etc/libvirt/nwfilter if directory is left empty after all our
example nwfilters were uninstalled. However, the check for that
is missing quotation marks thus rendering the test useless:

test -z allow-arp.xml allow-dhcp-server.xml .. qemu-announce-self.xml || \
  rmdir "/some/path/libvirt.git/_install/etc/libvirt/nwfilter"
/bin/sh: line 0: test: too many arguments

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
examples/Makefile.am

index 46465f9e5aeb17b0e42186a6c2f2337647b8452c..e1c37f05f80bc9ce4b1e5444af4c84efd11ac1e3 100644 (file)
@@ -90,5 +90,5 @@ uninstall-local::
        for f in $(FILTERS); do \
                rm -f "$(NWFILTER_DIR)/`basename $$f`"; \
        done
-       -test -z $(shell ls $(NWFILTER_DIR)) || rmdir $(NWFILTER_DIR)
+       -test -z "$(shell ls $(NWFILTER_DIR))" || rmdir $(NWFILTER_DIR)
 endif WITH_NWFILTER