build: add -W*-whitespace #32482

pull fanquake wants to merge 8 commits into bitcoin:master from fanquake:trailing_whitespace changing 6 files +626 −615
  1. fanquake commented at 3:13 pm on May 13, 2025: member

    GCC 15 now has options to turn leading & trailing whitespace into compile failures: https://gcc.gnu.org/gcc-15/changes.html#c-family. Fix the few cases of leading tabs, and trailing whitespace, and then enable -Wleading-whitespace and -Wtrailing-whitespace.

    We currently get PRs that are opened with various whitespace, i.e #33822, so turning that into compile-time failure where possible, seems useful, to avoid a CI roundtrip.

  2. DrahtBot commented at 3:13 pm on May 13, 2025: contributor

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/32482.

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK hebasto, ajtowns
    Stale ACK l0rinc

    If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

    LLM Linter (✨ experimental)

    Possible typos and grammar issues:

    • ; xor y1, a ; y1 = a ^ (a » (22-13) -> ; xor y1, a ; y1 = a ^ (a » (22-13)) [missing closing parenthesis in the expression]
    • ; xor y1, a ; y1 = a ^ (a » (13-2) -> ; xor y1, a ; y1 = a ^ (a » (13-2)) [missing closing parenthesis in the expression]
    • ; or y0, y2 ; y0 = MAJ = (a|c)&b)|(a&c) -> ; or y0, y2 ; y0 = MAJ = ((a|c)&b)|(a&c) [unmatched parentheses; added opening parenthesis for clarity]

    No other added lines contain typographic or grammatical errors that make the English invalid or incomprehensible.

    drahtbot_id_5_m

  3. DrahtBot added the label Build system on May 13, 2025
  4. hebasto commented at 3:19 pm on May 13, 2025: member

    GCC 15 now has options to turn these into compile failures: https://gcc.gnu.org/gcc-15/changes.html#c-family. Fix the few cases of leading tabs, and trailing whitespace, and then enable these options.

    Concept ACK on that.

    Unfortunately, CMake/Qt will generate code that contains trailing whitespace:

    0[ 98%] Building CXX object src/qt/CMakeFiles/bitcoinqt.dir/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp.o
    1/root/bitcoin/build/src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:5603:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    2 5603 | 
    3/root/bitcoin/build/src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:8254:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    4 8254 | 
    5/root/bitcoin/build/src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:9840:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    

    Will need to resolve that somehow.

    I’ll look into it.

  5. fanquake referenced this in commit c521192d8b on May 16, 2025
  6. fanquake force-pushed on May 16, 2025
  7. hebasto commented at 4:36 pm on May 30, 2025: member

    GCC 15 now has options to turn these into compile failures: https://gcc.gnu.org/gcc-15/changes.html#c-family. Fix the few cases of leading tabs, and trailing whitespace, and then enable these options.

    Concept ACK on that.

    Unfortunately, CMake/Qt will generate code that contains trailing whitespace:

    0[ 98%] Building CXX object src/qt/CMakeFiles/bitcoinqt.dir/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp.o
    1/root/bitcoin/build/src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:5603:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    2 5603 | 
    3/root/bitcoin/build/src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:8254:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    4 8254 | 
    5/root/bitcoin/build/src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:9840:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    

    Will need to resolve that somehow.

    I’ll look into it.

    Addressed in #32648.

  8. fanquake force-pushed on Jul 2, 2025
  9. fanquake renamed this:
    build: add `-W[leading|trailing]-whitespace`
    build: add `-Wleading-whitespace`
    on Jul 2, 2025
  10. fanquake marked this as ready for review on Jul 2, 2025
  11. fanquake commented at 1:08 pm on July 2, 2025: member
    Dropped -Wtrailing-whitespace for now. That could be added when Qts tools are fixed.
  12. maflcko added the label DrahtBot Guix build requested on Aug 2, 2025
  13. DrahtBot removed the label DrahtBot Guix build requested on Aug 3, 2025
  14. fanquake force-pushed on Aug 3, 2025
  15. hebasto commented at 3:14 pm on August 8, 2025: member

    GCC 15 now has options to turn leading & trailing whitespace into compile failures: https://gcc.gnu.org/gcc-15/changes.html#c-family. Fix the few cases of leading tabs, and trailing whitespace, and then enable -Wleading-whitespace. Unfortunately, CMake/Qt will generate code that contains trailing whitespace:

    0[ 98%] Building CXX object src/qt/CMakeFiles/bitcoinqt.dir/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp.o
    1/root/bitcoin/build/src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:5603:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    2 5603 | 
    3/root/bitcoin/build/src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:8254:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    4 8254 | 
    5/root/bitcoin/build/src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:9840:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    

    So -Wtrailing-whitespace could be enabled later, once Qts tooling is fixed.

    CMake 3.27 and newer handle this. The CMP0151 policy must be set to NEW.

  16. hebasto approved
  17. hebasto commented at 3:34 pm on August 8, 2025: member

    ACK 5e2620443d13b58efb38310263d67e2b823d6a1e.

    The first two commits were reviewed using git diff --ignore-space-change. Commit f2385191520f35fdef07743e5a12feaa87085dbe additionally removes an empty line, which is OK.

    So -Wtrailing-whitespace could be enabled later, once Qts tooling is fixed.

    CMake 3.27 and newer handle this. The CMP0151 policy must be set to NEW.

    As it is reasonable to expect CMake ≥3.27 on systems with GCC 15, I believe -Wtrailing-whitespace can be reintroduced.

  18. fanquake force-pushed on Aug 13, 2025
  19. fanquake force-pushed on Aug 21, 2025
  20. fanquake force-pushed on Aug 29, 2025
  21. in src/crypto/sha256_sse4.cpp:1030 in 8c60dc39a3 outdated
    1028 ; addm [mem], reg
    1029 ; Add reg to mem using reg-mem add and store
    1030 %macro addm 2
    1031-    add	%2, %1
    1032-    mov	%1, %2
    1033+    add %2, %1
    


    l0rinc commented at 7:52 pm on August 29, 2025:
    nit: given that we’re fixing non-trailing tabs as well, the only remaining .cpp/.h file that still contains tabs is https://github.com/bitcoin/bitcoin/blob/75a5c8258ec5309fe506438aa3815608430b53d6/src/util/subprocess.h#L1149, if you edit again, consider including that

    fanquake commented at 3:55 pm on September 1, 2025:
  22. in src/crypto/sha256_sse4.cpp:972 in 8c60dc39a3 outdated
    968@@ -969,27 +969,27 @@ void Transform(uint32_t* s, const unsigned char* chunk, size_t blocks)
    969 
    970 /*
    971 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
    972-; Copyright (c) 2012, Intel Corporation 
    973-; 
    974-; All rights reserved. 
    975-; 
    976+; Copyright (c) 2012, Intel Corporation
    


    l0rinc commented at 7:54 pm on August 29, 2025:

    fanquake commented at 4:00 pm on September 1, 2025:
  23. l0rinc approved
  24. l0rinc commented at 7:57 pm on August 29, 2025: contributor
    Core review ACK 8c60dc39a353c9d66cbe3a5a0a934eca6b2a287a
  25. DrahtBot requested review from hebasto on Aug 29, 2025
  26. l0rinc commented at 6:49 pm on September 1, 2025: contributor
    ACK b271b342e36000952a389c05b409bab691a4e4d2
  27. fanquake referenced this in commit d1bd01e189 on Sep 2, 2025
  28. bitcoin deleted a comment on Sep 2, 2025
  29. fanquake force-pushed on Oct 30, 2025
  30. fanquake force-pushed on Nov 5, 2025
  31. fanquake renamed this:
    build: add `-Wleading-whitespace`
    build: add `-W*-whitespace`
    on Nov 7, 2025
  32. l0rinc commented at 7:08 pm on November 7, 2025: contributor

    reACK 854269a785fc51602cc5ae018c666fc1d2659776

    git range-diff b271b34...854269a indicates it’s a simple rebase.

  33. ajtowns commented at 8:34 pm on November 8, 2025: contributor

    Concept ACK. The large commits here should be scripted-diffs though. I believe the following works, if expand/sponge are available:

    0scripted-diff: univalue: change leading whitespace to spaces
    1
    2-BEGIN VERIFY SCRIPT-
    3sed -i 's/^\t/    /' src/univalue/include/univalue_escapes.h
    4-END VERIFY SCRIPT-
    
    0scripted-diff: crypto: remove tabs and trailing whitespace in sha256_sse4.cpp
    1
    2-BEGIN VERIFY SCRIPT-
    3expand -t4 src/crypto/sha256_sse4.cpp | sed 's/  *$//' | sponge src/crypto/sha256_sse4.cpp
    4-END VERIFY SCRIPT-
    

    Only diff with what you’ve got is:

     0$ git diff HEAD pull/origin/32482
     1diff --git a/src/crypto/sha256_sse4.cpp b/src/crypto/sha256_sse4.cpp
     2index 2d37d124d1e..96f39e2df02 100644
     3--- a/src/crypto/sha256_sse4.cpp
     4+++ b/src/crypto/sha256_sse4.cpp
     5@@ -1078,7 +1078,7 @@ void Transform(uint32_t* s, const unsigned char* chunk, size_t blocks)
     6 %define e   r8d
     7
     8 %endif
     9-%define TBL rbp
    10+%define TBL    rbp
    11 %define a eax
    12 %define b ebx
    
  34. fanquake force-pushed on Nov 10, 2025
  35. l0rinc commented at 11:49 am on November 10, 2025: contributor

    reACK 2e713c22c67b3551f04273428db266503178e7fa

    0git fetch origin 2e713c22c67b3551f04273428db266503178e7fa && git range-diff 854269a...2e713c2
    

    commit messages include scripted diffs and the suggested change by AJ:

    0+%define TBL rbp
    
  36. DrahtBot requested review from ajtowns on Nov 10, 2025
  37. in src/util/subprocess.h:1149 in 4d47a704da outdated
    1145@@ -1146,7 +1146,7 @@ inline void Popen::execute_process() noexcept(false)
    1146                             NULL,         // process security attributes
    1147                             NULL,         // primary thread security attributes
    1148                             TRUE,         // handles are inherited
    1149-                            creation_flags,	// creation flags
    1150+                            creation_flags, // creation flags
    


    hebasto commented at 11:51 am on November 10, 2025:
    This change has just been merged upstream.

    fanquake commented at 11:55 am on November 10, 2025:
    Thanks.
  38. DrahtBot requested review from hebasto on Nov 10, 2025
  39. fanquake commented at 11:54 am on November 10, 2025: member

    if expand/sponge are available:

    We don’t have sponge, but added a commit to add moreutils, and pushed up the scripted diffs.

  40. hebasto commented at 12:07 pm on November 10, 2025: member

    Tested 2e713c22c67b3551f04273428db266503178e7fa on Ubuntu 25.10 with GCC 15.2.0:

     0$ cmake --build build
     1<snip>
     2[340/1092] Building CXX object src/qt/CMakeFiles/bitcoinqt.dir/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp.o
     3src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:5603:2: warning: trailing whitespace [-Wtrailing-whitespace=]
     4 5603 | 
     5src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:8254:2: warning: trailing whitespace [-Wtrailing-whitespace=]
     6 8254 | 
     7src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:9840:2: warning: trailing whitespace [-Wtrailing-whitespace=]
     8 9840 | 
     9src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:11671:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    1011671 | 
    11src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:11880:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    1211880 | 
    13src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:32981:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    1432981 | 
    15src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:33585:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    1633585 | 
    17src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:34942:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    1834942 | 
    19src/qt/bitcoinqt_autogen/EWIEGA46WW/qrc_bitcoin.cpp:35370:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    2035370 | 
    21[348/1092] Building CXX object src/qt/CMakeFiles/bitcoinqt.dir/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp.o
    22src/qt/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp:82738:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    2382738 | 
    24src/qt/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp:93715:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    2593715 | 
    26src/qt/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp:97857:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    2797857 | 
    28src/qt/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp:204993:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    29204993 | 
    30src/qt/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp:212562:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    31212562 | 
    32src/qt/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp:228433:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    33228433 | 
    34src/qt/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp:228777:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    35228777 | 
    36src/qt/bitcoinqt_autogen/EJRQKI7XPS/qrc_bitcoin_locale.cpp:228933:2: warning: trailing whitespace [-Wtrailing-whitespace=]
    37228933 | 
    38[419/1092] Building CXX object src/CMakeFiles/minisketch.dir/minisketch/src/fields/clmul_4bytes.cpp.o
    39In file included from ../src/minisketch/src/fields/clmul_4bytes.cpp:12:
    40../src/minisketch/src/fields/clmul_common_impl.h:39:66: warning: trailing whitespace [-Wtrailing-whitespace=]
    41   39 |         __m128i red1 = _mm_clmulepi64_si128(high1, MOD128, 0x00);
    42[1092/1092] Linking CXX executable bin/fuzz
    
  41. DrahtBot requested review from hebasto on Nov 10, 2025
  42. fanquake commented at 12:11 pm on November 10, 2025: member
    The minisketch issues are solved with pulling the subtree. I guess we are now just blocked on Qt / GUI tooling…
  43. hebasto commented at 1:49 pm on November 10, 2025: member

    I guess we are now just blocked on Qt / GUI tooling…

    From #32648 (comment):

    this should be fixed in Qts tooling.

    Even if it’s been fixed upstream, I don’t expect that change to be backported to all Qt versions down to 6.2. Therefore, we still need to suppress warnings in generated files. For example, as follows:

     0--- a/src/qt/CMakeLists.txt
     1+++ b/src/qt/CMakeLists.txt
     2@@ -50,11 +50,20 @@ endfunction()
     3 
     4 set(CMAKE_AUTOMOC ON)
     5 set(CMAKE_AUTOMOC_MOC_OPTIONS "-p${CMAKE_CURRENT_SOURCE_DIR}")
     6-set(CMAKE_AUTORCC ON)
     7 set(CMAKE_AUTOUIC ON)
     8 set(CMAKE_AUTOUIC_SEARCH_PATHS forms)
     9 
    10+set(CMAKE_AUTORCC OFF)
    11 configure_file(bitcoin_locale.qrc bitcoin_locale.qrc USE_SOURCE_PERMISSIONS COPYONLY)
    12+qt6_add_resources(BITCOIN_QRC bitcoin.qrc)
    13+qt6_add_resources(BITCOIN_LOCALE_QRC ${CMAKE_CURRENT_BINARY_DIR}/bitcoin_locale.qrc)
    14+set_property(
    15+  SOURCE
    16+    ${BITCOIN_QRC}
    17+    ${BITCOIN_LOCALE_QRC}
    18+  PROPERTY COMPILE_OPTIONS
    19+    -Wno-trailing-whitespace
    20+)
    21 
    22 # The bitcoinqt sources have to include headers in
    23 # order to parse them to collect translatable strings.
    24@@ -119,8 +128,8 @@ add_library(bitcoinqt STATIC EXCLUDE_FROM_ALL
    25   utilitydialog.h
    26   $<$<PLATFORM_ID:Windows>:winshutdownmonitor.cpp>
    27   $<$<PLATFORM_ID:Windows>:winshutdownmonitor.h>
    28-  bitcoin.qrc
    29-  ${CMAKE_CURRENT_BINARY_DIR}/bitcoin_locale.qrc
    30+  ${BITCOIN_QRC}
    31+  ${BITCOIN_LOCALE_QRC}
    32 )
    33 target_compile_definitions(bitcoinqt
    34   PUBLIC
    
  44. fanquake commented at 2:13 pm on November 10, 2025: member

    Even if it’s been fixed upstream,

    It’s not clear to me if it has been fixed or not, can you link to the relevant change / issue? I can cherry-pick the change above in, if you create a commit, and add a comment inline, for when the change can be dropped.

  45. hebasto commented at 3:22 pm on November 10, 2025: member

    Even if it’s been fixed upstream,

    It’s not clear to me if it has been fixed or not, can you link to the relevant change / issue?

    See https://bugreports.qt.io/browse/QTBUG-141858.

    I can cherry-pick the change above in, if you create a commit, and add a comment inline, for when the change can be dropped.

    Feel free to pick the top two commits from https://github.com/hebasto/bitcoin/commits/pr32482/1110/.

  46. fanquake force-pushed on Nov 10, 2025
  47. fanquake commented at 3:53 pm on November 10, 2025: member

    See https://bugreports.qt.io/browse/QTBUG-141858. Feel free to pick

    Thanks. I’ve pulled those two in here.

  48. fanquake commented at 4:55 pm on November 10, 2025: member

    Thanks. I’ve pulled those two in here.

    Looking at the CI. Those commits are not going to work as implemented (essentially anywhere we are using Clang).

  49. hebasto commented at 10:30 pm on November 10, 2025: member

    Thanks. I’ve pulled those two in here.

    Looking at the CI. Those commits are not going to work as implemented (essentially anywhere we are using Clang).

    Here is a branch with the fixed commit: https://github.com/hebasto/bitcoin/commits/pr32482/1110.1/.

  50. fanquake force-pushed on Nov 11, 2025
  51. ci: add moreutils to lint job
    Makes the sponge utility available for an upcoming scripted-diff.
    e6caf150b3
  52. scripted-diff: change whitespace to spaces in univalue
    -BEGIN VERIFY SCRIPT-
    sed -i 's/^\t/    /' src/univalue/include/univalue_escapes.h
    -END VERIFY SCRIPT-
    
    Co-authored-by: Anthony Towns <aj@erisian.com.au>
    4da084fbc9
  53. scripted-diff: remove whitespace in sha256_sse4.cpp
    -BEGIN VERIFY SCRIPT-
    expand -t4 src/crypto/sha256_sse4.cpp | sed 's/  *$//' | sponge src/crypto/sha256_sse4.cpp
    -END VERIFY SCRIPT-
    
    Co-authored-by: Anthony Towns <aj@erisian.com.au>
    0c2b9dadd5
  54. subprocess: replace tab with space
    See: https://github.com/arun11299/cpp-subprocess/pull/121.
    25ae14c339
  55. cmake: Switch from AUTORCC to `qt6_add_resources`
    This change provides finer control over the compilation of RCC-generated
    files.
    aabc5ca6ed
  56. cmake: Disable `-Wtrailing-whitespace` warnings for RCC-generated files
    See: https://bugreports.qt.io/browse/QTBUG-141858.
    d86650220a
  57. build: add -Wleading-whitespace=spaces
    This is available in GCC 15. See
    https://gcc.gnu.org/gcc-15/changes.html.
    d7659cd7e6
  58. in CMakeLists.txt:468 in e412d6d438 outdated
    462@@ -463,6 +463,9 @@ else()
    463   try_append_cxx_flags("-Wself-assign" TARGET warn_interface SKIP_LINK)
    464   try_append_cxx_flags("-Wbidi-chars=any" TARGET warn_interface SKIP_LINK)
    465   try_append_cxx_flags("-Wundef" TARGET warn_interface SKIP_LINK)
    466+  try_append_cxx_flags("-Wleading-whitespace=spaces" TARGET warn_interface SKIP_LINK)
    467+  try_append_cxx_flags("-Wtrailing-whitespace=any" TARGET warn_interface SKIP_LINK)
    468+
    


    hebasto commented at 11:29 am on November 11, 2025:
    nanonit: An extra empty line?

    fanquake commented at 11:37 am on November 11, 2025:
    Dropped.
  59. hebasto approved
  60. hebasto commented at 11:34 am on November 11, 2025: member
    ACK e412d6d438d600267174d1281feae3954c1c1c5b, tested on Ubuntu 25.10 using GCC 15.
  61. DrahtBot requested review from l0rinc on Nov 11, 2025
  62. build: add -Wtrailing-whitespace=any
    This is available in GCC 15. See
    https://gcc.gnu.org/gcc-15/changes.html.
    40dcbf580d
  63. fanquake force-pushed on Nov 11, 2025
  64. hebasto approved
  65. hebasto commented at 11:42 am on November 11, 2025: member
    re-ACK 40dcbf580d8eb31a067b62bf9676099919b9841e.
  66. ajtowns commented at 9:23 pm on November 11, 2025: contributor
    utACK 40dcbf580d8eb31a067b62bf9676099919b9841e
  67. fanquake requested review from maflcko on Nov 12, 2025
  68. maflcko commented at 10:21 am on November 12, 2025: member
    I am not using GCC, and I am not sure how many devs are using GCC-15. Is there even a ci task using gcc-15? Maybe Alpine 3.23 later this month? I haven’t looked at the build system changes, otherwise this seems fine to do.
  69. hebasto commented at 10:23 am on November 12, 2025: member

    and I am not sure how many devs are using GCC-15.

    I am :)

  70. l0rinc commented at 10:37 am on November 12, 2025: contributor

    how many devs are using GCC-15

    lately I’m also doing most of my benchmarks with 15

  71. fanquake merged this on Nov 12, 2025
  72. fanquake closed this on Nov 12, 2025

  73. fanquake deleted the branch on Nov 12, 2025
  74. maflcko commented at 2:38 pm on November 12, 2025: member

    Not sure how to reproduce locally, but this seems to be failing:

    0/__w/bitcoin-core-nightly/bitcoin-core-nightly/src/clientversion.cpp:33:79: error: trailing whitespace [-Werror=trailing-whitespace=]
    1   33 | //! git will put "#define GIT_COMMIT_ID ..." on the next line inside archives.
    

    https://github.com/maflcko/bitcoin-core-nightly/actions/runs/19297432422/job/55182808327#step:6:405

  75. TheCharlatan referenced this in commit 75d8345983 on Nov 12, 2025
  76. TheCharlatan referenced this in commit 7f93626ea0 on Nov 12, 2025
  77. hebasto commented at 3:30 pm on November 12, 2025: member

    Not sure how to reproduce locally, but this seems to be failing:

    0/__w/bitcoin-core-nightly/bitcoin-core-nightly/src/clientversion.cpp:33:79: error: trailing whitespace [-Werror=trailing-whitespace=]
    1   33 | //! git will put "#define GIT_COMMIT_ID ..." on the next line inside archives.
    

    https://github.com/maflcko/bitcoin-core-nightly/actions/runs/19297432422/job/55182808327#step:6:405

    Does the following patch help:

     0--- a/src/clientversion.cpp
     1+++ b/src/clientversion.cpp
     2@@ -30,7 +30,7 @@ const std::string UA_NAME("Satoshi");
     3 //   - "#define BUILD_GIT_COMMIT ...", if the top commit is not tagged
     4 //   - "// No build information available", if proper git information is not available
     5 
     6-//! git will put "#define GIT_COMMIT_ID ..." on the next line inside archives. $Format:%n#define GIT_COMMIT_ID "%H"$
     7+//! git will put "#define GIT_COMMIT_ID ..." on the next line inside archives.$Format:%n#define GIT_COMMIT_ID "%H"$
     8 
     9 #ifdef BUILD_GIT_TAG
    10     #define BUILD_DESC BUILD_GIT_TAG
    

    ?

  78. fanquake commented at 3:53 pm on November 12, 2025: member

    Not sure how to reproduce locally, but this seems to be failing:

    Interesting. My Fedora box, with the same GCC (15.2.1), does not fail the same as your CI job: https://github.com/maflcko/bitcoin-core-nightly/actions/runs/19297432422/job/55182808331.

  79. maflcko commented at 4:12 pm on November 12, 2025: member

    Does the following patch help:

    Yes, I presume it does help. I was just confused why the checkout GH action was using a git archive. Though, the guix release archive should be affected as well.


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2025-11-23 00:13 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me