2019-08-04 16:11:47 +00:00
|
|
|
# Maintainer: AndyRTR <andyrtr@archlinux.org>
|
|
|
|
# Maintainer: Tobias Powalowski <tpowa@archlinux.org>
|
|
|
|
# Contributor: John Proctor <jproctor@prium.net>
|
|
|
|
# Contributor: dibblethewrecker <dibblethewrecker.at.jiwe.org>
|
|
|
|
# Contributor: abelstr <abel@pinklf.eu>
|
|
|
|
# Contributor: Marco Lima <cipparello gmail com>
|
|
|
|
|
|
|
|
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
|
|
|
|
# - set -D_FILE_OFFSET_BITS=64 in CFLAGS
|
|
|
|
|
|
|
|
pkgbase=nfs-utils
|
|
|
|
pkgname=('nfs-utils' 'nfsidmap')
|
2022-01-26 06:57:47 +00:00
|
|
|
pkgver=2.6.1
|
|
|
|
pkgrel=1
|
2019-08-04 16:11:47 +00:00
|
|
|
arch=('x86_64')
|
|
|
|
url='http://nfs.sourceforge.net'
|
2020-06-28 16:59:01 +00:00
|
|
|
makedepends=('libevent' 'sqlite' 'rpcsvc-proto' 'device-mapper')
|
2019-08-04 16:11:47 +00:00
|
|
|
# http://git.linux-nfs.org/?p=steved/nfs-utils.git;a=summary
|
|
|
|
source=(https://www.kernel.org/pub/linux/utils/${pkgname}/${pkgver}/${pkgname}-${pkgver}.tar.{xz,sign}
|
|
|
|
exports)
|
2022-01-26 06:57:47 +00:00
|
|
|
# https://mirrors.edge.kernel.org/pub/linux/utils/nfs-utils/2.6.1/sha256sums.asc
|
|
|
|
sha256sums=('60dfcd94a9f3d72a12bc7058d811787ec87a6d593d70da2123faf9aad3d7a1df'
|
2019-08-04 16:11:47 +00:00
|
|
|
'SKIP'
|
2022-01-26 06:57:47 +00:00
|
|
|
'b8238b74179f7e1626db2b637671ddc17288a1c5b7692954ae6d2fbb1be3788d')
|
2019-08-04 16:11:47 +00:00
|
|
|
validpgpkeys=('E1B71E339E20A10A676F7CB69AFB1D681A125177') # Steve Dickson
|
|
|
|
|
|
|
|
prepare() {
|
2019-11-19 02:32:28 +00:00
|
|
|
cd "${pkgbase}"-${pkgver}
|
2019-08-04 16:11:47 +00:00
|
|
|
|
|
|
|
# fix hardcoded sbin path to our needs
|
|
|
|
sed -i "s|sbindir = /sbin|sbindir = /usr/bin|g" utils/*/Makefile.am
|
2019-11-19 02:32:28 +00:00
|
|
|
sed -i "s|sbin|bin|" utils/nfsidmap/id_resolver.conf
|
2019-08-04 16:11:47 +00:00
|
|
|
autoreconf -vfi
|
|
|
|
}
|
|
|
|
|
|
|
|
build() {
|
2019-11-19 02:32:28 +00:00
|
|
|
cd "${pkgbase}"-${pkgver}
|
2019-08-04 16:11:47 +00:00
|
|
|
CFLAGS+=" -D_FILE_OFFSET_BITS=64"
|
|
|
|
./configure --prefix=/usr \
|
|
|
|
--sbindir=/usr/bin \
|
|
|
|
--sysconfdir=/etc \
|
2021-02-24 14:55:36 +00:00
|
|
|
--enable-nfsv4server \
|
2019-08-04 16:11:47 +00:00
|
|
|
--enable-gss \
|
|
|
|
--without-tcp-wrappers \
|
|
|
|
--with-statedir=/var/lib/nfs \
|
|
|
|
--enable-ipv6 \
|
|
|
|
--enable-libmount-mount \
|
|
|
|
--enable-mountconfig \
|
2020-10-29 13:53:09 +00:00
|
|
|
--with-start-statd=/usr/bin/start-statd \
|
|
|
|
--with-systemd
|
|
|
|
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
|
2019-08-04 16:11:47 +00:00
|
|
|
make
|
|
|
|
}
|
|
|
|
|
|
|
|
check() {
|
2019-11-19 02:32:28 +00:00
|
|
|
cd "${pkgbase}"-${pkgver}
|
2019-08-04 16:11:47 +00:00
|
|
|
make -k check || /bin/true
|
|
|
|
}
|
|
|
|
|
|
|
|
package_nfs-utils() {
|
|
|
|
|
|
|
|
pkgdesc="Support programs for Network File Systems"
|
|
|
|
license=('GPL2')
|
|
|
|
|
2020-02-18 19:16:16 +00:00
|
|
|
backup=(etc/{exports,nfs.conf,nfsmount.conf}
|
|
|
|
var/lib/nfs/{etab,rmtab})
|
2019-08-04 16:11:47 +00:00
|
|
|
depends=('rpcbind' 'nfsidmap' 'gssproxy' 'libevent' 'device-mapper')
|
|
|
|
optdepends=('sqlite: for nfsdcltrack usage'
|
2020-06-28 16:59:01 +00:00
|
|
|
'python: for nfsiostat, nfsdclnts and mountstats usage')
|
2019-08-04 16:11:47 +00:00
|
|
|
|
2019-11-19 02:32:28 +00:00
|
|
|
cd "${pkgbase}"-${pkgver}
|
2019-08-04 16:11:47 +00:00
|
|
|
make DESTDIR="$pkgdir" install
|
|
|
|
|
|
|
|
install -D -m 644 utils/mount/nfsmount.conf "$pkgdir"/etc/nfsmount.conf
|
|
|
|
install -D -m 644 nfs.conf "$pkgdir"/etc/nfs.conf
|
|
|
|
|
|
|
|
install -d -m 755 "$pkgdir"/usr/share/doc/$pkgname
|
|
|
|
install -D -m 644 systemd/README "$pkgdir"/usr/share/doc/$pkgname/README.systemd
|
|
|
|
|
|
|
|
# docs
|
|
|
|
install -m 644 {NEWS,README} "$pkgdir"/usr/share/doc/$pkgname/
|
|
|
|
|
|
|
|
# empty exports file
|
|
|
|
install -D -m 644 ../exports "$pkgdir"/etc/exports
|
|
|
|
|
|
|
|
# config file for idmappers in newer kernels
|
2019-11-19 02:32:28 +00:00
|
|
|
install -D -m 644 utils/nfsidmap/id_resolver.conf "$pkgdir"/etc/request-key.d/id_resolver.conf
|
2019-08-04 16:11:47 +00:00
|
|
|
|
|
|
|
mkdir "$pkgdir"/etc/exports.d
|
|
|
|
mkdir -m 555 "$pkgdir"/var/lib/nfs/rpc_pipefs
|
|
|
|
mkdir "$pkgdir"/var/lib/nfs/v4recovery
|
|
|
|
|
|
|
|
# nfsidmap cleanup
|
2019-11-19 02:32:28 +00:00
|
|
|
rm -vrf "$pkgdir"/usr/include #/nfsid*
|
|
|
|
rm -vrf "$pkgdir"/usr/lib/libnfsidmap*
|
|
|
|
rm -vrf "$pkgdir"/usr/lib/pkgconfig #/libnfsidmap.pc
|
|
|
|
rm -v "$pkgdir"/usr/share/man/{man3/nfs4_uid_to_name*,man5/idmapd.conf*}
|
|
|
|
rm -rf "$pkgdir"/usr/share/man/man3
|
2019-08-04 16:11:47 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
package_nfsidmap() {
|
|
|
|
|
|
|
|
pkgdesc="Library to help mapping IDs, mainly for NFSv4"
|
|
|
|
license=('GPL2')
|
|
|
|
backup=(etc/idmapd.conf)
|
2020-06-28 16:59:01 +00:00
|
|
|
depends=('libldap' 'krb5')
|
2019-08-04 16:11:47 +00:00
|
|
|
|
2019-11-19 02:32:28 +00:00
|
|
|
cd "${pkgbase}"-${pkgver}
|
2019-08-04 16:11:47 +00:00
|
|
|
make -C support DESTDIR="$pkgdir" install
|
|
|
|
# config file
|
|
|
|
install -D -m 644 support/nfsidmap/idmapd.conf "$pkgdir"/etc/idmapd.conf
|
|
|
|
# license
|
|
|
|
install -Dm644 support/nfsidmap/COPYING $pkgdir/usr/share/licenses/nfsidmap/LICENSE
|
|
|
|
}
|