commit:     d3c5298c0c05243b79396f77fa43b0e949064122
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Sat Jan 21 11:01:49 2017 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Sat Jan 21 11:04:53 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d3c5298c

net-analyzer/nmap: Fix bug #529244 again.

Package-Manager: Portage-2.3.3, Repoman-2.3.1

 net-analyzer/nmap/files/nmap-7.31-libnl.patch | 15 ++++++++++++++
 net-analyzer/nmap/nmap-7.31.ebuild            |  6 ++++--
 net-analyzer/nmap/nmap-7.40.ebuild            | 28 ++++++++++++++-------------
 net-analyzer/nmap/nmap-9999.ebuild            | 28 ++++++++++++++-------------
 4 files changed, 49 insertions(+), 28 deletions(-)

diff --git a/net-analyzer/nmap/files/nmap-7.31-libnl.patch 
b/net-analyzer/nmap/files/nmap-7.31-libnl.patch
new file mode 100644
index 00000000..c16d829
--- /dev/null
+++ b/net-analyzer/nmap/files/nmap-7.31-libnl.patch
@@ -0,0 +1,15 @@
+nping does not call anything nl_* related so it should not link against libnl 
(bug #529244)
+Patching configure.ac would be best but eautoreconf does not handle the 
subdirs very well.
+
+--- a/nping/configure.ac
++++ b/nping/configure.ac
+@@ -114,9 +114,6 @@
+ # OpenSSL and NSE C modules can require dlopen
+ AC_SEARCH_LIBS(dlopen, dl)
+ 
+-# libpcap can require libnl
+-AC_SEARCH_LIBS(nl_handle_alloc, nl)
+-
+ # We test whether they specified openssl desires explicitly
+ use_openssl="yes"
+ specialssldir=""

diff --git a/net-analyzer/nmap/nmap-7.31.ebuild 
b/net-analyzer/nmap/nmap-7.31.ebuild
index 1bdcbae..e89f0e6 100644
--- a/net-analyzer/nmap/nmap-7.31.ebuild
+++ b/net-analyzer/nmap/nmap-7.31.ebuild
@@ -67,15 +67,17 @@ src_unpack() {
 }
 
 src_prepare() {
+       rm -r libpcap/ || die
+
        epatch \
                "${FILESDIR}"/${PN}-5.10_beta1-string.patch \
                "${FILESDIR}"/${PN}-5.21-python.patch \
                "${FILESDIR}"/${PN}-6.46-uninstaller.patch \
-               "${FILESDIR}"/${PN}-6.47-no-libnl.patch \
                "${FILESDIR}"/${PN}-6.25-liblua-ar.patch \
                "${FILESDIR}"/${PN}-7.25-no-FORTIFY_SOURCE.patch \
                "${FILESDIR}"/${PN}-7.25-CXXFLAGS.patch \
-               "${FILESDIR}"/${PN}-7.25-libpcre.patch
+               "${FILESDIR}"/${PN}-7.25-libpcre.patch \
+               "${FILESDIR}"/${PN}-7.31-libnl.patch
 
        if use nls; then
                local lingua=''

diff --git a/net-analyzer/nmap/nmap-7.40.ebuild 
b/net-analyzer/nmap/nmap-7.40.ebuild
index 28b7751..4ea8959 100644
--- a/net-analyzer/nmap/nmap-7.40.ebuild
+++ b/net-analyzer/nmap/nmap-7.40.ebuild
@@ -2,11 +2,11 @@
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
-EAPI=5
+EAPI=6
 
 PYTHON_COMPAT=( python2_7 )
 PYTHON_REQ_USE="sqlite,xml"
-inherit autotools eutils flag-o-matic python-single-r1 toolchain-funcs
+inherit autotools flag-o-matic python-single-r1 toolchain-funcs
 
 MY_P=${P/_beta/BETA}
 
@@ -54,6 +54,16 @@ DEPEND="
 "
 
 S="${WORKDIR}/${MY_P}"
+PATCHES=(
+       "${FILESDIR}"/${PN}-5.10_beta1-string.patch
+       "${FILESDIR}"/${PN}-5.21-python.patch
+       "${FILESDIR}"/${PN}-6.46-uninstaller.patch
+       "${FILESDIR}"/${PN}-6.25-liblua-ar.patch
+       "${FILESDIR}"/${PN}-7.25-no-FORTIFY_SOURCE.patch
+       "${FILESDIR}"/${PN}-7.25-CXXFLAGS.patch
+       "${FILESDIR}"/${PN}-7.25-libpcre.patch
+       "${FILESDIR}"/${PN}-7.31-libnl.patch
+)
 
 pkg_setup() {
        if use ndiff || use zenmap; then
@@ -67,15 +77,9 @@ src_unpack() {
 }
 
 src_prepare() {
-       epatch \
-               "${FILESDIR}"/${PN}-5.10_beta1-string.patch \
-               "${FILESDIR}"/${PN}-5.21-python.patch \
-               "${FILESDIR}"/${PN}-6.46-uninstaller.patch \
-               "${FILESDIR}"/${PN}-6.47-no-libnl.patch \
-               "${FILESDIR}"/${PN}-6.25-liblua-ar.patch \
-               "${FILESDIR}"/${PN}-7.25-no-FORTIFY_SOURCE.patch \
-               "${FILESDIR}"/${PN}-7.25-CXXFLAGS.patch \
-               "${FILESDIR}"/${PN}-7.25-libpcre.patch
+       rm -r libpcap/ || die
+
+       default
 
        if use nls; then
                local lingua=''
@@ -109,8 +113,6 @@ src_prepare() {
                zenmap/install_scripts/unix/zenmap-root.desktop \
                zenmap/install_scripts/unix/zenmap.desktop || die
 
-       epatch_user
-
        cp libdnet-stripped/include/config.h.in{,.nmap-orig} || die
        eautoreconf
        if [[ ${CHOST} == *-darwin* ]] ; then

diff --git a/net-analyzer/nmap/nmap-9999.ebuild 
b/net-analyzer/nmap/nmap-9999.ebuild
index b7315c6..ff1ea85 100644
--- a/net-analyzer/nmap/nmap-9999.ebuild
+++ b/net-analyzer/nmap/nmap-9999.ebuild
@@ -2,11 +2,11 @@
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
-EAPI=5
+EAPI=6
 
 PYTHON_COMPAT=( python2_7 )
 PYTHON_REQ_USE="sqlite,xml"
-inherit autotools eutils flag-o-matic git-r3 python-single-r1 toolchain-funcs 
user
+inherit autotools flag-o-matic git-r3 python-single-r1 toolchain-funcs user
 
 MY_P=${P/_beta/BETA}
 
@@ -52,6 +52,16 @@ DEPEND="
 "
 
 S="${WORKDIR}/${MY_P}"
+PATCHES=(
+       "${FILESDIR}"/${PN}-5.10_beta1-string.patch
+       "${FILESDIR}"/${PN}-5.21-python.patch
+       "${FILESDIR}"/${PN}-6.25-liblua-ar.patch
+       "${FILESDIR}"/${PN}-6.46-uninstaller.patch
+       "${FILESDIR}"/${PN}-7.25-CXXFLAGS.patch
+       "${FILESDIR}"/${PN}-7.25-libpcre.patch
+       "${FILESDIR}"/${PN}-7.25-no-FORTIFY_SOURCE.patch
+       "${FILESDIR}"/${PN}-7.31-libnl.patch
+)
 
 pkg_setup() {
        if use ndiff || use zenmap; then
@@ -60,15 +70,9 @@ pkg_setup() {
 }
 
 src_prepare() {
-       epatch \
-               "${FILESDIR}"/${PN}-5.10_beta1-string.patch \
-               "${FILESDIR}"/${PN}-5.21-python.patch \
-               "${FILESDIR}"/${PN}-6.25-liblua-ar.patch \
-               "${FILESDIR}"/${PN}-6.46-uninstaller.patch \
-               "${FILESDIR}"/${PN}-6.47-no-libnl.patch \
-               "${FILESDIR}"/${PN}-7.25-CXXFLAGS.patch \
-               "${FILESDIR}"/${PN}-7.25-libpcre.patch \
-               "${FILESDIR}"/${PN}-7.25-no-FORTIFY_SOURCE.patch
+       rm -r libpcap/ || die
+
+       default
 
        if use nls; then
                local lingua=''
@@ -97,8 +101,6 @@ src_prepare() {
                zenmap/install_scripts/unix/zenmap-root.desktop \
                zenmap/install_scripts/unix/zenmap.desktop || die
 
-       epatch_user
-
        cp libdnet-stripped/include/config.h.in{,.nmap-orig} || die
        eautoreconf
        if [[ ${CHOST} == *-darwin* ]] ; then

Reply via email to