2005-04-26 15:30:18 +03:00
|
|
|
# $Id$
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=nmap
|
2006-04-01 18:21:14 +03:00
|
|
|
PKG_VERSION:=4.01
|
|
|
|
PKG_RELEASE:=1
|
|
|
|
PKG_MD5SUM:=09c259837b24f6c7385c2c1c49760a7c
|
2005-04-26 15:30:18 +03:00
|
|
|
|
|
|
|
PKG_SOURCE_URL:=http://download.insecure.org/nmap/dist
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
|
|
|
PKG_CAT:=bzcat
|
|
|
|
|
|
|
|
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
2005-05-15 13:03:35 +03:00
|
|
|
PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
|
2005-04-26 15:30:18 +03:00
|
|
|
|
2005-05-15 13:03:35 +03:00
|
|
|
include $(TOPDIR)/package/rules.mk
|
2005-04-26 15:30:18 +03:00
|
|
|
|
2005-05-15 13:03:35 +03:00
|
|
|
$(eval $(call PKG_template,NMAP,nmap,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
|
2005-04-26 15:30:18 +03:00
|
|
|
|
2005-05-15 13:03:35 +03:00
|
|
|
$(PKG_BUILD_DIR)/.configured:
|
|
|
|
(cd $(PKG_BUILD_DIR); rm -rf config.{cache,status} ; \
|
2005-04-26 15:30:18 +03:00
|
|
|
$(TARGET_CONFIGURE_OPTS) \
|
|
|
|
libpcapdir="$(STAGING_DIR)/usr/lib" \
|
|
|
|
CFLAGS="$(TARGET_CFLAGS)" \
|
2005-10-23 04:29:01 +03:00
|
|
|
CXXFLAGS="$(TARGET_CFLAGS) -fno-builtin -fno-rtti -nostdinc++" \
|
2005-04-26 15:30:18 +03:00
|
|
|
CPPFLAGS="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
|
2005-10-23 04:29:01 +03:00
|
|
|
LDFLAGS="-nodefaultlibs -L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
|
2006-01-04 10:37:19 +02:00
|
|
|
LIBS="-luClibc++ -lc -lm -lgcc" \
|
2005-04-26 15:30:18 +03:00
|
|
|
ac_cv_prog_CXX="$(TARGET_CXX)" \
|
|
|
|
./configure \
|
2005-05-15 13:03:35 +03:00
|
|
|
--target=$(GNU_TARGET_NAME) \
|
|
|
|
--host=$(GNU_TARGET_NAME) \
|
|
|
|
--build=$(GNU_HOST_NAME) \
|
|
|
|
--program-prefix="" \
|
|
|
|
--program-suffix="" \
|
|
|
|
--prefix=/usr \
|
|
|
|
--exec-prefix=/usr \
|
|
|
|
--bindir=/usr/bin \
|
|
|
|
--datadir=/usr/share \
|
|
|
|
--includedir=/usr/include \
|
|
|
|
--infodir=/usr/share/info \
|
|
|
|
--libdir=/usr/lib \
|
|
|
|
--libexecdir=/usr/lib \
|
|
|
|
--localstatedir=/var \
|
|
|
|
--mandir=/usr/share/man \
|
|
|
|
--sbindir=/usr/sbin \
|
|
|
|
--sysconfdir=/etc \
|
|
|
|
$(DISABLE_LARGEFILE) \
|
|
|
|
$(DISABLE_NLS) \
|
|
|
|
--without-openssl \
|
2005-06-12 23:16:28 +03:00
|
|
|
--without-nmapfe \
|
2006-04-01 18:21:14 +03:00
|
|
|
--with-libdnet="$(STAGING_DIR)/usr" \
|
2005-05-15 13:03:35 +03:00
|
|
|
--with-libpcap="$(STAGING_DIR)/usr" \
|
|
|
|
--with-libpcre="$(STAGING_DIR)/usr" \
|
2005-04-26 15:30:18 +03:00
|
|
|
);
|
2005-05-20 00:14:18 +03:00
|
|
|
touch $@
|
2005-04-26 15:30:18 +03:00
|
|
|
|
2005-05-15 13:03:35 +03:00
|
|
|
$(PKG_BUILD_DIR)/.built:
|
|
|
|
mkdir -p $(PKG_INSTALL_DIR)
|
|
|
|
$(MAKE) -C $(PKG_BUILD_DIR) \
|
2005-05-20 00:14:18 +03:00
|
|
|
$(TARGET_CONFIGURE_OPTS) \
|
2005-10-02 18:04:05 +03:00
|
|
|
CCOPT="$(TARGET_CFLAGS) -fno-builtin -nostdinc++" \
|
2005-05-15 13:03:35 +03:00
|
|
|
DESTDIR="$(PKG_INSTALL_DIR)" \
|
2005-05-20 00:14:18 +03:00
|
|
|
all install
|
|
|
|
touch $@
|
2005-04-26 15:30:18 +03:00
|
|
|
|
2005-05-15 13:03:35 +03:00
|
|
|
$(IPKG_NMAP):
|
|
|
|
install -d -m0755 $(IDIR_NMAP)/usr/share/nmap
|
2005-04-26 15:30:18 +03:00
|
|
|
for file in mac-prefixes os-fingerprints protocols rpc service-probes services; do \
|
2006-02-02 01:53:19 +02:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/share/nmap/nmap-$$file $(IDIR_NMAP)/usr/share/nmap; \
|
2005-04-26 15:30:18 +03:00
|
|
|
done
|
2005-05-15 13:03:35 +03:00
|
|
|
install -d -m0755 $(IDIR_NMAP)/usr/bin
|
2006-02-02 01:53:19 +02:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/bin/nmap $(IDIR_NMAP)/usr/bin/
|
2005-05-15 13:03:35 +03:00
|
|
|
$(RSTRIP) $(IDIR_NMAP)
|
2005-04-26 15:30:18 +03:00
|
|
|
$(IPKG_BUILD) $(IDIR_NMAP) $(PACKAGE_DIR)
|
2005-06-12 23:16:28 +03:00
|
|
|
|
|
|
|
mostlyclean:
|
|
|
|
$(MAKE) -C $(PKG_BUILD_DIR) clean
|
|
|
|
rm $(PKG_BUILD_DIR)/.built
|