From 9c3785d8ef4e4a6f99236cd98c71e4917f96a7bd Mon Sep 17 00:00:00 2001 From: Juan RP Date: Sat, 9 Jan 2016 07:54:59 +0100 Subject: [PATCH] nfs-utils: simplify and unbreak musl cross. --- srcpkgs/nfs-utils/template | 35 +++++++++++++++++------------------ 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/srcpkgs/nfs-utils/template b/srcpkgs/nfs-utils/template index c9dfa532eee..1f08f9bf659 100644 --- a/srcpkgs/nfs-utils/template +++ b/srcpkgs/nfs-utils/template @@ -1,7 +1,13 @@ # Template file for 'nfs-utils' pkgname=nfs-utils version=1.3.3 -revision=2 +revision=3 +build_style=gnu-configure +configure_args="--with-statduser=nobody --enable-gss --enable-nfsv4 + --with-statedir=/var/lib/nfs --enable-libmount-mount --enable-gss + --enable-uuid --enable-ipv6 --without-tcp-wrappers + --with-tirpcinclude=$XBPS_CROSS_BASE/usr/include/tirpc + --with-krb5=$XBPS_CROSS_BASE" short_desc="Network File System utilities" maintainer="Juan RP " license="GPL-2" @@ -9,7 +15,7 @@ homepage="http://nfs.sourceforge.net" distfiles="${KERNEL_SITE}/utils/${pkgname}/${version}/${pkgname}-${version}.tar.xz" checksum=700d689c5622c87953c34102e5befafc4d3c811e676852238f0dd79c9c0c084d -hostmakedepends="pkg-config" +hostmakedepends="pkg-config libtirpc-devel" makedepends="libblkid-devel libmount-devel libtirpc-devel libnfsidmap-devel keyutils-devel libevent-devel mit-krb5-devel libevent-devel device-mapper-devel libcap-devel sqlite-devel" @@ -22,23 +28,16 @@ make_dirs=" /etc/exports.d 0750 root root " -do_configure() { - configure_args+=" --with-statduser=nobody --enable-gss --enable-nfsv4 - --with-statedir=/var/lib/nfs --enable-libmount-mount - --without-tcp-wrappers --enable-gss --enable-uuid --enable-ipv6 - --sbindir=/usr/bin " - - ./configure ${configure_args} \ - --with-tirpcinclude=$XBPS_CROSS_BASE/usr/include/tirpc \ - --with-krb5=$XBPS_CROSS_BASE \ - CC_FOR_BUILD="$CC" CFLAGS_FOR_BUILD="$CFLAGS" +pre_build() { + case "$XBPS_TARGET_MACHINE" in + *-musl) + sed -i '/SUBDIRS/s,tools,,' Makefile.in + cd tools/rpcgen + make CC=cc CFLAGS= CPPFLAGS= LDFLAGS= ${makejobs} + ;; + esac } -do_build() { - make ${makejobs} -} -do_install() { - make DESTDIR=${DESTDIR} install - +post_install() { mv ${DESTDIR}/sbin/* ${DESTDIR}/usr/bin # conffiles vconf ${FILESDIR}/exports