From 9032359fdcbed4a4f3ad634f005ee0dbb687fa42 Mon Sep 17 00:00:00 2001 From: Ethan Clay Date: Sun, 12 Jul 2026 02:36:54 -0400 Subject: [PATCH] fix(ci): reject duplicate fuzz stub symbols (cherry picked from commit 37bab1b3c14d9927c252cca642f564c0a6da7fb4) --- src/CMakeLists.txt | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 906a1b0..ddbc011 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -817,10 +817,10 @@ if(BUILD_FUZZ) VERBATIM ) - # fuzz_stubs.cpp — satisfies the daemon-side globals that triangles_common - # and trianglesd_objects reference (pwalletMain, uiInterface, etc.) but - # that the fuzzer never actually touches. Keeping these as null/no-ops is - # the standard fuzzer pattern — see src/test/test_triangles.cpp and + # fuzz_stubs.cpp — satisfies globals owned by the excluded init.cpp that + # triangles_common and trianglesd_objects reference (pwalletMain, + # uiInterface, etc.). Keeping these as null/no-ops is the standard fuzzer + # pattern — see src/test/test_triangles.cpp and # src/test/snapshotnet_tests.cpp for the same approach. file(MAKE_DIRECTORY "${FUZZ_OBJ_DIR}") file(WRITE "${FUZZ_FUZZ_STUBS_SRC}" @@ -842,9 +842,6 @@ bool fUseFastIndex = false; unsigned int nDerivationMethodIndex = 0; bool fEnforceCanonical = true; bool fConfChange = false; -bool fWalletUnlockStakingOnly = false; -bool fUsePrivateSend = false; -bool fMasterNode = false; class CWalletStub : public CKeyStore { @@ -959,7 +956,6 @@ exec "$PROG" "${OBJS[@]}" "$@" "-fsanitize=fuzzer,address,undefined" "${FUZZ_OBJ_SCRIPT_FUZZ}" "-o" "${FUZZ_BIN}" - "-Wl,--allow-multiple-definition" "${FUZZ_OBJ_SCRIPT}" "${FUZZ_OBJ_FUZZ_STUBS}" "${CMAKE_BINARY_DIR}/lib/libhash9_crypto.a"