Package: netmrg
Version: 0.20-6.1
Severity: serious
Tags: patch
User: [email protected]
Usertags: origin-ubuntu ubuntu-patch saucy
netmrg fails to build with the multiarch net-snmp in unstable, as
follows:
configure: error: Cannot find SNMP libraries. Use --with-snmp-lib-dir= to
specify non-default path.
make: *** [config.status] Error 1
configure is really being far too controlling here; this problem goes
away if configure scripts are prepared to admit that the system linker
might have a clue where to find system libraries. However, here's a
patch to work around this brain damage for now.
* Work around configure wanting to know too much detail about where a
system libsnmp.so is installed rather than trusting the linker.
diff -u netmrg-0.20/debian/rules netmrg-0.20/debian/rules
--- netmrg-0.20/debian/rules
+++ netmrg-0.20/debian/rules
@@ -11,6 +11,7 @@
# from having to guess our platform (since we know it already)
DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
CFLAGS = -Wall -g
@@ -24,10 +25,16 @@
INSTALL_PROGRAM += -s
endif
+ifneq (,$(wildcard /usr/lib/$(DEB_HOST_MULTIARCH)/libsnmp.so))
+ confflags := --with-snmp-lib-dir=/usr/lib/$(DEB_HOST_MULTIARCH)
+else
+ confflags :=
+endif
+
config.status: configure
dh_testdir
# Add here commands to configure the package.
- CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE)
--build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man
--infodir=\$${prefix}/share/info --sysconfdir=/etc/netmrg --localstatedir=/var
--libexecdir=/usr/lib
+ CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE)
--build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man
--infodir=\$${prefix}/share/info --sysconfdir=/etc/netmrg --localstatedir=/var
--libexecdir=/usr/lib $(confflags)
build: build-stamp
Thanks,
--
Colin Watson [[email protected]]
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]