summaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorWilliam Pitcock <nenolod@dereferenced.org>2014-04-03 09:54:00 +0000
committerWilliam Pitcock <nenolod@dereferenced.org>2014-04-03 09:54:00 +0000
commitd775866336cf6ef05fde1d4ccf25431598bfed0c (patch)
tree48bb1dd65b18e03fe4ff8a790fabb75233cf44df /main
parentc674892267ce993b91b71b35c32ac558c75ad5b1 (diff)
downloadaports-d775866336cf6ef05fde1d4ccf25431598bfed0c.tar.bz2
aports-d775866336cf6ef05fde1d4ccf25431598bfed0c.tar.xz
main/socat: fix musl build and upgrade to 1.7.2.4
Diffstat (limited to 'main')
-rw-r--r--main/socat/APKBUILD30
-rw-r--r--main/socat/netdb-internal.patch13
-rw-r--r--main/socat/use-linux-headers.patch11
3 files changed, 49 insertions, 5 deletions
diff --git a/main/socat/APKBUILD b/main/socat/APKBUILD
index e25aaf942..2a598dbb8 100644
--- a/main/socat/APKBUILD
+++ b/main/socat/APKBUILD
@@ -1,7 +1,7 @@
# Contributor: Kiyoshi Aman <kiyoshi.aman@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=socat
-pkgver=1.7.2.2
+pkgver=1.7.2.4
pkgrel=0
pkgdesc="Multipurpose relay for binary protocols"
url="http://www.dest-unreach.org/socat/"
@@ -10,9 +10,23 @@ license="GPL"
depends=
makedepends="openssl-dev readline-dev"
subpackages="$pkgname-doc"
-source="http://www.dest-unreach.org/$pkgname/download/$pkgname-$pkgver.tar.bz2"
+source="http://www.dest-unreach.org/$pkgname/download/$pkgname-$pkgver.tar.bz2
+ use-linux-headers.patch
+ netdb-internal.patch"
_builddir="$srcdir/$pkgname-$pkgver"
+prepare() {
+ cd "$_builddir"
+ for i in $source; do
+ case $i in
+ *.patch)
+ msg "Applying $i..."
+ patch -s -p1 -N -i "$srcdir"/$i || return 1
+ ;;
+ esac
+ done
+}
+
build() {
cd "$_builddir"
./configure \
@@ -34,6 +48,12 @@ package() {
make DESTDIR="$pkgdir" install || return 1
}
-md5sums="39231e512d8052f328552865df15d42f socat-1.7.2.2.tar.bz2"
-sha256sums="9a167af11a4d3809cbc66f5e2dcb39b6e371251282ef5de6ea6ff0c4be8a953c socat-1.7.2.2.tar.bz2"
-sha512sums="712a9e061139ffc38552db9321bac143f22da85852dc8b30148c5fb3b4209d4a963a62948aaf9eb35f63b23b4b6459627effb5a2b6757b70ddecffe31860b73b socat-1.7.2.2.tar.bz2"
+md5sums="69b8155dd442a6f24e28ef5407d868eb socat-1.7.2.4.tar.bz2
+c87e489c0cb4baa22c8a051fab022f03 use-linux-headers.patch
+66d19b98f4de8d8f1f4d67924c9d3da6 netdb-internal.patch"
+sha256sums="4b7739901c6fad1e460f3e5b1868fb4c2a1427febbba7a510cd2e42fd4941e09 socat-1.7.2.4.tar.bz2
+609f0499d9c61cff6aa4b9be2fa4a7051463de986742f5af5181af1c7238ae86 use-linux-headers.patch
+ff671b41583a974f439c3ee8d223422d6f23ad508f404a4fbc240336eeb447a3 netdb-internal.patch"
+sha512sums="256a3fba171544733cbfd6efde884cb9f5ff52e2b5300cebbe712cbb79d3e3bc7142e2e8a93fe4faf944db8326ab2c3673ef37ef76b724f33bf65cc0f9fbf27b socat-1.7.2.4.tar.bz2
+2032b6528cb27b69d8fb6a6f64af32fcc1f6e4934bb0d7c8931b38ab7ad5e27f6f4344a6cf49751fa3178cd725f954e195373362f7d5929e587d7f0309346059 use-linux-headers.patch
+22a6e0c2317a9317997c98114daac258ebbcc3d8e58e49a6ebf24781b98967afed47c63807282582fa0909076fe349281f05e4462faacb90e7aabc853903d6e6 netdb-internal.patch"
diff --git a/main/socat/netdb-internal.patch b/main/socat/netdb-internal.patch
new file mode 100644
index 000000000..d1ebc8e5b
--- /dev/null
+++ b/main/socat/netdb-internal.patch
@@ -0,0 +1,13 @@
+--- socat-1.7.2.4.orig/compat.h
++++ socat-1.7.2.4/compat.h
+@@ -656,6 +656,10 @@
+ # define NETDB_INTERNAL h_NETDB_INTERNAL
+ #endif
+
++#if !defined(NETDB_INTERNAL)
++# define NETDB_INTERNAL (-1)
++#endif
++
+ #ifndef INET_ADDRSTRLEN
+ # define INET_ADDRSTRLEN sizeof(struct sockaddr_in)
+ #endif
diff --git a/main/socat/use-linux-headers.patch b/main/socat/use-linux-headers.patch
new file mode 100644
index 000000000..5ef90ac84
--- /dev/null
+++ b/main/socat/use-linux-headers.patch
@@ -0,0 +1,11 @@
+--- socat-1.7.2.4.orig/sysincludes.h
++++ socat-1.7.2.4/sysincludes.h
+@@ -134,7 +134,7 @@
+ #include <netpacket/packet.h>
+ #endif
+ #if HAVE_NETINET_IF_ETHER_H
+-#include <netinet/if_ether.h>
++#include <linux/if_ether.h>
+ #endif
+ #if HAVE_LINUX_IF_TUN_H
+ #include <linux/if_tun.h>