Skip to content

Commit f618577

Browse files
committed
build: fix link error on some platforms. Fixes #5235
Some users may have libtool libs (.la) installed in their linker search paths. In this case, using -static-libtool-libs would try to link in .a's instead of shared libs. That would be harmless unless the .a was built in a way that would break linking, like non-fpic. What we really want is "-static" here. Despite its name, it's actually less aggressive than -static-libtool-libs. It causes only internal libs to be linked statically (libbitcoinconsensus is the one were'a after).
1 parent 5c4dffd commit f618577

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Makefile.test.include

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ test_test_bitcoin_LDADD += $(LIBBITCOIN_WALLET)
8686
endif
8787

8888
test_test_bitcoin_LDADD += $(LIBBITCOIN_CONSENSUS) $(BDB_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(MINIUPNPC_LIBS)
89-
test_test_bitcoin_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) -static-libtool-libs
89+
test_test_bitcoin_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) -static
9090

9191
nodist_test_test_bitcoin_SOURCES = $(GENERATED_TEST_FILES)
9292

0 commit comments

Comments
 (0)