net-analyzer/nmap: Sync with Gentoo

It's from Gentoo commit 54c3961cd8fd050411752bc036f2e6d24b1aa075.
This commit is contained in:
Flatcar Buildbot 2023-04-24 07:14:46 +00:00 committed by Krzesimir Nowak
parent 09c112443f
commit d0ced35123
4 changed files with 25 additions and 19 deletions

View File

@ -16,7 +16,6 @@
<flag name="nping">Install the nping utility</flag> <flag name="nping">Install the nping utility</flag>
<flag name="nse">Include support for the Nmap Scripting Engine (NSE)</flag> <flag name="nse">Include support for the Nmap Scripting Engine (NSE)</flag>
<flag name="symlink">Install symlink to nc</flag> <flag name="symlink">Install symlink to nc</flag>
<flag name="system-lua">Use <pkg>dev-lang/lua</pkg> instead of the bundled liblua</flag>
<flag name="zenmap">Install the GTK+ based nmap GUI, zenmap</flag> <flag name="zenmap">Install the GTK+ based nmap GUI, zenmap</flag>
</use> </use>
<upstream> <upstream>

View File

@ -26,9 +26,9 @@ else
fi fi
SLOT="0" SLOT="0"
IUSE="ipv6 libssh2 ncat nping +nse ssl symlink +system-lua" IUSE="ipv6 libssh2 ncat nping +nse ssl symlink"
REQUIRED_USE=" REQUIRED_USE="
system-lua? ( nse ${LUA_REQUIRED_USE} ) nse? ( ${LUA_REQUIRED_USE} )
symlink? ( ncat ) symlink? ( ncat )
" "
@ -40,13 +40,15 @@ RDEPEND="
net-libs/libssh2[zlib] net-libs/libssh2[zlib]
sys-libs/zlib sys-libs/zlib
) )
nse? ( sys-libs/zlib ) nse? (
${LUA_DEPS}
sys-libs/zlib
)
ssl? ( dev-libs/openssl:0= ) ssl? ( dev-libs/openssl:0= )
symlink? ( symlink? (
!net-analyzer/netcat !net-analyzer/netcat
!net-analyzer/openbsd-netcat !net-analyzer/openbsd-netcat
) )
system-lua? ( ${LUA_DEPS} )
" "
DEPEND="${RDEPEND}" DEPEND="${RDEPEND}"
@ -67,7 +69,7 @@ PATCHES=(
) )
pkg_setup() { pkg_setup() {
use system-lua && lua-single_pkg_setup use nse && lua-single_pkg_setup
} }
src_prepare() { src_prepare() {
@ -99,9 +101,9 @@ src_configure() {
$(use_with libssh2) \ $(use_with libssh2) \
$(use_with ncat) \ $(use_with ncat) \
$(use_with nping) \ $(use_with nping) \
$(use_with nse liblua) \
$(use_with ssl openssl) \ $(use_with ssl openssl) \
$(usex libssh2 --with-zlib) \ $(usex libssh2 --with-zlib) \
$(usex nse --with-liblua=$(usex system-lua yes included '' '') --without-liblua) \
$(usex nse --with-zlib) \ $(usex nse --with-zlib) \
--cache-file="${S}"/config.cache \ --cache-file="${S}"/config.cache \
--with-libdnet=included \ --with-libdnet=included \

View File

@ -28,9 +28,9 @@ fi
# https://github.com/nmap/nmap/issues/2199 # https://github.com/nmap/nmap/issues/2199
LICENSE="|| ( NPSL-0.94 NPSL-0.95 )" LICENSE="|| ( NPSL-0.94 NPSL-0.95 )"
SLOT="0" SLOT="0"
IUSE="ipv6 libssh2 ncat nping +nse ssl symlink +system-lua" IUSE="ipv6 libssh2 ncat nping +nse ssl symlink"
REQUIRED_USE=" REQUIRED_USE="
system-lua? ( nse ${LUA_REQUIRED_USE} ) nse? ( ${LUA_REQUIRED_USE} )
symlink? ( ncat ) symlink? ( ncat )
" "
@ -42,7 +42,10 @@ RDEPEND="
net-libs/libssh2[zlib] net-libs/libssh2[zlib]
sys-libs/zlib sys-libs/zlib
) )
nse? ( sys-libs/zlib ) nse? (
${LUA_DEPS}
sys-libs/zlib
)
ssl? ( dev-libs/openssl:0= ) ssl? ( dev-libs/openssl:0= )
symlink? ( symlink? (
ncat? ( ncat? (
@ -50,7 +53,6 @@ RDEPEND="
!net-analyzer/openbsd-netcat !net-analyzer/openbsd-netcat
) )
) )
system-lua? ( ${LUA_DEPS} )
" "
DEPEND="${RDEPEND}" DEPEND="${RDEPEND}"
BDEPEND=" BDEPEND="
@ -79,7 +81,7 @@ PATCHES=(
pkg_setup() { pkg_setup() {
python-any-r1_pkg_setup python-any-r1_pkg_setup
use system-lua && lua-single_pkg_setup use nse && lua-single_pkg_setup
} }
src_prepare() { src_prepare() {
@ -114,9 +116,9 @@ src_configure() {
$(use_with libssh2) \ $(use_with libssh2) \
$(use_with ncat) \ $(use_with ncat) \
$(use_with nping) \ $(use_with nping) \
$(use_with nse liblua) \
$(use_with ssl openssl) \ $(use_with ssl openssl) \
$(usex libssh2 --with-zlib) \ $(usex libssh2 --with-zlib) \
$(usex nse --with-liblua=$(usex system-lua yes included '' '') --without-liblua) \
$(usex nse --with-zlib) \ $(usex nse --with-zlib) \
--cache-file="${S}"/config.cache \ --cache-file="${S}"/config.cache \
--with-libdnet=included \ --with-libdnet=included \

View File

@ -30,10 +30,10 @@ fi
# https://github.com/nmap/nmap/issues/2199 # https://github.com/nmap/nmap/issues/2199
LICENSE="NPSL-0.95" LICENSE="NPSL-0.95"
SLOT="0" SLOT="0"
IUSE="ipv6 libssh2 ncat ndiff nping nls +nse ssl symlink +system-lua zenmap" IUSE="ipv6 libssh2 ncat ndiff nping nls +nse ssl symlink zenmap"
REQUIRED_USE=" REQUIRED_USE="
${PYTHON_REQUIRED_USE} ${PYTHON_REQUIRED_USE}
system-lua? ( nse ${LUA_REQUIRED_USE} ) nse? ( ${LUA_REQUIRED_USE} )
symlink? ( ncat ) symlink? ( ncat )
" "
@ -47,7 +47,10 @@ RDEPEND="
sys-libs/zlib sys-libs/zlib
) )
nls? ( virtual/libintl ) nls? ( virtual/libintl )
nse? ( sys-libs/zlib ) nse? (
${LUA_DEPS}
sys-libs/zlib
)
ssl? ( dev-libs/openssl:= ) ssl? ( dev-libs/openssl:= )
symlink? ( symlink? (
ncat? ( ncat? (
@ -55,7 +58,6 @@ RDEPEND="
!net-analyzer/openbsd-netcat !net-analyzer/openbsd-netcat
) )
) )
system-lua? ( ${LUA_DEPS} )
zenmap? ( zenmap? (
${PYTHON_DEPS} ${PYTHON_DEPS}
$(python_gen_cond_dep ' $(python_gen_cond_dep '
@ -64,6 +66,7 @@ RDEPEND="
) )
" "
DEPEND="${RDEPEND}" DEPEND="${RDEPEND}"
# Python is always needed at build time for some scripts
BDEPEND=" BDEPEND="
${PYTHON_DEPS} ${PYTHON_DEPS}
virtual/pkgconfig virtual/pkgconfig
@ -90,7 +93,7 @@ PATCHES=(
pkg_setup() { pkg_setup() {
python-single-r1_pkg_setup python-single-r1_pkg_setup
use system-lua && lua-single_pkg_setup use nse && lua-single_pkg_setup
} }
src_prepare() { src_prepare() {
@ -134,10 +137,10 @@ src_configure() {
$(use_with ncat) $(use_with ncat)
$(use_with ndiff) $(use_with ndiff)
$(use_with nping) $(use_with nping)
$(use_with nse liblua)
$(use_with ssl openssl) $(use_with ssl openssl)
$(use_with zenmap) $(use_with zenmap)
$(usex libssh2 --with-zlib) $(usex libssh2 --with-zlib)
$(usex nse --with-liblua=$(usex system-lua yes included '' '') --without-liblua)
$(usex nse --with-zlib) $(usex nse --with-zlib)
--cache-file="${S}"/config.cache --cache-file="${S}"/config.cache
# The bundled libdnet is incompatible with the version available in the # The bundled libdnet is incompatible with the version available in the