Gitian fixes for 0.9.0rc1 build #3620

pull laanwj wants to merge 1 commits into bitcoin:master from laanwj:2014_01_gitian_fixes changing 6 files +25 −6
  1. laanwj commented at 12:24 PM on February 3, 2014: member
    • Add 'g++' package (virtualbox images don't have this by default)
    • Workaround for determinism in Qt5 resources
    • Pass --disable-maintainer-mode --disable-dependency-tracking to configure for libqrencode to avoid random errors about missing m4 directory
    • Fix typo -with-pic -> --with-pic

    It is not necessary to rebuild dependencies after this commit. Fixes #3610 and #3612.

  2. in contrib/gitian-descriptors/qt-win.yml:None in 9debb6b3d3 outdated
      26 | +  #  A security fix in QHash makes the ordering of keys to be different on every ru
      27 | +  #  (https://qt.gitorious.org/qt/qtbase/commit/c01eaa438200edc9a3bbcd8ae1e8ded058bea268).
      28 | +  #  This is good in general but qrc shouldn't be doing a traversal over a randomized container.
      29 | +  #  The thorough solution would be to use QMap instead of QHash, but this requires patching Qt.
      30 | +  #  For now luckily there is a test mode that forces a fixed seed.
      31 | +  export QT_RCC_TEST=1
    


    Michagogo commented at 12:45 PM on February 3, 2014:

    Why do you add this here? What exactly does it do, if you say rebuilding isn't necessary?


    laanwj commented at 12:49 PM on February 3, 2014:

    Hmm yes maybe it is necessary.


    Michagogo commented at 12:55 PM on February 3, 2014:

    Okay -- in that case, don't forget to increment the dependency version.

  3. in contrib/gitian-descriptors/gitian-win.yml:None in 9debb6b3d3 outdated
      35 | @@ -36,6 +36,14 @@ script: |
      36 |    INDIR=$HOME/build
      37 |    OPTFLAGS='-O2'
      38 |    NEEDDIST=1
      39 | +  # Qt: workaround for determinism in resource ordering
      40 | +  #  Qt5's rcc uses a QHash to store the files for the resource.
      41 | +  #  A security fix in QHash makes the ordering of keys to be different on every ru
    


    Diapolo commented at 12:45 PM on February 3, 2014:

    Small typo on every run.


    laanwj commented at 12:51 PM on February 3, 2014:

    @diapolo to be honest typos in the comments are not really a priority right now, if you want to help try doing gitian builds


    Diapolo commented at 2:10 PM on February 3, 2014:

    Sure, if there are some final instructions available that I can follow. As far as I remember, Gavin said he is currently writing on a doc?


  4. in contrib/gitian-descriptors/qt-win.yml:None in 9debb6b3d3 outdated
      20 | @@ -21,6 +21,14 @@ script: |
      21 |    # Defines
      22 |    export TZ=UTC
      23 |    INDIR=$HOME/build
      24 | +  # Qt: workaround for determinism in resource ordering
      25 | +  #  Qt5's rcc uses a QHash to store the files for the resource.
      26 | +  #  A security fix in QHash makes the ordering of keys to be different on every ru
    


    Diapolo commented at 12:45 PM on February 3, 2014:

    Same here...

  5. laanwj commented at 12:52 PM on February 3, 2014: member

    At least rebuild Qt after this. I'm not 100% sure that it is needed, but there is a large chance that Qt itself is also using the resource compiler somewhere.

  6. gavinandresen commented at 12:53 PM on February 3, 2014: contributor

    ACK

  7. Gitian fixes for 0.9.0rc1 build
    - Add 'g++' package (virtualbox images don't have this by default)
    - Workaround for determinism in Qt5 resources
    - Pass --disable-maintainer-mode --disable-dependency-tracking to
      configure for libqrencode to avoid random errors about missing m4
      directory
    - Fix typo -with-pic -> --with-pic
    
    It is not necessary to rebuild dependencies after this commit.
    Fixes #3610 and #3612.
    65615a3a78
  8. BitcoinPullTester commented at 2:32 PM on February 3, 2014: none

    Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/65615a3a784c01128b408a915ab375c35640fb0a for binaries and test log. This test script verifies pulls every time they are updated. It, however, dies sometimes and fails to test properly. If you are waiting on a test, please check timestamps to verify that the test.log is moving at http://jenkins.bluematt.me/pull-tester/current/ Contact BlueMatt on freenode if something looks broken.

  9. laanwj commented at 3:56 PM on February 3, 2014: member

    This seems to fix at least all the determinism issues on KVM. I built the entire chain (including all dependencies) twice and ended up with the same result:

    763b94cd7fd717ec8838593f18743e4612a445cfe9622a7b14ef8d4a5077bae6  32/bitcoin-0.9.0-win32-setup.exe
    778c489114209254a27d095ff56b4b6638092c58e2e277cdf3ce06056c5e81ff  32/bitcoin-cli.exe
    023ad348dbe06a172b80d49bca9151c950d8485cc215ec0dc048a6c8a522c2c0  32/bitcoin-qt.exe
    e549386338608ddfc3a8d551dd4638d216e0d6d05995737577b9b50e34a0c986  32/bitcoind.exe
    057c990265b43c80178aa16fa18f6bacf5f3b0e1212ca55b77356b09122e1aa4  32/test_bitcoin-qt.exe
    e65c38b013aca3506742c674c18fb0689792e51cae0af06cb96f10d6084071d9  32/test_bitcoin.exe
    d1031fd597ba17a42d3da79e646cb8700fd76ab22d1b88a998024344f6b85af4  64/bitcoin-0.9.0-win64-setup.exe
    0eaf0edcb173729fe3b416a95a704ed1415ae2874f6ea4b293f4177724d9e0f1  64/bitcoin-cli.exe
    9c76db95dc4d6fd6a771c021e96e6b1d657cb29abadb92d47546247792be270e  64/bitcoin-qt.exe
    bc2252edadfd63a82fe0fced4c8969e0bf07cf30a6727310746f85b7a3713437  64/bitcoind.exe
    930597e75fad4455fc4253b5f2829933b7cfde48a679c28cf9aa57d57f8c773d  64/test_bitcoin-qt.exe
    0dcfd1cc22cf6cb9e2554f22aa1502891fd1c22f29bd745b2a8497b9fe4c094b  64/test_bitcoin.exe
    24798a99e86d54e1b45294a67ed22b836a2572fcf160cca1c5cf45884e9aca45  src/bitcoin-0.9.0.tar.gz
    

    Edit: now going to try with LXC and see if it different (and if so, why).

  10. laanwj commented at 5:16 PM on February 3, 2014: member

    I've written down the steps I had to follow to get the LXC build to work on Ubuntu 12.04: https://gist.github.com/laanwj/8787944

  11. Michagogo commented at 5:24 PM on February 3, 2014: contributor

    @laanwj Hm, what's wrong with doing it the way @devrandom suggests in his README, with these commands:

    sudo brctl addbr br0
    sudo ifconfig br0 10.0.2.2/24 up
    

    ?

    Other than that, I don't see anything different in your gist relating to the build itself. Any idea what the difference might be?

  12. laanwj commented at 5:55 PM on February 3, 2014: member

    I've rebuilt the entire dependency chain in LXC and got the same result as above. So, seems deterministic.

    Edit: nothing is wrong with @devrandom's way, but I wanted to use the lxcbr0 device provided by Ubuntu itself instead of creating a new one. This will not make a difference to the executable.

  13. laanwj referenced this in commit 23617fd01d on Feb 3, 2014
  14. laanwj merged this on Feb 3, 2014
  15. laanwj closed this on Feb 3, 2014

  16. laanwj commented at 6:00 PM on February 3, 2014: member

    @gavinandresen I've merged this, but I'm not sure how to do proceed. Can/should we re-tag rc1 to make sure that people build with these gitian descriptors?

  17. gavinandresen commented at 6:59 PM on February 3, 2014: contributor

    Best to just consider rc1 dead, bump version numbers, and jump to rc2.

  18. laanwj commented at 7:53 PM on February 3, 2014: member

    Hm, let's wait a bit. I'm not getting deterministic builds for Linux. (juist built everything twice w/ LXC, only bitcoin-cli and test_bitcoin are the same)

  19. gavinandresen commented at 8:12 PM on February 3, 2014: contributor

    OK on waiting a bit; we should make sure we can cobble together builds that match before bumping version numbers.

    FYI: I'll be out Wed-Fri this week, headed down to Princeton and DC.

  20. laanwj commented at 7:01 AM on February 4, 2014: member

    Let's try to get it ready today then. I figured out the cause of non-determinism (OpenSSL embeds a timestamp, should use faketime during OpenSSL build).

  21. laanwj deleted the branch on Apr 9, 2014
  22. fanquake referenced this in commit e16f8720dc on Apr 21, 2021
  23. sidhujag referenced this in commit 75e7a76739 on Apr 21, 2021
  24. 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: 2026-04-13 15:16 UTC

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