|
@@ -7,10 +7,9 @@
|
|
NMAP_VERSION = 7.60
|
|
NMAP_VERSION = 7.60
|
|
NMAP_SITE = https://nmap.org/dist
|
|
NMAP_SITE = https://nmap.org/dist
|
|
NMAP_SOURCE = nmap-$(NMAP_VERSION).tar.bz2
|
|
NMAP_SOURCE = nmap-$(NMAP_VERSION).tar.bz2
|
|
-NMAP_DEPENDENCIES = libpcap pcre host-autoconf
|
|
|
|
|
|
+NMAP_DEPENDENCIES = libpcap host-autoconf
|
|
NMAP_CONF_OPTS = --without-liblua --without-zenmap \
|
|
NMAP_CONF_OPTS = --without-liblua --without-zenmap \
|
|
- --with-libdnet=included --with-liblinear=included \
|
|
|
|
- --with-libpcre="$(STAGING_DIR)/usr" --without-ncat
|
|
|
|
|
|
+ --with-libdnet=included --with-liblinear=included
|
|
NMAP_LICENSE = GPL-2.0
|
|
NMAP_LICENSE = GPL-2.0
|
|
NMAP_LICENSE_FILES = COPYING
|
|
NMAP_LICENSE_FILES = COPYING
|
|
|
|
|
|
@@ -51,11 +50,52 @@ else
|
|
NMAP_CONF_OPTS += --without-openssl
|
|
NMAP_CONF_OPTS += --without-openssl
|
|
endif
|
|
endif
|
|
|
|
|
|
-# ndiff only works with python2.x
|
|
|
|
-ifeq ($(BR2_PACKAGE_PYTHON),y)
|
|
|
|
|
|
+NMAP_INSTALL_TARGET_OPTS = DESTDIR=$(TARGET_DIR)
|
|
|
|
+
|
|
|
|
+ifeq ($(BR2_PACKAGE_NMAP_NCAT),y)
|
|
|
|
+NMAP_CONF_OPTS += --with-ncat
|
|
|
|
+NMAP_MAKE_OPTS += build-ncat
|
|
|
|
+NMAP_INSTALL_TARGET_OPTS += install-ncat
|
|
|
|
+else
|
|
|
|
+NMAP_CONF_OPTS += --without-ncat
|
|
|
|
+endif
|
|
|
|
+
|
|
|
|
+ifeq ($(BR2_PACKAGE_NMAP_NDIFF),y)
|
|
NMAP_DEPENDENCIES += python
|
|
NMAP_DEPENDENCIES += python
|
|
|
|
+NMAP_CONF_OPTS += --with-ndiff
|
|
|
|
+NMAP_MAKE_OPTS += build-ndiff
|
|
|
|
+NMAP_INSTALL_TARGET_OPTS += install-ndiff
|
|
else
|
|
else
|
|
NMAP_CONF_OPTS += --without-ndiff
|
|
NMAP_CONF_OPTS += --without-ndiff
|
|
endif
|
|
endif
|
|
|
|
|
|
|
|
+ifeq ($(BR2_PACKAGE_NMAP_NMAP),y)
|
|
|
|
+NMAP_DEPENDENCIES += pcre
|
|
|
|
+NMAP_CONF_OPTS += --with-libpcre="$(STAGING_DIR)/usr"
|
|
|
|
+NMAP_MAKE_OPTS += nmap
|
|
|
|
+NMAP_INSTALL_TARGET_OPTS += install-nmap
|
|
|
|
+endif
|
|
|
|
+
|
|
|
|
+ifeq ($(BR2_PACKAGE_NMAP_NPING),y)
|
|
|
|
+NMAP_CONF_OPTS += --with-nping
|
|
|
|
+NMAP_MAKE_OPTS += build-nping
|
|
|
|
+NMAP_INSTALL_TARGET_OPTS += install-nping
|
|
|
|
+else
|
|
|
|
+NMAP_CONF_OPTS += --without-nping
|
|
|
|
+endif
|
|
|
|
+
|
|
|
|
+# If we are going to install ncat, ensure Busybox gets built/installed
|
|
|
|
+# before, so that this package overrides Busybox nc.
|
|
|
|
+ifeq ($(BR2_PACKAGE_NMAP_NCAT)$(BR2_PACKAGE_BUSYBOX),yy)
|
|
|
|
+NMAP_DEPENDENCIES += busybox
|
|
|
|
+endif
|
|
|
|
+
|
|
|
|
+# Add a symlink to "nc" if none of the competing netcats is selected
|
|
|
|
+ifeq ($(BR2_PACKAGE_NMAP_NCAT):$(BR2_PACKAGE_NETCAT)$(BR2_PACKAGE_NETCAT_OPENBSD),y:)
|
|
|
|
+define NMAP_INSTALL_NCAT_SYMLINK
|
|
|
|
+ ln -fs ncat $(TARGET_DIR)/usr/bin/nc
|
|
|
|
+endef
|
|
|
|
+NMAP_POST_INSTALL_TARGET_HOOKS += NMAP_INSTALL_NCAT_SYMLINK
|
|
|
|
+endif
|
|
|
|
+
|
|
$(eval $(autotools-package))
|
|
$(eval $(autotools-package))
|