[23.x] guix: patch NSIS to remove .reloc sections from install stubs #25799

pull fanquake wants to merge 1 commits into bitcoin:23.x from fanquake:backport_guix_fixups changing 2 files +32 −1
  1. fanquake commented at 1:17 pm on August 7, 2022: member

    Backport of #25788 to the 23.x branch.

    Guix Build (x86_64):

    05533c15a0084dfc174b68620a638f5499677be20eafdb1261457f7759298abdc  guix-build-fc77b2a41dd9/output/dist-archive/bitcoin-fc77b2a41dd9.tar.gz
    1b67742b17aa813350051635f1e0a9b27921deb22c40d89c8d108fd809619826c  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/SHA256SUMS.part
    234e06ab6fbcce2508095d6899daf9c38b962df1a042d0bedee49169f394d47a5  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-debug.zip
    363e1e7c1aa62577a21606c789bdaf983352c5285eec5722608cf7a3240a25d6a  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-setup-unsigned.exe
    40ae26c5bc2f2aa86c451d3cfa3fbdbd73edab6136fd8d6510cd1c47a833973b7  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-unsigned.tar.gz
    5ddb1feb2541d1a4922a62997224e965a3e79c7233c75106eb8c7ad76eff6cf89  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64.zip
    

    Guix Build (arm64):

    05533c15a0084dfc174b68620a638f5499677be20eafdb1261457f7759298abdc  guix-build-fc77b2a41dd9/output/dist-archive/bitcoin-fc77b2a41dd9.tar.gz
    13c5cb927e397d14f39bed24480b6800d946854c376d35cfb7a9dd635d45a5d6b  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/SHA256SUMS.part
    2b520c2e9f4c29fe711225c737b4c16e2ae933d5954cfb15cec554e1e0b57b061  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-debug.zip
    363e1e7c1aa62577a21606c789bdaf983352c5285eec5722608cf7a3240a25d6a  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-setup-unsigned.exe
    40ae26c5bc2f2aa86c451d3cfa3fbdbd73edab6136fd8d6510cd1c47a833973b7  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-unsigned.tar.gz
    51447a28a582c0e5f2dd03ce22ecf078c6398142b3a2be2de2347a5f095f14d5b  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64.zip
    
  2. guix: patch NSIS to remove .reloc sections from install stubs
    With the release of binutils/ld 2.36, ld swapped to much improved
    default settings when producing windows binaries with mingw-w64. One of
    these changes was to stop stripping the .reloc section from binaries,
    which is required for working ASLR.
    
    .reloc section stripping is something we've accounted for previously,
    see #18702. The related upstream discussion is in this thread:
    https://sourceware.org/bugzilla/show_bug.cgi?id=19011.
    
    When we switched to using a newer Guix time-machine in #23778, we begun
    using binutils 2.37 to produce releases. Since then, our windows
    installer (produced with makensis) has not functioned correctly when run on
    a Windows system with the "Force randomization for images (Mandatory ASLR)"
    option enabled. Note that all of our other release binaries, which all
    contain .reloc sections, function fine under the same option, so it
    cannot be just the presence of a .reloc section that is the issue.
    
    For now, restore makensis to it's pre-binutils-2.36 behaviour, which
    fixes the produced installer. The underlying issue can be further
    investigated in future.
    
    Github-Pull: #25788
    Rebased-From: 7a0b129c41d9fefdbc20d6d04983dd87bb8379e7
    fc77b2a41d
  3. fanquake added the label Windows on Aug 7, 2022
  4. fanquake added the label Build system on Aug 7, 2022
  5. fanquake added the label Backport on Aug 7, 2022
  6. hebasto approved
  7. hebasto commented at 2:44 pm on August 7, 2022: member
    ACK fc77b2a41dd97561d76c89c74e6850c6a1085ce5, bitcoin-fc77b2a41dd9-win64-setup-unsigned.exe tested on on Windows 11 Pro 21H2 with the “Force randomization for images (Mandatory ASLR)” option being set to “On by default”.
  8. hebasto commented at 2:45 pm on August 7, 2022: member

    Guiz builds on x86_64:

    05533c15a0084dfc174b68620a638f5499677be20eafdb1261457f7759298abdc  guix-build-fc77b2a41dd9/output/dist-archive/bitcoin-fc77b2a41dd9.tar.gz
    1b67742b17aa813350051635f1e0a9b27921deb22c40d89c8d108fd809619826c  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/SHA256SUMS.part
    234e06ab6fbcce2508095d6899daf9c38b962df1a042d0bedee49169f394d47a5  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-debug.zip
    363e1e7c1aa62577a21606c789bdaf983352c5285eec5722608cf7a3240a25d6a  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-setup-unsigned.exe
    40ae26c5bc2f2aa86c451d3cfa3fbdbd73edab6136fd8d6510cd1c47a833973b7  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-unsigned.tar.gz
    5ddb1feb2541d1a4922a62997224e965a3e79c7233c75106eb8c7ad76eff6cf89  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64.zip
    
  9. jarolrod commented at 7:49 pm on August 7, 2022: member

    GUIX hashes

    x86:

    0$ env HOSTS='x86_64-w64-mingw32' ./contrib/guix/guix-build 
    1$ find guix-build-$(git rev-parse --short=12 HEAD)/output/ -type f -print0 | env LC_ALL=C sort -z | xargs -r0 sha256sum
    2
    35533c15a0084dfc174b68620a638f5499677be20eafdb1261457f7759298abdc  guix-build-fc77b2a41dd9/output/dist-archive/bitcoin-fc77b2a41dd9.tar.gz
    4b67742b17aa813350051635f1e0a9b27921deb22c40d89c8d108fd809619826c  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/SHA256SUMS.part
    534e06ab6fbcce2508095d6899daf9c38b962df1a042d0bedee49169f394d47a5  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-debug.zip
    663e1e7c1aa62577a21606c789bdaf983352c5285eec5722608cf7a3240a25d6a  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-setup-unsigned.exe
    70ae26c5bc2f2aa86c451d3cfa3fbdbd73edab6136fd8d6510cd1c47a833973b7  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-unsigned.tar.gz
    8ddb1feb2541d1a4922a62997224e965a3e79c7233c75106eb8c7ad76eff6cf89  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64.zip
    

    arm64:

    0$ env HOSTS='x86_64-w64-mingw32' ./contrib/guix/guix-build 
    1$ find guix-build-$(git rev-parse --short=12 HEAD)/output/ -type f -print0 | env LC_ALL=C sort -z | xargs -r0 sha256sum
    2
    35533c15a0084dfc174b68620a638f5499677be20eafdb1261457f7759298abdc  guix-build-fc77b2a41dd9/output/dist-archive/bitcoin-fc77b2a41dd9.tar.gz
    43c5cb927e397d14f39bed24480b6800d946854c376d35cfb7a9dd635d45a5d6b  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/SHA256SUMS.part
    5b520c2e9f4c29fe711225c737b4c16e2ae933d5954cfb15cec554e1e0b57b061  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-debug.zip
    663e1e7c1aa62577a21606c789bdaf983352c5285eec5722608cf7a3240a25d6a  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-setup-unsigned.exe
    70ae26c5bc2f2aa86c451d3cfa3fbdbd73edab6136fd8d6510cd1c47a833973b7  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64-unsigned.tar.gz
    81447a28a582c0e5f2dd03ce22ecf078c6398142b3a2be2de2347a5f095f14d5b  guix-build-fc77b2a41dd9/output/x86_64-w64-mingw32/bitcoin-fc77b2a41dd9-win64.zip
    
  10. jarolrod approved
  11. jarolrod commented at 8:04 pm on August 7, 2022: member

    ACK fc77b2a41dd97561d76c89c74e6850c6a1085ce5

    tested on Windows 11 for ARM

  12. fanquake added this to the milestone 23.1 on Aug 8, 2022
  13. fanquake renamed this:
    guix: patch NSIS to remove .reloc sections from install stubs
    [23.x] guix: patch NSIS to remove .reloc sections from install stubs
    on Aug 8, 2022
  14. achow101 commented at 8:45 pm on August 9, 2022: member

    ACK fc77b2a41dd97561d76c89c74e6850c6a1085ce5

    Diff matches

  15. achow101 merged this on Aug 9, 2022
  16. achow101 closed this on Aug 9, 2022

  17. fanquake deleted the branch on Aug 10, 2022
  18. bitcoin locked this on Aug 10, 2023

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-09-29 01:12 UTC

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