nfs4-acl-tools: Fix build with autoconf-2.7.1.

Added two new patches from gentoo:

- jobserver-unavailable.patch: makes possible to build with -jX (instead of 1
  only)
- libtool.patch: Fixes cross build
This commit is contained in:
André Cerqueira 2022-08-21 18:04:28 +01:00 committed by Michal Vasilek
parent 4a574f492d
commit 9fb07eab7f
4 changed files with 105 additions and 25 deletions

View file

@ -1,20 +0,0 @@
--- a/Makefile 2018-08-21 18:07:51.000000000 +0200
+++ b/Makefile.new 2018-10-02 11:16:49.335221638 +0200
@@ -61,16 +61,7 @@
$(CONFIGURE): aclocal.m4
autoconf
- ./configure \
- --prefix=/ \
- --exec-prefix=/ \
- --sbindir=/bin \
- --bindir=/usr/bin \
- --libdir=/lib \
- --libexecdir=/usr/lib \
- --includedir=/usr/include \
- --mandir=/usr/share/man \
- --datadir=/usr/share \
+ ./configure @configure_args@ \
$$LOCAL_CONFIGURE_OPTIONS
touch .census

View file

@ -0,0 +1,26 @@
From: https://gitweb.gentoo.org/repo/gentoo.git/tree/net-fs/nfs4-acl-tools/files/nfs4-acl-tools-0.3.5-jobserver-unavailable.patch
Fix
* gmake[1]: warning: jobserver unavailable: using -j1. Add '+' to parent make rule.
--- a/include/buildmacros
+++ b/include/buildmacros
@@ -152,7 +152,7 @@ INSTALL_LINGUAS = \
endif
SUBDIRS_MAKERULE = \
- @for d in $(SUBDIRS) ""; do \
+ @+for d in $(SUBDIRS) ""; do \
if test -d "$$d" -a ! -z "$$d"; then \
$(ECHO) === $$d ===; \
$(MAKEF) -C $$d $@ || exit $$?; \
@@ -170,7 +170,7 @@ DIST_MAKERULE = \
$(MAKEF) -C build dist
SOURCE_MAKERULE = \
- @test -z "$$DIR" && DIR="."; \
+ @+test -z "$$DIR" && DIR="."; \
for f in $(SRCFILES) ""; do \
if test ! -z "$$f"; then $(ECHO) $$DIR/$$f; fi;\
done; \

View file

@ -0,0 +1,72 @@
From 2abd5015bf6bac1697ac4422d76fa121a49f2b24 Mon Sep 17 00:00:00 2001
From: orbea <orbea@riseup.net>
Date: Fri, 17 Jun 2022 12:36:01 -0700
Subject: [PATCH] configure: Add missing LT_INIT
Otherwise it fails to generate libtool for the build breaking the build
when using a different toolchain than the system libtool. It also breaks
the build with rlibtool which depends on the generated libtool to
determine if it should build static or shared libraries.
The existing make and libtool tests were removed as unnecessary and
problematic.
--- a/configure.ac
+++ b/configure.ac
@@ -9,6 +9,9 @@ AC_ARG_ENABLE(shared,
enable_shared=no)
AC_SUBST(enable_shared)
+LT_INIT
+
+AC_PROG_LIBTOOL
AC_PROG_INSTALL
AC_PROG_CC
--- a/include/builddefs.in
+++ b/include/builddefs.in
@@ -39,6 +39,8 @@ DEBUG = @debug_build@
OPTIMIZER = @opt_build@
MALLOCLIB = @malloc_lib@
+top_builddir = $(TOPDIR)
+
LIBNFS4ACL = $(TOPDIR)/libnfs4acl/libnfs4acl.la
LIBATTR = @libattr@
@@ -68,7 +70,6 @@ AWK = @awk@
SED = @sed@
TAR = @tar@
ZIP = @zip@
-MAKE = @make@
ECHO = @echo@
SORT = @sort@
LN_S = @LN_S@
--- a/m4/package_utilies.m4
+++ b/m4/package_utilies.m4
@@ -22,26 +22,6 @@ AC_DEFUN([AC_PACKAGE_UTILITIES],
AC_SUBST(cc)
AC_PACKAGE_NEED_UTILITY($1, "$cc", cc, [C compiler])
- if test -z "$MAKE"; then
- AC_PATH_PROG(MAKE, gmake,, /usr/bin:/usr/freeware/bin)
- fi
- if test -z "$MAKE"; then
- AC_PATH_PROG(MAKE, make,, /usr/bin)
- fi
- make=$MAKE
- AC_SUBST(make)
- AC_PACKAGE_NEED_UTILITY($1, "$make", make, [GNU make])
-
- if test -z "$LIBTOOL"; then
- AC_PATH_PROG(LIBTOOL, glibtool,, /usr/bin)
- fi
- if test -z "$LIBTOOL"; then
- AC_PATH_PROG(LIBTOOL, libtool,, /usr/bin:/usr/local/bin:/usr/freeware/bin)
- fi
- libtool=$LIBTOOL
- AC_SUBST(libtool)
- AC_PACKAGE_NEED_UTILITY($1, "$libtool", libtool, [GNU libtool])
-
if test -z "$TAR"; then
AC_PATH_PROG(TAR, tar,, /usr/freeware/bin:/bin:/usr/local/bin:/usr/bin)
fi

View file

@ -3,8 +3,6 @@ pkgname=nfs4-acl-tools
version=0.3.7
revision=1
build_style=gnu-configure
configure_args="ac_cv_path_LIBTOOL='/usr/bin/libtool --tag=CC'
ac_cv_func_malloc_0_nonnull=yes"
hostmakedepends="automake autoconf libtool"
makedepends="attr-devel"
short_desc="Client tools for manipulating NFSv4 ACLs directly"
@ -13,14 +11,18 @@ license="BSD-3-Clause, LGPL-2.1-or-later, GPL-2.0-only"
homepage="http://linux-nfs.org/wiki/index.php/Main_Page"
distfiles="http://linux-nfs.org/~bfields/${pkgname}/${pkgname}-${version}.tar.gz"
checksum=1b929f15b7b8d1701a416a0888df61a2a173b50eeaa9fed4f28543ffe8989503
disable_parallel_build=yes
if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
makedepends+=" musl-legacy-compat"
fi
do_configure() {
sed -i "s;@configure_args@;$(echo $configure_args | paste);" Makefile
pre_configure() {
cp /usr/share/autoconf/build-aux/{config.guess,config.sub} "${wrksrc}"
autoreconf -ifv
}
pre_install() {
export CHOWNPROG=: CHGRPPROG=: # Don't try to chown/chgrp as we build as non-root
}
post_install() {