From 9d379a9237fe1af3fa94a35835356cad0adaf7dd Mon Sep 17 00:00:00 2001 From: Nick Bowler Date: Sat, 26 Feb 2022 15:26:58 -0500 Subject: [PATCH] fix-ltdl: 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-ltdl.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/fix-ltdl.pl b/scripts/fix-ltdl.pl index f65265d..cfd0545 100755 --- a/scripts/fix-ltdl.pl +++ b/scripts/fix-ltdl.pl @@ -1,6 +1,6 @@ #!/usr/bin/env perl # -# Copyright © 2012, 2014 Nick Bowler +# Copyright © 2012, 2014, 2022 Nick Bowler # # Fixup a non-recursive libltdl makefile fragment. While libltdl purports to # support inclusion into non-recursive automake builds, it does a few things @@ -99,7 +99,7 @@ while () { print <<'EOF'; # This trick should define ltdl_orderonly to | iff we're using GNU make. ltdl_make_features = $(.FEATURES) -ltdl_have_orderonly = $(findstring order-only,$(ltdl_make_features)) +ltdl_have_orderonly = $(findstring order-only,${ltdl_make_features}) ltdl_orderonly = $(ltdl_have_orderonly:order-only=|) ltdl_core_headers = ltdl_src_headers = $(ltdl_orderonly) $(ltdl_core_headers) -- 2.43.2