From eb17af0ea5ab624581f6a3e7cac499919c952854 Mon Sep 17 00:00:00 2001 From: Amos Jeffries Date: Wed, 1 Apr 2026 20:41:35 +1300 Subject: [PATCH] Fix missing LDFLAGS when linking squid binary The auto-tools build system defines AM_LDFLAGS as the place for tools to add linker flags automatically determined to be needed, so as not to clobber user provide flags in LDFLAGS variable. This AM_* variable can be replaced in the linker command line for binary 'foo' by defining a replacement foo_LDFLAGS variable in Makefile.am. When third-party build and test tool use AM_LDFLAGS to pass flags to our build process additional flags the current squid_LDFLAGS ignores them. --- src/Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Makefile.am b/src/Makefile.am index 4480764023d..91c2266c330 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -560,7 +560,7 @@ squid_LDADD = \ if ENABLE_LOADABLE_MODULES squid_SOURCES += $(LOADABLE_MODULES_SOURCES) squid_LDADD += -L$(top_builddir) $(LIBLTDL) -squid_LDFLAGS = -export-dynamic -dlopen force +squid_LDFLAGS = $(AM_LDFLAGS) -export-dynamic -dlopen force ## when static module linking is supported and enabled: ## squid_LDFLAGS = -all-static -dlopen self ##