summaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
authorRene Mayrhofer <rene@mayrhofer.eu.org>2011-01-01 11:21:23 +0100
committerRene Mayrhofer <rene@mayrhofer.eu.org>2011-01-01 11:21:23 +0100
commitfac80d3f44dc9614f4313f2e225efdbb83840e64 (patch)
tree028a1ec6bd34d95fd60cd93a560364982345210e /debian
parenta643e0130a2a7b7faaed83bf3e133677ac89f5db (diff)
downloadvyos-strongswan-fac80d3f44dc9614f4313f2e225efdbb83840e64.tar.gz
vyos-strongswan-fac80d3f44dc9614f4313f2e225efdbb83840e64.zip
Special handling for strongswan-nm: only build if headers are really available.
Diffstat (limited to 'debian')
-rwxr-xr-xdebian/rules12
-rw-r--r--debian/strongswan-nm.install1
2 files changed, 11 insertions, 2 deletions
diff --git a/debian/rules b/debian/rules
index c7253fe21..e3eb7b5c8 100755
--- a/debian/rules
+++ b/debian/rules
@@ -23,7 +23,7 @@ CONFIGUREARGS := --prefix=/usr --sysconfdir=/etc --localstatedir=/var \
--enable-eap-gtc --enable-eap-aka --enable-eap-mschapv2 \
--enable-eap-tls --enable-eap-ttls --enable-eap-tnc \
--enable-sql --enable-integrity-test \
- --enable-nm --enable-ha --enable-dhcp --enable-farp \
+ --enable-ha --enable-dhcp --enable-farp \
--enable-led \
--enable-test-vectors --enable-nat-transport
# --with-user=strongswan --with-group=nogroup \
@@ -49,6 +49,14 @@ ifeq ($(DEB_BUILD_ARCH_CPU),i386)
CONFIGUREARGS += --enable-padlock
endif
+# And only enable network-manager building if the libraries are present
+# (they will be when the build-deps are fulfilled, but this makes it easier
+# to do backports where the network-manager libs can not be installed, and
+# thus to just ignore build-deps).
+ifeq ($(shell test -d /usr/include/libnm-glib/ && echo yes),yes)
+ CONFIGUREARS += --enable-nm
+endif
+
build: build-stamp
build-stamp:
dh_testdir
@@ -91,6 +99,8 @@ install: build-stamp
ifeq ($(DEB_BUILD_ARCH_CPU),i386)
install $(CURDIR)/debian/tmp/usr/lib/ipsec/plugins/libstrongswan-padlock.so* $(CURDIR)/debian/libstrongswan/usr/lib/ipsec/plugins/
endif
+ # and special handling for network-manager files - only install when build
+ install -d $(CURDIR)/debian/tmp/usr/lib/ipsec/plugins/libstrongswan-nm.so* $(CURDIR)/debian/strongswan-nm/usr/lib/ipsec/plugins/
# and additional files not covered by upstream makefile...
install --mode=0600 $(CURDIR)/debian/ipsec.secrets.proto $(CURDIR)/debian/strongswan-starter/etc/ipsec.secrets
diff --git a/debian/strongswan-nm.install b/debian/strongswan-nm.install
deleted file mode 100644
index a6a6dc3a1..000000000
--- a/debian/strongswan-nm.install
+++ /dev/null
@@ -1 +0,0 @@
-usr/lib/ipsec/plugins/libstrongswan-nm.so* usr/lib/ipsec/plugins/