[log4shib] 12/13: New patch socket-and-gethostbyname-are-often-provided-by-libc.patch
Ferenc Wágner
wferi-guest at moszumanska.debian.org
Tue Aug 2 10:42:25 UTC 2016
This is an automated email from the git hooks/post-receive script.
wferi-guest pushed a commit to branch debian/master
in repository log4shib.
commit fbc0beb500011b51fe43f2dd38660ab1e5733f42
Author: Ferenc Wágner <wferi at niif.hu>
Date: Mon Jul 4 14:50:46 2016 +0200
New patch socket-and-gethostbyname-are-often-provided-by-libc.patch
socket() and gethostbyname() are often provided by libc
This stops overlinking against libnsl, so we don't need the --as-needed
linker option anymore.
---
debian/patches/series | 1 +
...-gethostbyname-are-often-provided-by-libc.patch | 23 ++++++++++++++++++++++
debian/rules | 8 ++------
3 files changed, 26 insertions(+), 6 deletions(-)
diff --git a/debian/patches/series b/debian/patches/series
index 956f669..e9ecfc1 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -3,3 +3,4 @@ Don-t-leak-the-build-flags-into-the-pkg-config-file.patch
Fix-Doxygen-formatting-issues.patch
Remove-obsolete-MAX_DOT_GRAPH_-WIDTH-HEIGHT-Doxygen-.patch
Drop-superfluous-scope-to-help-Doxygen-find-the-decl.patch
+socket-and-gethostbyname-are-often-provided-by-libc.patch
diff --git a/debian/patches/socket-and-gethostbyname-are-often-provided-by-libc.patch b/debian/patches/socket-and-gethostbyname-are-often-provided-by-libc.patch
new file mode 100644
index 0000000..dbebc73
--- /dev/null
+++ b/debian/patches/socket-and-gethostbyname-are-often-provided-by-libc.patch
@@ -0,0 +1,23 @@
+From: =?utf-8?q?Ferenc_W=C3=A1gner?= <wferi at niif.hu>
+Date: Mon, 4 Jul 2016 08:07:36 +0200
+Subject: socket() and gethostbyname() are often provided by libc
+
+---
+ configure.ac | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 5968628..572bc3e 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -102,8 +102,8 @@ AC_CHECK_FUNCS([syslog gettimeofday ftime localtime_r gmtime_r])
+ # ----------------------------------------------------------------------------
+
+ # for RemoteSyslogAppender
+-AC_CHECK_LIB(socket,socket, LIBS="-lsocket $LIBS",,)
+-AC_CHECK_LIB(nsl,gethostbyname, LIBS="-lnsl $LIBS",,)
++AC_SEARCH_LIBS([socket],[socket],,[AC_MSG_ERROR([cannot find socket() function])])
++AC_SEARCH_LIBS([gethostbyname],[nsl],,[AC_MSG_ERROR([cannot find gethostbyname() function])])
+
+ # checks for pthreads
+ AX_PTHREAD([enable_threads="pthread"],[enable_threads="no"])
diff --git a/debian/rules b/debian/rules
index add0459..c678b40 100755
--- a/debian/rules
+++ b/debian/rules
@@ -4,9 +4,8 @@
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
# Force linking with -lpthread, working around a bug in libtool that drops
-# the linkage because it uses -nostdlib. See #468555. Add --as-needed to
-# drop a few unnecessary dependencies.
-export DEB_LDFLAGS_MAINT_APPEND = -lpthread -Wl,--as-needed
+# the linkage because it uses -nostdlib. See #468555.
+export DEB_LDFLAGS_MAINT_APPEND = -lpthread
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
DEBUG = --enable-debug
@@ -36,8 +35,5 @@ override_dh_install:
if [ -d $(APIDOCS) ]; then find $(APIDOCS) -name "*.md5" -delete; fi
dh_install --fail-missing
-override_dh_autoreconf:
- dh_autoreconf --as-needed
-
%:
dh $@ --parallel --with autoreconf
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-shibboleth/log4shib.git
More information about the Pkg-shibboleth-devel
mailing list