1 # Maintainer: AndyRTR <andyrtr@archlinux.org>
2 # Maintainer: Tobias Powalowski <tpowa@archlinux.org>
3 # Contributor: John Proctor <jproctor@prium.net>
4 # Contributor: dibblethewrecker <dibblethewrecker.at.jiwe.org>
5 # Contributor: abelstr <abel@pinklf.eu>
6 # Contributor: Marco Lima <cipparello gmail com>
9 pkgname=('nfs-utils' 'nfsidmap')
13 url='http://nfs.sourceforge.net'
14 makedepends=('libevent' 'sqlite' 'rpcsvc-proto' 'device-mapper')
15 # http://git.linux-nfs.org/?p=steved/nfs-utils.git;a=summary
16 source=(https://www.kernel.org/pub/linux/utils/${pkgname}/${pkgver}/${pkgname}-${pkgver}.tar.{xz,sign}
19 # https://mirrors.edge.kernel.org/pub/linux/utils/nfs-utils/2.6.3/sha256sums.asc
20 sha256sums=('38d89e853a71d3c560ff026af3d969d75e24f782ff68324e76261fe0344459e1'
22 'b8238b74179f7e1626db2b637671ddc17288a1c5b7692954ae6d2fbb1be3788d'
23 '8e1b6aa59cf5539b9da13cfec217b3ca7b6c32e08df3b0a204901ed2891b2ded')
24 validpgpkeys=('E1B71E339E20A10A676F7CB69AFB1D681A125177') # Steve Dickson
27 cd "${pkgbase}"-${pkgver}
29 # fix hardcoded sbin/libexec path to our needs
30 sed -i "s|sbindir = /sbin|sbindir = /usr/bin|g" utils/*/Makefile.am
31 sed -i "s|sbin|bin|" utils/nfsidmap/id_resolver.conf
32 sed -i "s|libexec|bin|" tools/nfsrahead/99-nfs.rules
37 cd "${pkgbase}"-${pkgver}
38 ./configure --prefix=/usr \
41 --libexecdir=/usr/bin \
42 --with-statedir=/var/lib/nfs \
43 --with-statdpath=/var/lib/nfs/statd \
44 --with-start-statd=/usr/bin/start-statd \
45 --enable-nfsv4server \
47 --without-tcp-wrappers \
49 --enable-libmount-mount \
50 --enable-mountconfig \
52 sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
57 cd "${pkgbase}"-${pkgver}
58 #make -k check || /bin/true
64 pkgdesc="Support programs for Network File Systems"
67 backup=(etc/{exports,nfs.conf,nfsmount.conf}
68 var/lib/nfs/{etab,rmtab})
69 depends=('rpcbind' 'nfsidmap' 'gssproxy' 'libevent' 'device-mapper')
70 optdepends=('sqlite: for nfsdcltrack and fsidd usage'
71 'python: for rpcctl, nfsiostat, nfsdclnts and mountstats usage')
73 cd "${pkgbase}"-${pkgver}
74 make DESTDIR="$pkgdir" install
76 install -D -m 644 utils/mount/nfsmount.conf "$pkgdir"/etc/nfsmount.conf
77 install -D -m 644 nfs.conf "$pkgdir"/etc/nfs.conf
79 install -d -m 755 "$pkgdir"/usr/share/doc/$pkgname
80 install -D -m 644 systemd/README "$pkgdir"/usr/share/doc/$pkgname/README.systemd
83 install -m 644 {NEWS,README} "$pkgdir"/usr/share/doc/$pkgname/
86 install -D -m 644 ../exports "$pkgdir"/etc/exports
88 # config file for idmappers in newer kernels
89 install -D -m 644 utils/nfsidmap/id_resolver.conf "$pkgdir"/etc/request-key.d/id_resolver.conf
91 mkdir "$pkgdir"/etc/exports.d
92 mkdir -m 555 "$pkgdir"/var/lib/nfs/rpc_pipefs
93 mkdir "$pkgdir"/var/lib/nfs/v4recovery
95 # systemd sysusers - FS#75536
96 install -D -m 644 ../sysusers.d "${pkgdir}"/usr/lib/sysusers.d/rpcuser.conf
97 chown -Rv 34:34 "${pkgdir}"/var/lib/nfs/statd
98 chmod -R 700 "${pkgdir}"/var/lib/nfs/statd
99 chmod 644 "${pkgdir}"/var/lib/nfs/statd/state
102 rm -vrf "$pkgdir"/usr/include #/nfsid*
103 rm -vrf "$pkgdir"/usr/lib/libnfsidmap*
104 rm -vrf "$pkgdir"/usr/lib/pkgconfig #/libnfsidmap.pc
105 rm -v "$pkgdir"/usr/share/man/{man3/nfs4_uid_to_name*,man5/idmapd.conf*}
106 rm -rf "$pkgdir"/usr/share/man/man3
111 pkgdesc="Library to help mapping IDs, mainly for NFSv4"
113 backup=(etc/idmapd.conf)
114 depends=('libldap' 'krb5')
116 cd "${pkgbase}"-${pkgver}
117 make -C support DESTDIR="$pkgdir" install
120 rm -v "$pkgdir"/usr/bin/fsidd
121 rmdir -v "$pkgdir"/usr/bin
124 install -D -m 644 support/nfsidmap/idmapd.conf "$pkgdir"/etc/idmapd.conf
126 install -Dm644 support/nfsidmap/COPYING $pkgdir/usr/share/licenses/nfsidmap/LICENSE