Add aarch64 qt depends support for cross compiling bitcoin-qt #13696

pull TheCharlatan wants to merge 1 commits into bitcoin:master from TheCharlatan:aarch64Depends changing 3 files +6 −3
  1. TheCharlatan commented at 10:21 pm on July 17, 2018: member

    This also adds a generic qt linux target in packages.mk . I am a bit confused by the existing docs for the RISC addition. Are there boards that would support running bitcoin-qt, or at the very least forwarding X over ssh? Is everybody building depends with NO_QT=1 when targeting RISC? If not, I will revert the change for a generic qt linux package definition back to the piecemeal solution.

    This pull request should close #13495

  2. fanquake added the label Build system on Jul 17, 2018
  3. fanquake requested review from theuni on Jul 17, 2018
  4. laanwj commented at 7:45 am on July 18, 2018: member

    Are there boards that would support running bitcoin-qt, or at the very least forwarding X over ssh? Is everybody building depends with NO_QT=1 when targeting RISC?

    There apparently are boards that support that according to this comment: #13543 (comment) That said, the RISC-V depends build for qt currently doesn’t work. NO_QT=1 is required. PR #13660 aims to solve that.

  5. Sjors commented at 8:04 am on July 18, 2018: member

    Being able to incrementally add QT binaries for new architecture is probably useful.

    Make sure to try a Gitian build, see #13700.

  6. Sjors commented at 10:36 am on July 18, 2018: member

    I was able to cross compile this on a Bionic host.

    I don’t have a desktop environment at the moment, but bitcoin-qt --help my device complains:

    0./bitcoin-qt: error while loading shared libraries: libfontconfig.so.1: cannot open shared object file: No such file or directory
    
  7. DrahtBot added the label Needs gitian build on Jul 18, 2018
  8. theuni commented at 11:28 pm on July 18, 2018: member

    I’d rather not have to add this for every arch we encounter. It’s annoying that qt doesn’t have a generic target allowing you to specify individual toolchain components, so I made my own:

    See here: https://github.com/theuni/bitcoin/commit/b7204784516e12cb09ff0ccb875f3905da29ff71 @TheCharlatan how about pulling that in rather than the second chunk here?

    Edit: Also, note that there’s no longer anything arch-specific in the qt recipe. So it’s possible that arches like risc-v “just work” now. I think that’s a good enough justification for getting rid of the conditional qt build.

  9. TheCharlatan commented at 12:03 pm on July 20, 2018: member
    @theuni added your commit on top of mine. Great Work, this should make everything build.
  10. TheCharlatan force-pushed on Jul 20, 2018
  11. TheCharlatan force-pushed on Jul 20, 2018
  12. Sjors commented at 2:00 pm on July 20, 2018: member

    this should make everything build

    Except Travis :trollface:

    My MacOS isn’t happy either, at the end:

    0ERROR: Feature 'openssl-linked' was enabled, but the pre-condition '!features.securetransport && libs.openssl' failed.
    1
    2ERROR: Feature 'openssl' was enabled, but the pre-condition '!features.securetransport && (features.openssl-linked || libs.openssl_headers)' failed.
    3make: *** [/Volumes/SSD/src/bitcoin/depends/work/build/x86_64-apple-darwin17.6.0/qt/5.9.6-cb944b1f839/qtbase/.stamp_configured] Error 3
    

    I’ll try the cross-compiled QT binaries again on a 64 bit device shortly.

  13. theuni commented at 3:30 pm on July 20, 2018: member

    Huh, I guess clang ends up using the gcc flags. qt’s buildsystem is so wonky!

    Testing a fix.

  14. theuni commented at 6:56 pm on July 20, 2018: member

    @TheCharlatan See here: https://github.com/theuni/bitcoin/commits/13696 That’s 3 more commits on top of the one here.

    That adds a generic config for macOS like the linux one, and fixes up a few things with the linux/mingw build.

    Ideally we’d create a bitcoin-specific device for mingw as well so that everything builds the same, but I won’t be able to get to that today. Any volunteers? :)

    Ordinarily I’d suggest that we just merge the previous version of your PR as-is, then merge my changes as a follow-up, but That would mean travis would be rebuilding depends a whole bunch of times, so I’d prefer to knock this out in one go.

  15. TheCharlatan force-pushed on Jul 20, 2018
  16. MarcoFalke removed the label Needs gitian build on Jul 21, 2018
  17. Sjors commented at 7:54 am on July 21, 2018: member

    I’m still getting the same OpenSSL error when building depends on macOS with 900c53a. Here’s my log.

    Cross-compile (on Bionic) also still gets me the same error on the device (while the bitcoind binary doesn’t have that problem):

    0./bitcoin-qt: error while loading shared libraries: libfontconfig.so.1: cannot open shared object file: No such file or directory
    
  18. DrahtBot commented at 1:27 pm on July 22, 2018: member
    • #12775 (Integration of property based testing into Bitcoin Core by Christewart)
    • #8469 ([POC] Introducing property based testing to Core by Christewart)

    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.

  19. MarcoFalke added the label Needs gitian build on Jul 22, 2018
  20. DrahtBot removed the label Needs gitian build on Jul 23, 2018
  21. TheCharlatan commented at 9:59 am on July 23, 2018: member
    Drahtbot also does not seem to build bitcoin-qt (or at least it is not present in the aarch64 archive).
  22. TheCharlatan commented at 10:02 am on July 23, 2018: member
    Sorry, looked at the wrong archive. It does indeed build bitcoin-qt. @Sjors maybe your problem with openssl is unrelated after all.
  23. Sjors commented at 12:35 pm on July 23, 2018: member

    If @DrahtBot can build it using Gitian, then that’s good enough for me now. Will figure out what’s wrong with my Gitian machine.

    Running that binary on my device, it now throwsqt.qpa.screen: QXcbConnection: Could not connect to display, which is what I would except given the lack of display.

  24. Sjors commented at 11:56 am on July 24, 2018: member

    Tried again on Bionic:

    0sha256sum src/qt/bitcoin-qt 
    12a692455e5f943761f4c164036bb4932eb8fe56f9ca99f847c636b38af29398d  src/qt/bitcoin-qt
    

    Now it correctly throws Could not connect to display. So sounds like I was doing something wrong before, probably silent failure due to a missing dependency.

    I installed a desktop for the occasion:

    khadas

    I also tried building the depends again on macOS. For that I rebased on master just in case, because master works (except for #13750, but this PR removes that problematic line). Still the same OpenSSL error. I’ll dig a bit more.

  25. Sjors commented at 12:24 pm on July 24, 2018: member
    • 0bbe8990 + 12c93cb85b6cb075d22323ff02acebbe05e42375: works
    • dd2e90ac1bdf95330771b375e27f81d4d78720cd (@theuni’s patch): trouble
  26. theuni commented at 6:52 pm on July 24, 2018: member
    @Sjors yes, my changes will cause problems for native macOS builds. I’ll work on fixing that up.
  27. DrahtBot added the label Needs rebase on Jul 25, 2018
  28. MarcoFalke deleted a comment on Jul 25, 2018
  29. laanwj added this to the milestone 0.17.0 on Jul 25, 2018
  30. TheCharlatan force-pushed on Jul 26, 2018
  31. TheCharlatan commented at 10:04 am on July 26, 2018: member
    Rebased.
  32. DrahtBot removed the label Needs rebase on Jul 26, 2018
  33. DrahtBot added the label Needs rebase on Jul 29, 2018
  34. Add aarch64 qt depends support for cross compiling bitcoin-qt 00db418176
  35. TheCharlatan force-pushed on Jul 29, 2018
  36. DrahtBot removed the label Needs rebase on Jul 29, 2018
  37. MarcoFalke commented at 2:37 pm on July 29, 2018: member
    What is the status of native macOS build on this pull request? If we can’t get these to work, we should probably remove the 0.17 milestone?
  38. ken2812221 commented at 4:00 pm on July 29, 2018: contributor
    I think we can rollback to the previous way and use generic config after 0.17 branch split off.
  39. TheCharlatan commented at 9:18 am on July 30, 2018: member
    @theuni , are you fine with rolling back to my initial commit, or do you have a fix available already?
  40. theuni commented at 4:44 pm on August 1, 2018: member

    @TheCharlatan Yes, I guess rolling back would be best. Sorry for the back and forth :(

    Qmake doesn’t seem to support what I’m trying to do at all, so I’ll put the more invasive changes on hold until the next qt bump. Maybe we’ll end up with a nice clean qt build just in time for some wacky new Qt6 buildsystem :)

  41. TheCharlatan force-pushed on Aug 1, 2018
  42. TheCharlatan commented at 9:08 pm on August 1, 2018: member
    Force pushed to remove the generic qt builds. @theuni I created a seperate branch on my repo that still contains your changes as they were before.
  43. TheCharlatan commented at 10:14 pm on August 1, 2018: member
    I’ll be offline the next two weeks, but would still very much like this to go into 0.17. If anything needs to be added/changed, feel free to close this and reopen as another pr.
  44. Sjors commented at 9:01 am on August 2, 2018: member
    Thanks! I already tested 0bbe899 above, and 00db418 is the same but rebased, so tACK. @MarcoFalke can you do one of those fancy gitian builds to make sure 64-bit QT for ARM is now in it?
  45. fanquake added the label Needs gitian build on Aug 2, 2018
  46. DrahtBot commented at 1:24 am on August 3, 2018: member

    Gitian builds for commit aa30e4bb8fc15d7f83845effb5a95eee68681199 (master):

    Gitian builds for commit 4f5ff4cfec6d5fc61d2ab4c0e509a5dab9889661 (master and this pull):

  47. DrahtBot removed the label Needs gitian build on Aug 3, 2018
  48. ken2812221 commented at 7:20 am on August 3, 2018: contributor
    utACK 00db418
  49. Sjors commented at 5:11 pm on August 3, 2018: member
    Tested the new Gitian binaries again on a desktop. For some reason I can’t interact with a keyboard at all, e.g. I can’t type commands in the console screen. I tried both a physical and onscreen keyboard. This might be some quirk with my device, but would be good if someone else tried it too.
  50. MarcoFalke merged this on Aug 5, 2018
  51. MarcoFalke closed this on Aug 5, 2018

  52. MarcoFalke referenced this in commit 2ab72080ad on Aug 5, 2018
  53. TheCharlatan deleted the branch on Aug 15, 2019
  54. PastaPastaPasta referenced this in commit a9651e5e70 on Jul 29, 2020
  55. PastaPastaPasta referenced this in commit cd3248d3fd on Jul 29, 2020
  56. PastaPastaPasta referenced this in commit bd8f48820e on Jul 29, 2020
  57. CryptoCentric referenced this in commit 2aa44c5021 on Jul 2, 2021
  58. DrahtBot locked this on Dec 16, 2021

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-12-19 03:12 UTC

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