Subject: [alpine-devel] [PATCH] extra/nmap: new aport

From: Leonardo Arena <[email-masked]>
Date: Fri, 20 Feb 2009 10:27:40 +0100

i've enabled lua because even --without-liblua insisted to compile NMap
Scripting Engine (NSE).
I've put NSE under a subpackage.
leo
From 1270dafc607390c213043af990d6624e95bb1def Mon Sep 17 00:00:00 2001
From: Leonardo Arena <[email-masked]>
Date: Fri, 20 Feb 2009 09:23:34 +0000
Subject: [PATCH] extra/nmap: new aport

---
 extra/nmap/APKBUILD |   38 ++++++++++++++++++++++++++++++++++++++
 1 files changed, 38 insertions(+), 0 deletions(-)
 create mode 100644 extra/nmap/APKBUILD

diff --git a/extra/nmap/APKBUILD b/extra/nmap/APKBUILD
new file mode 100644
index 0000000..ae7be5e
--- /dev/null
+++ b/extra/nmap/APKBUILD
@@ -0,0 +1,38 @@
+# Contributor: Leonardo Arena <[email-masked]>
+# Maintainer: Leonardo Arena <[email-masked]>
+pkgname=nmap 
+pkgver=4.76
+pkgrel=0
+pkgdesc="A network exploration tool and security/port scanner"
+url="http:/nmap.org"
+license="custom:GPL"
+depends="pcre libpcap openssl-dev lua-dev"
+makedepends="g++"
+install=
+subpackages="$pkgname-doc $pkgname-nse"
+source="http://nmap.org/dist/$pkgname-$pkgver.tgz"
+
+build() {
+	cd "$srcdir/$pkgname-$pkgver"
+
+	./configure --prefix=/usr \
+		--sysconfdir=/etc \
+		--mandir=/usr/share/man \
+		--infodir=/usr/share/info \
+		--without-zenmap \
+		--with-liblua=/usr/include \
+		--with-openssl=/usr/lib
+	make || return 1
+	make DESTDIR="$pkgdir" install
+
+	# install custom GPL2 license
+	install -D -m644 COPYING ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
+}
+
+nse() {
+	mkdir -p "$subpkgdir"/usr/share/$pkgname
+	mv "$pkgdir"/usr/share/$pkgname/nselib "$subpkgdir"/usr/share/$pkgname/
+	mv "$pkgdir"/usr/share/$pkgname/scripts "$subpkgdir"/usr/share/$pkgname/
+}
+
+md5sums="54b5c9e3f44c1adde17df68170eb7cfe  nmap-4.76.tgz"
-- 
1.6.1.3

---

From: Leonardo Arena <[email-masked]>
Date: Fri, 20 Feb 2009 10:35:31 +0100

ouch!

I think i forgot uclibc as depends..
pls discard previous patch
leo

---

---

From: Natanael Copa <[email-masked]>
Date: Fri, 20 Feb 2009 11:36:04 +0100

On Fri, 2009-02-20 at 10:35 +0100, Leonardo Arena wrote:
>         i've enabled lua because even --without-liblua insisted to
>         compile NMap Scripting Engine (NSE).

nclab01:~/aports/extra/nmap$ scanelf -Rn pkg
 TYPE   NEEDED FILE 
ET_DYN libssl.so.0.9.8,libcrypto.so.0.9.8,liblua.so.5,libstdc++.so.6,libm.so.0,libgcc_s.so.1,libc.so.0,ld-uClibc.so.0 pkg/usr/bin/nmap 

note the libstdc++. It meas it needs g++ as a runtime dependency.

I think what we really want is use uclibc++ for this.

Do do that, add uclibc++-dev to makedepends and:

export CXX=g++-uc

that works normally without any more modification, but I think that nmap
needs one or 2 patches (unless those are committed to upstream nowdays)

I can take a look at it.

Thanks!

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---