Skip to content

Commit 7be9bbd

Browse files
committed
#aa52e48 use no-as-needed parameter for tests too
1 parent e9157fc commit 7be9bbd

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

_charm/src/aa52e486de14f7e86e0af62dcc24ad8104fb389bd2cb9bc3806dcc5c77829b2c.cr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@
77
<links>
88
<link name="parent">7bc74cc796c455a46d699ad91f6aca5b7c790f56a6a0968b4ecbce33efce9d25</link>
99
</links>
10-
<cf v="fred322 2025-04-14T16:24:26+02:00"/>
10+
<cf v="fred322 2025-04-23T09:36:36+02:00"/>
1111
</cr>

core/module-crules-vars.mk

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,10 @@ define GetExistingModGeneratedSO
116116
$(foreach mod,$1,$(if $(wildcard $(TRDIR)/$(SODIR)/$(SOPFX)$(APPNAME)_$(mod).$(SOEXT)),$(APPNAME)_$(mod))$(if $(wildcard $(TRDIR)/$(SODIR)/$(SOPFX)$(mod).$(SOEXT)),$(mod)))
117117
endef
118118

119+
# --no-as-needed permit to add the linked libraries even if they are not used in this module.
120+
# This is the default value for old compilers
121+
LDFLAGS+=-Wl,--no-as-needed
122+
119123
# target full path
120124
TARGETFILE=$(TARGETDIR)/$(TARGET)
121125
TARGETFILE_LIB=$(TARGETDIR)/$(TARGET_LIB)
@@ -288,9 +292,7 @@ endef
288292
# only process abs managed ldflags to permit developer to add elements in LDFLAGS with its own order.
289293
CRULES_VAR_LINKED_LIBS=$(sort $(filter -l%,$(LDFLAGS)))
290294

291-
# --no-as-needed permit to add the linked libraries even if they are not used in this module.
292-
# This is the default value for old compilers (only for generated libs, not for test libs).
293-
FULL_LDFLAGS=-Wl,--no-as-needed
295+
FULL_LDFLAGS=
294296
ifneq ($(MODTYPE),library)
295297
# --rpath-link permit to the linker to find shared libraries (needed for cross compiler linker for exe generation).
296298
FULL_LDFLAGS+=$(patsubst -L%,-Wl$(_comma_)--rpath-link=%,$(sort $(filter -L%,$(LDFLAGS))))

0 commit comments

Comments
 (0)