From e218d4445fa5a2015163cf50d847980ff3240b36 Mon Sep 17 00:00:00 2001 From: Nick Bowler Date: Sun, 7 Mar 2021 00:57:08 -0500 Subject: [PATCH] fix-gnulib: Fix order-only hack with HP-UX make. HP-UX make gets confused by the space in $(findstring ...,$(...)) syntax: instead of expanding to the empty string as desired, it mismatches the parentheses and we are left with a single ). E.g.: % cat >Makefile <<'EOF' all: @echo '$(a $(b))' EOF % make ) Since $(x) and ${x} are equivalent in Make, a neat solution is to just replace one set of parentheses with braces; now there are no nested parentheses to mismatch in the first place. --- scripts/fix-gnulib.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/fix-gnulib.pl b/scripts/fix-gnulib.pl index 16eac47..51bdf59 100755 --- a/scripts/fix-gnulib.pl +++ b/scripts/fix-gnulib.pl @@ -145,7 +145,7 @@ m4_unquote(m4_argn([2], [ # This trick should define gnulib_orderonly to | iff we're using GNU make. gnulib_make_features = $(.FEATURES) -gnulib_have_orderonly = $(findstring order-only,$(gnulib_make_features)) +gnulib_have_orderonly = $(findstring order-only,${gnulib_make_features}) gnulib_orderonly = $(gnulib_have_orderonly:order-only=|) gnulib_core_headers = gnulib_raw_headers = $(gnulib_core_headers) -- 2.43.0