openbsd-netcat: use create_wrksrc

This commit is contained in:
Đoàn Trần Công Danh 2022-10-27 18:59:03 +07:00
parent 250c159cc9
commit 1c4973ed20
1 changed files with 7 additions and 3 deletions

View File

@ -2,7 +2,7 @@
pkgname=openbsd-netcat
version=1.219
revision=1
wrksrc="netcat-openbsd-${version%p*}"
create_wrksrc=yes
hostmakedepends="pkg-config"
makedepends="libbsd-devel"
short_desc="TCP/IP swiss army knife (OpenBSD/Debian variant)"
@ -19,8 +19,12 @@ alternatives="
nc:nc:/usr/bin/openbsd-nc
nc:nc.1:/usr/share/man/man1/openbsd-nc.1"
post_extract() {
mv netcat-openbsd-${version}/* .
( cd debian/patches; xargs cat <series; ) | patch -p1
}
do_build() {
( cd ../debian/patches; xargs cat <series; ) | patch -p1
case "$XBPS_TARGET_MACHINE" in
*-musl) # Add missing b64_ntop() and b64_pton() functions
cp ${FILESDIR}/base64.c .
@ -35,5 +39,5 @@ do_build() {
do_install() {
vbin nc openbsd-nc
vman nc.1 openbsd-nc.1
vlicense ../debian/copyright LICENSE
vlicense debian/copyright LICENSE
}