cmake: Fix FindQt module #32709

pull hebasto wants to merge 2 commits into bitcoin:master from hebasto:250609-cmake-findqt changing 1 files +12 −3
  1. hebasto commented at 11:34 am on June 9, 2025: member

    This PR improves the FindQt module in two ways:

    1. Ensures that the find_package(Qt .. MODULE REQUIRED COMPONENTS ...) call treats any missing component as a fatal error. In the master branch, only a warning is currently issued.

    2. Cleans up the user-facing part of the CMake cache following the migration to Qt 6. An exception (Qt6_DIR) is documented.

  2. cmake: Fix `FindQt` module
    The `find_package(Qt .. MODULE REQUIRED COMPONENTS ...)` call must treat
    any missing component as a fatal error.
    8f1b55d1d5
  3. hebasto added the label Build system on Jun 9, 2025
  4. DrahtBot commented at 11:34 am on June 9, 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/32709.

    Reviews

    See the guideline for information on the review process. A summary of reviews will appear here.

  5. maflcko added the label DrahtBot Guix build requested on Jun 9, 2025
  6. in cmake/module/FindQt.cmake:44 in 2fa8e44359 outdated
    42 )
    43 
    44-foreach(component IN LISTS Qt_FIND_COMPONENTS ITEMS "")
    45-  mark_as_advanced(Qt${Qt_FIND_VERSION_MAJOR}${component}_DIR)
    46+# Mark all variables as advanced, except Qt6_DIR.
    47+# The latter can be helpful on some systems.
    


    fanquake commented at 2:17 pm on June 9, 2025:

    can be helpful on some systems.

    Can we document something more specific; I’m guessing this doesn’t close #32536?


    hebasto commented at 2:26 pm on June 9, 2025:

    can be helpful on some systems.

    Can we document something more specific;

    What do you have in mind?

    I’m guessing this doesn’t close #32536?

    Correct, it doesn’t. The Qt6_DIR cache variable can be set by the user to specify the location of a Qt 6 package that CMake cannot discover for some reason. The user should be able to see this variable in CMake’s cache.


    fanquake commented at 11:22 am on June 10, 2025:

    What do you have in mind?

    I don’t know, because it’s not clear from the commit or documentation why this is needed. I’d rather we document nothing than something vague like “can be helpful on some systems.”


    hebasto commented at 11:36 am on June 10, 2025:

    I’d rather we document nothing than something vague like “can be helpful on some systems.”

    OK. The comment has been dropped.

  7. DrahtBot commented at 9:06 pm on June 9, 2025: contributor

    Guix builds (on x86_64) [untrusted test-only build, possibly unsafe, not for production use]

    File commit f3bbc746647d1fd23bf5cfe357e32f38c5f6319c(master) commit d04b9346b6284fc32f4d82411048e6c02fe41315(pull/32709/merge)
    *-aarch64-linux-gnu-debug.tar.gz 40197981e100908b... b3acbdc542267201...
    *-aarch64-linux-gnu.tar.gz 60ba7c50f4bd5722... 526ad3bac6eb74e6...
    *-arm-linux-gnueabihf-debug.tar.gz a8043da9d5a1633a... 09f0a6d92224eec0...
    *-arm-linux-gnueabihf.tar.gz d9b3c37efb57c91f... 4366b8a4d1230e8f...
    *-arm64-apple-darwin-codesigning.tar.gz 5f8eb68ad8238fb4... 9d129d506196743e...
    *-arm64-apple-darwin-unsigned.tar.gz 764de9c61eecfddb... 4ad964f1b3316697...
    *-arm64-apple-darwin-unsigned.zip f74980bcdeff3b06... 78033279a9305844...
    *-powerpc64-linux-gnu-debug.tar.gz 403541d3d6fbae3c... cc7b9d48e0a0b533...
    *-powerpc64-linux-gnu.tar.gz da2710959fedc2a8... 1e05894d8c1b40f3...
    *-riscv64-linux-gnu-debug.tar.gz c7aef1609b518f6c... 5b9bac9646d02df2...
    *-riscv64-linux-gnu.tar.gz 305e2a4994205ae6... 0ee2a8034395d98b...
    *-x86_64-apple-darwin-codesigning.tar.gz 3f7e82ae32d6bdcb... ede8f98d8449662c...
    *-x86_64-apple-darwin-unsigned.tar.gz 9cbe91a75b71d43f... ec7af69a94f61dc2...
    *-x86_64-apple-darwin-unsigned.zip 69a0ae70a20744a5... c24ca79651256bfb...
    *-x86_64-linux-gnu-debug.tar.gz f81f3a804acfdf9b... c8694e0c7080050e...
    *-x86_64-linux-gnu.tar.gz e709b93e3b94a118... bb154917a7310893...
    *.tar.gz a3fd8aca7a44f3e9... 88677490f1ddd0af...
    SHA256SUMS.part 593b52564f7bda5d... 215239d7b7243c53...
    guix_build.log 5653bdee5863b4be... 1b3855d3ad561808...
    guix_build.log.diff 03a02a55ef3add66...
  8. DrahtBot removed the label DrahtBot Guix build requested on Jun 9, 2025
  9. cmake: Mark more Qt package variables as advanced
    This change cleans up the user-facing part of the CMake cache following
    the migration to Qt 6.
    89d3daf823
  10. hebasto force-pushed on Jun 10, 2025

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-06-15 06:13 UTC

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