build: remove –enable-glibc-back-compat from Guix build #22405

pull fanquake wants to merge 5 commits into bitcoin:master from fanquake:remove_glibc_back_compat_guix changing 9 files +30 −6
  1. fanquake commented at 3:33 pm on July 5, 2021: member

    Now that our Guix toolchains are based on glibc 2.24 and 2.27 (RISCV), we don’t need to use the --enable-glibc-back-compat option to produce binaries that don’t use any symbols from glibc 2.17 and 2.27 or later.

    This also adds additional documentation to some Guix patches (pointed out in #22365) and removes Guix patches from the spelling linter, because that isn’t our spelling.

    Symbol usage: https://gist.github.com/fanquake/d15604fc580718444c5aa4b3c3c75fdc.

    Guix Builds:

     0bash-5.1# find guix-build-$(git rev-parse --short=12 HEAD)/output/ -type f -print0 | env LC_ALL=C sort -z | xargs -r0 sha256sum
     1ed54e6a6cf4fab328557c0c72eb08c73f2a58c6c70959544cf4b1882e75ea69e  guix-build-797b3ed90900/output/aarch64-linux-gnu/SHA256SUMS.part
     283bd9dadc59f89f848d143fa4fc3964f16fe0b4bdf35e5093b577ff2c4bd1f43  guix-build-797b3ed90900/output/aarch64-linux-gnu/bitcoin-797b3ed90900-aarch64-linux-gnu-debug.tar.gz
     394cb8c35281f12dec6ea5b390b66cad5e27ac8c45a30c42c8d38c438695d54c0  guix-build-797b3ed90900/output/aarch64-linux-gnu/bitcoin-797b3ed90900-aarch64-linux-gnu.tar.gz
     47318b63d65c0aa52d2446de8e1f40658d2e47ab8fb0268820c3b7585d140fb23  guix-build-797b3ed90900/output/arm-linux-gnueabihf/SHA256SUMS.part
     595e1ffb372964b73f539653ca703b70cf0c018801a9c4c0ffc46a0b63539253c  guix-build-797b3ed90900/output/arm-linux-gnueabihf/bitcoin-797b3ed90900-arm-linux-gnueabihf-debug.tar.gz
     6039d3842e6499626cf955ae0a7590dd6b3d0935cdc217c98aaf9d156b0ebd3b4  guix-build-797b3ed90900/output/arm-linux-gnueabihf/bitcoin-797b3ed90900-arm-linux-gnueabihf.tar.gz
     7e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855  guix-build-797b3ed90900/output/dist-archive/SKIPATTEST.TAG
     82c4e7b6e7aff63ba811e5bf59362d16866c3a358f8844fba8739a61192870622  guix-build-797b3ed90900/output/dist-archive/bitcoin-797b3ed90900.tar.gz
     9955029b949c368eabd517dd33040d2f01e2ac6a55e7b4f9107907a7c6e0c6060  guix-build-797b3ed90900/output/powerpc64-linux-gnu/SHA256SUMS.part
    10fd6d6b137f8efedf58a879d11205b1d4649e1f97d7f91e193239ef206fcc285d  guix-build-797b3ed90900/output/powerpc64-linux-gnu/bitcoin-797b3ed90900-powerpc64-linux-gnu-debug.tar.gz
    1151736ac8e77737999f1b5bd4c381b0016f19a8d5e40e786fe941ff04e84c11c9  guix-build-797b3ed90900/output/powerpc64-linux-gnu/bitcoin-797b3ed90900-powerpc64-linux-gnu.tar.gz
    128c244c16bfa46c1efdb120e1d91fdd14d3f14eefee8d7e1fbb0a9b4664a5c315  guix-build-797b3ed90900/output/powerpc64le-linux-gnu/SHA256SUMS.part
    13704ee593251a1b1c65a5bebeef93b23f266af4e8cbf8ae556150c3b2e8f06a6c  guix-build-797b3ed90900/output/powerpc64le-linux-gnu/bitcoin-797b3ed90900-powerpc64le-linux-gnu-debug.tar.gz
    140ec06ae7d344de20d61e3965d8b383747ef20b0e9d93a3165733ea23bdf2ead8  guix-build-797b3ed90900/output/powerpc64le-linux-gnu/bitcoin-797b3ed90900-powerpc64le-linux-gnu.tar.gz
    152dd6c6ecc67b0ea40ca9c43f92efca81ccd054b8db8c197ad84ad9674d510a25  guix-build-797b3ed90900/output/riscv64-linux-gnu/SHA256SUMS.part
    165ebb27a855a677f7a188d83995be6b2a3ea8606be152abb7fc7832713fb0677a  guix-build-797b3ed90900/output/riscv64-linux-gnu/bitcoin-797b3ed90900-riscv64-linux-gnu-debug.tar.gz
    17bdaf1783f5e1861597afa37c1880364e118d9a7a7af8017302d82202791019f6  guix-build-797b3ed90900/output/riscv64-linux-gnu/bitcoin-797b3ed90900-riscv64-linux-gnu.tar.gz
    18726c9092b60ac2e7d7e14b2c24467fcf276a6f89170a871ddab9dce6ac230699  guix-build-797b3ed90900/output/x86_64-apple-darwin18/SHA256SUMS.part
    192af4d709b44952654f3c08c86593bf2ccc9a44ed422783a1b95b8a199a894db2  guix-build-797b3ed90900/output/x86_64-apple-darwin18/bitcoin-797b3ed90900-osx-unsigned.dmg
    20fd49ba445aa6cf3d8c47019a05e9e5740cb0f53349344dd80671297127f49f1a  guix-build-797b3ed90900/output/x86_64-apple-darwin18/bitcoin-797b3ed90900-osx-unsigned.tar.gz
    213f51cbf8cf18420d4be70e656aa993675cf5e828a255c2030047ae2e059ed5b7  guix-build-797b3ed90900/output/x86_64-apple-darwin18/bitcoin-797b3ed90900-osx64.tar.gz
    22afd1edee1447bb88d81e972abfae4c4e065b5b1827769f033cff9472084c7c1b  guix-build-797b3ed90900/output/x86_64-linux-gnu/SHA256SUMS.part
    23ec468ef886d25e685f4f7a18b4f7d497dedf757495e0d5beb72c23cc32ab69b5  guix-build-797b3ed90900/output/x86_64-linux-gnu/bitcoin-797b3ed90900-x86_64-linux-gnu-debug.tar.gz
    241934d7294f0c9e083d38a3f68d4a61cd679defa79ce0a89f77386978692b9b18  guix-build-797b3ed90900/output/x86_64-linux-gnu/bitcoin-797b3ed90900-x86_64-linux-gnu.tar.gz
    2594c11c328a628052eb6f50e9816aa768f87ea7acfbbbafdab60f6928da766811  guix-build-797b3ed90900/output/x86_64-w64-mingw32/SHA256SUMS.part
    26fd371922ba93d81bd4a2b711d617af6756f9f0494db6d83aa0e5f491a24168ef  guix-build-797b3ed90900/output/x86_64-w64-mingw32/bitcoin-797b3ed90900-win-unsigned.tar.gz
    274e4ad976bc029bbbf9596ad8493accaaba8b0d5c598dd342f8da330609bbdf21  guix-build-797b3ed90900/output/x86_64-w64-mingw32/bitcoin-797b3ed90900-win64-debug.zip
    283a89a16b9101e9a17d98efb9234b5bdd264c0bba2c6326511017730e1a08311f  guix-build-797b3ed90900/output/x86_64-w64-mingw32/bitcoin-797b3ed90900-win64-setup-unsigned.exe
    29e285ab737e3c843fd3f1c26c2f053e421a3c39b33995747ce48281884d3f28d1  guix-build-797b3ed90900/output/x86_64-w64-mingw32/bitcoin-797b3ed90900-win64.zip
    
  2. fanquake added the label Build system on Jul 5, 2021
  3. MarcoFalke added the label Needs Guix build on Jul 5, 2021
  4. DrahtBot commented at 3:57 pm on July 5, 2021: member

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

    Conflicts

    Reviewers, this pull request conflicts with the following ones:

    If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

  5. fanquake force-pushed on Jul 6, 2021
  6. fanquake force-pushed on Jul 6, 2021
  7. fanquake force-pushed on Jul 6, 2021
  8. fanquake force-pushed on Jul 6, 2021
  9. fanquake marked this as a draft on Jul 6, 2021
  10. build: remove glibc backcompat requirement for Linux symbol checks 84dd81fb5b
  11. fanquake force-pushed on Jul 6, 2021
  12. guix: no-longer pass --enable-glibc-back-compat to Guix
    Now that our Guix builds are performed on glibc 2.24 and 2.27 (RISCV),
    we no-longer need to pass the --enable-glibc-back-compat option.
    
    Replace it with --disable-threadlocal, to prevent the usage of symbols
    from glibc 2.18.
    
    None of the binaries produced required symbols later than 2.17, and 2.27
    (RISCV).
    de6ca41a52
  13. lint: exclude Guix patches from spell-checking
    Co-authored-by: Carl Dong <contact@carldong.me>
    4516e5ec92
  14. guix: add additional documentation to patches 15fc9a0299
  15. script: remove gitian reference from symbol-check.py 797b3ed909
  16. fanquake force-pushed on Jul 6, 2021
  17. dongcarl commented at 9:01 pm on July 6, 2021: member
    No strong opinions on the concept, ACK code change.
  18. fanquake marked this as ready for review on Jul 7, 2021
  19. fanquake commented at 1:08 am on July 7, 2021: member
    Updated the PR description with Guix build output, and a link to the GLIBC symbol usage of the binaries. This is ready for review.
  20. sipa commented at 1:27 am on July 7, 2021: member

    utACK 797b3ed9090030f32fade81803b580562d4a90a3

    I think some of the restrictions we impose on ourselves to avoid glibc 2.17+ dependencies are probably a bit excessive (independent of this PR), and we may want to revisit those for 23.0, but no need to renege on that now.

  21. in contrib/guix/libexec/build.sh:243 in 797b3ed909
    239@@ -240,7 +240,7 @@ mkdir -p "$OUTDIR"
    240 # CONFIGFLAGS
    241 CONFIGFLAGS="--enable-reduce-exports --disable-bench --disable-gui-tests --disable-fuzz-binary"
    242 case "$HOST" in
    243-    *linux*) CONFIGFLAGS+=" --enable-glibc-back-compat" ;;
    244+    *linux*) CONFIGFLAGS+=" --disable-threadlocal" ;;
    


    hebasto commented at 7:26 am on July 7, 2021:

    Doesn’t configure check thread_local support?

    Maybe

     0diff --git a/configure.ac b/configure.ac
     1index 94f01a51a..ee8d716e5 100644
     2--- a/configure.ac
     3+++ b/configure.ac
     4@@ -1027,10 +1027,7 @@ AC_COMPILE_IFELSE([AC_LANG_SOURCE([
     5   [AC_MSG_RESULT(no)]
     6 )
     7 
     8-dnl thread_local is currently disabled when building with glibc back compat.
     9-dnl Our minimum supported glibc is 2.17, however support for thread_local
    10-dnl did not arrive in glibc until 2.18.
    11-if test "x$use_thread_local" = xyes || { test "x$use_thread_local" = xauto && test "x$use_glibc_compat" = xno; }; then
    12+if test "x$use_thread_local" != xno; then
    13   TEMP_LDFLAGS="$LDFLAGS"
    14   LDFLAGS="$TEMP_LDFLAGS $PTHREAD_CFLAGS"
    15   AC_MSG_CHECKING([for thread_local support])
    16diff --git a/contrib/guix/libexec/build.sh b/contrib/guix/libexec/build.sh
    17index 02ef80096..fd76cb2b7 100755
    18--- a/contrib/guix/libexec/build.sh
    19+++ b/contrib/guix/libexec/build.sh
    20@@ -239,9 +239,6 @@ mkdir -p "$OUTDIR"
    21 
    22 # CONFIGFLAGS
    23 CONFIGFLAGS="--enable-reduce-exports --disable-bench --disable-gui-tests --disable-fuzz-binary"
    24-case "$HOST" in
    25-    *linux*) CONFIGFLAGS+=" --disable-threadlocal" ;;
    26-esac
    27 
    28 # CFLAGS
    29 HOST_CFLAGS="-O2 -g"
    

    ?


    fanquake commented at 7:32 am on July 7, 2021:
    The change you’ve suggested is not going to work for supporting glibc 2.17 at runtime, for the exact reason outlined in the comment you’ve deleted.

    hebasto commented at 7:44 am on July 7, 2021:
    The configure script in Guix environment with glibc 2.17 should leave HAVE_THREAD_LOCAL undefined after the failed check, no?

    fanquake commented at 7:46 am on July 7, 2021:

    Guix environment with glibc 2.17

    The Guix environment is based on glibc 2.24, except for RISCV (2.27).


    hebasto commented at 7:48 am on July 7, 2021:
    Indeed.
  22. hebasto commented at 7:26 am on July 7, 2021: member
    Concept ACK.
  23. hebasto approved
  24. hebasto commented at 11:07 am on July 7, 2021: member

    ACK 797b3ed9090030f32fade81803b580562d4a90a3

    Guix builds:

     0eb08c73f2a58c6c70959544cf4b1882e75ea69e  guix-build-797b3ed90900/output/aarch64-linux-gnu/SHA256SUMS.part
     183bd9dadc59f89f848d143fa4fc3964f16fe0b4bdf35e5093b577ff2c4bd1f43  guix-build-797b3ed90900/output/aarch64-linux-gnu/bitcoin-797b3ed90900-aarch64-linux-gnu-debug.tar.gz
     294cb8c35281f12dec6ea5b390b66cad5e27ac8c45a30c42c8d38c438695d54c0  guix-build-797b3ed90900/output/aarch64-linux-gnu/bitcoin-797b3ed90900-aarch64-linux-gnu.tar.gz
     37318b63d65c0aa52d2446de8e1f40658d2e47ab8fb0268820c3b7585d140fb23  guix-build-797b3ed90900/output/arm-linux-gnueabihf/SHA256SUMS.part
     495e1ffb372964b73f539653ca703b70cf0c018801a9c4c0ffc46a0b63539253c  guix-build-797b3ed90900/output/arm-linux-gnueabihf/bitcoin-797b3ed90900-arm-linux-gnueabihf-debug.tar.gz
     5039d3842e6499626cf955ae0a7590dd6b3d0935cdc217c98aaf9d156b0ebd3b4  guix-build-797b3ed90900/output/arm-linux-gnueabihf/bitcoin-797b3ed90900-arm-linux-gnueabihf.tar.gz
     6e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855  guix-build-797b3ed90900/output/dist-archive/SKIPATTEST.TAG
     72c4e7b6e7aff63ba811e5bf59362d16866c3a358f8844fba8739a61192870622  guix-build-797b3ed90900/output/dist-archive/bitcoin-797b3ed90900.tar.gz
     8955029b949c368eabd517dd33040d2f01e2ac6a55e7b4f9107907a7c6e0c6060  guix-build-797b3ed90900/output/powerpc64-linux-gnu/SHA256SUMS.part
     9fd6d6b137f8efedf58a879d11205b1d4649e1f97d7f91e193239ef206fcc285d  guix-build-797b3ed90900/output/powerpc64-linux-gnu/bitcoin-797b3ed90900-powerpc64-linux-gnu-debug.tar.gz
    1051736ac8e77737999f1b5bd4c381b0016f19a8d5e40e786fe941ff04e84c11c9  guix-build-797b3ed90900/output/powerpc64-linux-gnu/bitcoin-797b3ed90900-powerpc64-linux-gnu.tar.gz
    118c244c16bfa46c1efdb120e1d91fdd14d3f14eefee8d7e1fbb0a9b4664a5c315  guix-build-797b3ed90900/output/powerpc64le-linux-gnu/SHA256SUMS.part
    12704ee593251a1b1c65a5bebeef93b23f266af4e8cbf8ae556150c3b2e8f06a6c  guix-build-797b3ed90900/output/powerpc64le-linux-gnu/bitcoin-797b3ed90900-powerpc64le-linux-gnu-debug.tar.gz
    130ec06ae7d344de20d61e3965d8b383747ef20b0e9d93a3165733ea23bdf2ead8  guix-build-797b3ed90900/output/powerpc64le-linux-gnu/bitcoin-797b3ed90900-powerpc64le-linux-gnu.tar.gz
    142dd6c6ecc67b0ea40ca9c43f92efca81ccd054b8db8c197ad84ad9674d510a25  guix-build-797b3ed90900/output/riscv64-linux-gnu/SHA256SUMS.part
    155ebb27a855a677f7a188d83995be6b2a3ea8606be152abb7fc7832713fb0677a  guix-build-797b3ed90900/output/riscv64-linux-gnu/bitcoin-797b3ed90900-riscv64-linux-gnu-debug.tar.gz
    16bdaf1783f5e1861597afa37c1880364e118d9a7a7af8017302d82202791019f6  guix-build-797b3ed90900/output/riscv64-linux-gnu/bitcoin-797b3ed90900-riscv64-linux-gnu.tar.gz
    17726c9092b60ac2e7d7e14b2c24467fcf276a6f89170a871ddab9dce6ac230699  guix-build-797b3ed90900/output/x86_64-apple-darwin18/SHA256SUMS.part
    182af4d709b44952654f3c08c86593bf2ccc9a44ed422783a1b95b8a199a894db2  guix-build-797b3ed90900/output/x86_64-apple-darwin18/bitcoin-797b3ed90900-osx-unsigned.dmg
    19fd49ba445aa6cf3d8c47019a05e9e5740cb0f53349344dd80671297127f49f1a  guix-build-797b3ed90900/output/x86_64-apple-darwin18/bitcoin-797b3ed90900-osx-unsigned.tar.gz
    203f51cbf8cf18420d4be70e656aa993675cf5e828a255c2030047ae2e059ed5b7  guix-build-797b3ed90900/output/x86_64-apple-darwin18/bitcoin-797b3ed90900-osx64.tar.gz
    21afd1edee1447bb88d81e972abfae4c4e065b5b1827769f033cff9472084c7c1b  guix-build-797b3ed90900/output/x86_64-linux-gnu/SHA256SUMS.part
    22ec468ef886d25e685f4f7a18b4f7d497dedf757495e0d5beb72c23cc32ab69b5  guix-build-797b3ed90900/output/x86_64-linux-gnu/bitcoin-797b3ed90900-x86_64-linux-gnu-debug.tar.gz
    231934d7294f0c9e083d38a3f68d4a61cd679defa79ce0a89f77386978692b9b18  guix-build-797b3ed90900/output/x86_64-linux-gnu/bitcoin-797b3ed90900-x86_64-linux-gnu.tar.gz
    2494c11c328a628052eb6f50e9816aa768f87ea7acfbbbafdab60f6928da766811  guix-build-797b3ed90900/output/x86_64-w64-mingw32/SHA256SUMS.part
    25fd371922ba93d81bd4a2b711d617af6756f9f0494db6d83aa0e5f491a24168ef  guix-build-797b3ed90900/output/x86_64-w64-mingw32/bitcoin-797b3ed90900-win-unsigned.tar.gz
    264e4ad976bc029bbbf9596ad8493accaaba8b0d5c598dd342f8da330609bbdf21  guix-build-797b3ed90900/output/x86_64-w64-mingw32/bitcoin-797b3ed90900-win64-debug.zip
    273a89a16b9101e9a17d98efb9234b5bdd264c0bba2c6326511017730e1a08311f  guix-build-797b3ed90900/output/x86_64-w64-mingw32/bitcoin-797b3ed90900-win64-setup-unsigned.exe
    28e285ab737e3c843fd3f1c26c2f053e421a3c39b33995747ce48281884d3f28d1  guix-build-797b3ed90900/output/x86_64-w64-mingw32/bitcoin-797b3ed90900-win64.zip
    
  25. fanquake merged this on Jul 7, 2021
  26. fanquake closed this on Jul 7, 2021

  27. MarcoFalke removed the label Needs Guix build on Jul 7, 2021
  28. laanwj commented at 11:43 am on July 7, 2021: member
    Posthumous code review ACK 797b3ed9090030f32fade81803b580562d4a90a3
  29. sidhujag referenced this in commit 5e283f2d1c on Jul 10, 2021
  30. fanquake deleted the branch on Jul 16, 2021
  31. laanwj referenced this in commit 698b4b8fac on Sep 16, 2021
  32. fanquake referenced this in commit 6bde42e29e on Nov 17, 2021
  33. gwillen referenced this in commit ae15e5dc5d on Jun 1, 2022
  34. DrahtBot locked this on Aug 18, 2022

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: 2024-11-17 21:12 UTC

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