# Maintainer: Gabor Pali pkgname=socat pkgver=1.8.0.0 pkgrel=0 # base: 0 pkgdesc="Multipurpose relay for binary protocols (stripped)" options="!check" url="http://www.dest-unreach.org/socat/" arch="all" license="GPL-2.0-only WITH OpenSSL-Exception" makedepends="linux-headers" subpackages="$pkgname-with-udp:_udp" source="http://www.dest-unreach.org/socat/download/socat-$pkgver.tar.gz use-linux-headers.patch netdb-internal.patch no-extras.patch " _srcdir="$srcdir"/"$pkgname"-"$pkgver" _stripped_build_dir="$srcdir"/build-stripped _with_udp_build_dir="$srcdir"/build-with-udp prepare() { default_prepare mkdir -p \ "$_stripped_build_dir" \ "$_with_udp_build_dir" } _options="--srcdir=$_srcdir --build=$CBUILD --host=$CHOST --disable-stdio --disable-fdnum --disable-file --disable-creat --disable-gopen --disable-pipe --disable-socketpair --disable-shell --disable-stats --disable-ip6 --disable-rawip --disable-genericsocket --disable-interface --disable-sctp --disable-dccp --disable-vsock --disable-namespaces --disable-posixmq --disable-socks4 --disable-socks4a --disable-socks5 --disable-proxy --disable-exec --disable-system --disable-pty --disable-fs --disable-readline --disable-openssl --disable-tun --disable-sycls --disable-filan --disable-retry --disable-libwrap --prefix=/usr" build() { msg "Building stripped (strict)" cd "$_stripped_build_dir" "$_srcdir"/configure \ $_options \ --disable-udp make -j8 msg "Building with UDP" cd "$_with_udp_build_dir" "$_srcdir"/configure \ $_options make -j8 } package() { cd "$_stripped_build_dir" make DESTDIR="$pkgdir" install } _udp() { pkgdesc="Multipurpose relay for binary protocols (with UDP enabled)" provides="socat" mkdir -p "$subpkgdir" cd "$_with_udp_build_dir" make DESTDIR="$subpkgdir" install } sha512sums=" edf459a9f1907a14025e13b3101ad29787f9a72795cffcd00017ce98847562884db29a95b9ae478a6a50868137548b142947c43fb18e975eb5853a763c42902c socat-1.8.0.0.tar.gz 2032b6528cb27b69d8fb6a6f64af32fcc1f6e4934bb0d7c8931b38ab7ad5e27f6f4344a6cf49751fa3178cd725f954e195373362f7d5929e587d7f0309346059 use-linux-headers.patch 22a6e0c2317a9317997c98114daac258ebbcc3d8e58e49a6ebf24781b98967afed47c63807282582fa0909076fe349281f05e4462faacb90e7aabc853903d6e6 netdb-internal.patch 017c0b51e416ae7f199885d808173b40ba72a419dbe946d692a044a81dcffd0c38e40a99abb7d1cbed01d132c5a9adfc5f9a1de1fe4e8a4ff7d22ed7b0ec53d3 no-extras.patch "