* add libnatpmp

This commit is contained in:
Alexander Baldeck 2024-08-03 11:18:49 +02:00
parent 94cf02dccf
commit 904135144a
2 changed files with 48 additions and 0 deletions

12
libnatpmp/.SRCINFO Normal file
View File

@ -0,0 +1,12 @@
pkgbase = libnatpmp
pkgdesc = A portable and fully compliant implementation of the NAT-PMP protocol
pkgver = 20230423
pkgrel = 3
url = http://miniupnp.free.fr/libnatpmp.html
arch = x86_64
license = BSD
depends = glibc
source = https://miniupnp.tuxfamily.org/files/libnatpmp-20230423.tar.gz
sha256sums = 0684ed2c8406437e7519a1bd20ea83780db871b3a3a5d752311ba3e889dbfc70
pkgname = libnatpmp

36
libnatpmp/PKGBUILD Normal file
View File

@ -0,0 +1,36 @@
# POWER Maintainer: Alexander Baldeck <alex.bldck@gmail.com>
# Maintainer: Baptiste Jonglez <baptiste--aur at jonglez dot org>
# Contributor: Anatol Pomozov <anatol dot pomozov at gmail>
# Contributor: Gustavo Alvarez <s1pkn07@gmail.com>
# Contributor: Kristjan Reinloo <mail at kreinloo dot net>
# Contributor: Pierre Bourdon <delroth@gmail.com>
pkgname=libnatpmp
pkgver=20230423
pkgrel=3
pkgdesc='A portable and fully compliant implementation of the NAT-PMP protocol'
arch=(x86_64 powerpc64le powerpc64 powerpc riscv64)
url='http://miniupnp.free.fr/libnatpmp.html'
license=(BSD)
depends=(glibc)
source=("https://miniupnp.tuxfamily.org/files/libnatpmp-$pkgver.tar.gz")
sha256sums=('0684ed2c8406437e7519a1bd20ea83780db871b3a3a5d752311ba3e889dbfc70')
prepare() {
cd $pkgname-$pkgver
sed -e 's/CFLAGS = /CFLAGS += /' -i Makefile
}
build() {
cd $pkgname-$pkgver
make
}
package() {
cd $pkgname-$pkgver
make INSTALLPREFIX="$pkgdir/usr" INSTALLDIRINC="$pkgdir/usr/include" install
# Install missing header
install -Dm644 natpmp_declspec.h -t "$pkgdir"/usr/include
install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
install -Dm644 natpmpc.1 "$pkgdir/usr/share/man/man1/natpmpc.1"
}