summaryrefslogtreecommitdiffstats
path: root/main/netcat-openbsd
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2013-10-09 12:16:41 +0000
committerTimo Teräs <timo.teras@iki.fi>2013-10-09 12:16:41 +0000
commitaa1a14671d24b167ecccbf5554ed3e0842fd5e84 (patch)
tree2dae59461b3f9daad7c616ceb753a8c23b4494a1 /main/netcat-openbsd
parent42052fa4858f3a320230c65f0527f1aa901a260a (diff)
downloadaports-aa1a14671d24b167ecccbf5554ed3e0842fd5e84.tar.bz2
aports-aa1a14671d24b167ecccbf5554ed3e0842fd5e84.tar.xz
main/netcat-openbsd: fix musl build
Diffstat (limited to 'main/netcat-openbsd')
-rw-r--r--main/netcat-openbsd/APKBUILD28
-rw-r--r--main/netcat-openbsd/fix-cdefs.patch24
2 files changed, 42 insertions, 10 deletions
diff --git a/main/netcat-openbsd/APKBUILD b/main/netcat-openbsd/APKBUILD
index 5e7a48865..cf4a4cb63 100644
--- a/main/netcat-openbsd/APKBUILD
+++ b/main/netcat-openbsd/APKBUILD
@@ -12,21 +12,22 @@ makedepends="$depends_dev"
install=
subpackages="$pkgname-doc"
source="http://ftp.debian.org/debian/pool/main/n/$pkgname/${pkgname}_${pkgver}.orig.tar.gz
- netcat-openbsd_1.89-4.diff"
+ netcat-openbsd_1.89-4.diff
+ fix-cdefs.patch
+ "
_builddir="$srcdir"/$pkgname-$pkgver.orig
prepare() {
- cd "$_builddir"
+ local i
- for i in ../*.diff
- do
- msg "Applying patch $i"
- patch -p1 -i $i || return 1
+ cd "$_builddir"
+ for i in $source; do
+ case $i in
+ *.patch|*.diff) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
+ esac
done
-
- for i in `cat debian/patches/series`
- do
+ for i in `cat debian/patches/series`; do
echo "Applying patch $i" 1>&2
patch -p1 -i "debian/patches/$i" || return 1
done
@@ -46,4 +47,11 @@ package() {
}
md5sums="7238ce15aae43069e96ba7faf03f153e netcat-openbsd_1.89.orig.tar.gz
-8e88cb91ca8cad6f9a75d3b84e028298 netcat-openbsd_1.89-4.diff"
+8e88cb91ca8cad6f9a75d3b84e028298 netcat-openbsd_1.89-4.diff
+c9161b439eb4c4a75295be39ad32d1ac fix-cdefs.patch"
+sha256sums="72e844dde8a2a7cba61971d493758dbea9ef0b164bccef15fd4a36490dc77f2b netcat-openbsd_1.89.orig.tar.gz
+4faa7854302889e06a376f03b2113beeae5443de59bdc0de155ab1e0902e28e9 netcat-openbsd_1.89-4.diff
+4bf424667b7321a895e48bb9fafcc7b85b578fcecd27d1b982f9e28350429b6c fix-cdefs.patch"
+sha512sums="4e18289c507461fb8257e466ab082a2b18489218c3065af5b4626369cd3acb378f68eb69cfe77ff46d5fba222c12e2bc30dc71c0a88d2921a7e513b926b8b75d netcat-openbsd_1.89.orig.tar.gz
+8ec30df716d91ec26102ecf76a47d456cd287511516319d28a6b99467e256e158789bc2bfafbd5e13b3effd9237c158eefd6cfd5ba014570395813bccf469ef1 netcat-openbsd_1.89-4.diff
+b70e19344c358ece0c5edcafc2be3df3b09c0fcbef95dc21e0bf8fe31593905a3191870cc9bb5eb707d12748d727276a19918c3998277d6f0a9a10954931a0a0 fix-cdefs.patch"
diff --git a/main/netcat-openbsd/fix-cdefs.patch b/main/netcat-openbsd/fix-cdefs.patch
new file mode 100644
index 000000000..e4c341d14
--- /dev/null
+++ b/main/netcat-openbsd/fix-cdefs.patch
@@ -0,0 +1,24 @@
+Only in netcat-openbsd-1.89.orig: atomicio.o
+Only in netcat-openbsd-1.89.orig: openbsd-compat/base64.o
+--- netcat-openbsd-1.89.orig.orig/openbsd-compat/readpassphrase.h
++++ netcat-openbsd-1.89.orig/openbsd-compat/readpassphrase.h
+@@ -31,10 +31,14 @@
+ #define RPP_SEVENBIT 0x10 /* Strip the high bit from input. */
+ #define RPP_STDIN 0x20 /* Read from stdin, not /dev/tty */
+
+-#include <sys/cdefs.h>
++#ifdef __cplusplus
++extern "C" {
++#endif
+
+-__BEGIN_DECLS
+ char * readpassphrase(const char *, char *, size_t, int);
+-__END_DECLS
++
++#ifdef __cplusplus
++};
++#endif
+
+ #endif /* !_READPASSPHRASE_H_ */
+Only in netcat-openbsd-1.89.orig: openbsd-compat/readpassphrase.o
+Only in netcat-openbsd-1.89.orig: socks.o