qLinux
… a distribution study
<< Prev Keyutils-1.6.1
Next >> Fcron-3.2.1
Download: nfs-utils-2.6.1.tar.xz.
./configure --prefix=/qlnx \ LDFLAGS="-L/libs/lib" CFLAGS="-I/libs/inc" CPPFLAGS="$CFLAGS" \ --with-rpcgen=internal \ --with-statdpath=/qlnx/var/nfs \ --with-pluginpath=/qlnx/lib/libnfsidmap \ --disable-ldap \ --disable-nfsdcld \ --disable-nfsdcltrack \ --disable-uuid \ --disable-nfsv41 \ --disable-gss \ --enable-libmount-mount \ --disable-sbin-override \ --includedir=/qlnx/inc \ --mandir=/qlnx/man \ --with-statedir=/qlnx/var/nfs \ --with-mountfile=/qlnx/etc/nfsmounts.conf \ --with-statdpath=/qlnx/var/nfs \ --with-nfsconfig=/qlnx/etc/nfs.conf \ --with-start-statd=/qlnx/bin/start-statd \ --sysconfdir=/qlnx/etc --disable-mount \ --disable-caps
Some note to the configure options, based on my own experience:
LDFLAGS=“-L/libs/lib” CFLAGS=“-I/libs/inc” CPPFLAGS=“$CFLAGS”
    Unfortunately the build system doesn't recognize pkg-config correctly.
–with-rpcgen=internal
    We don't have any external rpc package.
–disable-nfsdcld, –disable-nfsdcltrack, –disable-gss, –disable-nfsv41
    These options requires external packages (e.g. sqlite) which are not available yet.
–enable-libmount-mount
    Link mount.nfs with libmount.
Fix the newly created file  libtool 
sed -i '/qlnx\/dev\/null/!s|dev/null|/qlnx/dev/null|g' libtool
Build and install the package:
make make install
Remove a useless file:
rm /qlnx/man/man7/nfs.systemd.7
Move the admin executables to the desired location:
chmod 0750 /qlnx/sbin/* mv -v /qlnx/sbin/* /qlnx/bin/ rmdir /qlnx/sbin
If not done yet create a user and group:
groupadd -g 65534 nogroup useradd -u 65534 -g nogroup -d /qlnx/dev/null -s /qlnx/bin/nologin nobody chown nobody.nogroup /qlnx/var/nfs
        rpcgen, exportfs, nfsconf nfsidmap nfsstat rpc.mountd rpc.statd showmount start-statd mount.nfs4 umount.nfs4 mount.nfs, umount.nfs mount.nfs mountstats nfsdclnts nfsiostat rpc.idmapd rpc.nfsd rpcdebug sm-notify
        rpcgen.1, nfs4_uid_to_name.3, exports.5 idmapd.conf.5 nfs.5 nfs.conf.5 nfsmount.conf.5, nfsd.7, exportfs.8 mountd.8 nfsd.8 nfsiostat.8 rpc.mountd.8 rpc.statd.8 sm-notify.8 idmapd.8 mountstats.8 nfsdclnts.8 nfsstat.8 rpc.nfsd.8 rpcdebug.8 statd.8 mount.nfs.8 nfsconf.8 nfsidmap.8 rpc.idmapd.8 rpc.sm-notify.8 showmount.8 umount.nfs.8
        nfsidmap.h nfsidmap_plugin.h
        libnfsidmap.a libnfsidmap.la libnfsidmap.so libnfsidmap.so.1 libnfsidmap.so.1.0.0, libnfsimap.pc
        /qlnx/var/nfs/*, /qlnx/lib/libnfsidmap/*
<< Prev Keyutils-1.6.1
Next >> Fcron-3.2.1