depends: Update minimum required CMake version #31300

pull hebasto wants to merge 1 commits into bitcoin:master from hebasto:241116-deps-cmake changing 4 files +41 −4
  1. hebasto commented at 10:22 pm on November 16, 2024: member

    From the CMake 3.31 Release Notes:

    Compatibility with versions of CMake older than 3.10 is now deprecated and will be removed from a future version.

    This PR updates the cmake_minimum_required command across all packages in depends to ensure the minimum version is not set below 3.10.

    Without this change, CMake 3.31 emits a warning:

     0$ make -C depends freetype
     1make: Entering directory '/home/hebasto/git/bitcoin/depends'
     2Extracting freetype...
     3/home/hebasto/git/bitcoin/depends/sources/freetype-2.11.0.tar.xz: OK
     4Preprocessing freetype...
     5Configuring freetype...
     6CMake Deprecation Warning at CMakeLists.txt:100 (cmake_minimum_required):
     7  Compatibility with CMake < 3.10 will be removed from a future version of
     8  CMake.
     9
    10  Update the VERSION argument <min> value or use a ...<max> suffix to tell
    11  CMake that the project does not need compatibility with older versions.
    12
    13
    14-- The C compiler identification is GNU 13.2.0
    15< snip >
    
  2. depends: Update minimum required CMake version
    Compatibility with versions of CMake older than 3.10 is now deprecated
    and will be removed from a future version.
    
    See: https://cmake.org/cmake/help/v3.31/release/3.31.html
    b5a12350fa
  3. hebasto added the label Build system on Nov 16, 2024
  4. DrahtBot commented at 10:22 pm on November 16, 2024: 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/31300.

    Reviews

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

  5. hebasto commented at 9:19 am on November 17, 2024: member

    My Guix build:

     0x86_64
     1bb75dc6ee5cde4b85294a4c61948e4ae1d5ef5d011e671b494333f207c07c774  guix-build-b5a12350faf0/output/aarch64-linux-gnu/SHA256SUMS.part
     26bc0af6d7d9c76ef1c65ba631bdcd84f482f30ec3961460dfaf0e2721843f802  guix-build-b5a12350faf0/output/aarch64-linux-gnu/bitcoin-b5a12350faf0-aarch64-linux-gnu-debug.tar.gz
     3fa27f50aa27fd5a95200340612515a79e17df57cc65faceeeb0df4f31e5d4592  guix-build-b5a12350faf0/output/aarch64-linux-gnu/bitcoin-b5a12350faf0-aarch64-linux-gnu.tar.gz
     4c79b56bc518b387b7da72c8db717b738f339ea9c3b617f5c8dd49a1d68d34404  guix-build-b5a12350faf0/output/arm-linux-gnueabihf/SHA256SUMS.part
     5c117989052d852221338a187cc0af151afaff4336de523b6d163fab2f4ab35f5  guix-build-b5a12350faf0/output/arm-linux-gnueabihf/bitcoin-b5a12350faf0-arm-linux-gnueabihf-debug.tar.gz
     6fa75f6062171d55179d58505fbe392a14c5fb6d7f45254bc0059aaea01412943  guix-build-b5a12350faf0/output/arm-linux-gnueabihf/bitcoin-b5a12350faf0-arm-linux-gnueabihf.tar.gz
     7a6051fb91afea060e1d26b94b14c3d156747be8ba7aa0e96cdc08f3bcee90847  guix-build-b5a12350faf0/output/arm64-apple-darwin/SHA256SUMS.part
     867c7e7e6fb258d2ca622b0cf32f2cf45329cf1b9f096a5f97de2148073aee593  guix-build-b5a12350faf0/output/arm64-apple-darwin/bitcoin-b5a12350faf0-arm64-apple-darwin-unsigned.tar.gz
     941d2cfcfbf24302901ffad118a73c7b2f5ff388a33f552a3e5c4c5840e8a8e17  guix-build-b5a12350faf0/output/arm64-apple-darwin/bitcoin-b5a12350faf0-arm64-apple-darwin-unsigned.zip
    104e13941d7a9d0e3700c5b762e3ed041122e322bb4eb5a7b2ecaa25c363287407  guix-build-b5a12350faf0/output/arm64-apple-darwin/bitcoin-b5a12350faf0-arm64-apple-darwin.tar.gz
    1149aa71b716595b4df910c2a862c3e3c42de421f0a3496a569b291c797af47923  guix-build-b5a12350faf0/output/dist-archive/bitcoin-b5a12350faf0.tar.gz
    12d86ea1a3ade131425888febb4e4d0020b36f1f677e1e171d75ee3c5ec1513714  guix-build-b5a12350faf0/output/powerpc64-linux-gnu/SHA256SUMS.part
    13cd4e2b541fc1479fb1f6cfa555905c6c622a10efca4527102ed7452991359083  guix-build-b5a12350faf0/output/powerpc64-linux-gnu/bitcoin-b5a12350faf0-powerpc64-linux-gnu-debug.tar.gz
    1497bf4ecdedac7f33741e4f997696a1af200c2e6ac312e1cbb6f5e92757e52608  guix-build-b5a12350faf0/output/powerpc64-linux-gnu/bitcoin-b5a12350faf0-powerpc64-linux-gnu.tar.gz
    153ea32ed23ad403e562c9cf0eddda1190ea58272485645ad776864e8586459114  guix-build-b5a12350faf0/output/riscv64-linux-gnu/SHA256SUMS.part
    1619d85b45743fb242d96950fa610b3fef659d4ad5567c5b119c08354638cb2428  guix-build-b5a12350faf0/output/riscv64-linux-gnu/bitcoin-b5a12350faf0-riscv64-linux-gnu-debug.tar.gz
    17882a8ad0cea85ef987552b7586b26fcceee5c6e47939bb1295dcb3c0eb647b41  guix-build-b5a12350faf0/output/riscv64-linux-gnu/bitcoin-b5a12350faf0-riscv64-linux-gnu.tar.gz
    18588db4f34601193315006459852f0b865da47b8770671dbb3ef689390bdbd11d  guix-build-b5a12350faf0/output/x86_64-apple-darwin/SHA256SUMS.part
    192f2d4e8be3800cba72e1208a8118861b0ddd5abff1858e4bd150cfa38f0ae3a8  guix-build-b5a12350faf0/output/x86_64-apple-darwin/bitcoin-b5a12350faf0-x86_64-apple-darwin-unsigned.tar.gz
    20bba5370d78d79d21532cc45f3413ca0beef69ef0d95aeb656d14c5f74d4d1622  guix-build-b5a12350faf0/output/x86_64-apple-darwin/bitcoin-b5a12350faf0-x86_64-apple-darwin-unsigned.zip
    216d8c4da7e609f7c4027f911b8aafe53a84b4a3d232b0c42c70f1ecfdd2830386  guix-build-b5a12350faf0/output/x86_64-apple-darwin/bitcoin-b5a12350faf0-x86_64-apple-darwin.tar.gz
    22d98671dd280042ae71edc5e74329b60a5c32d8ee0e480b8ef71557416f297cf9  guix-build-b5a12350faf0/output/x86_64-linux-gnu/SHA256SUMS.part
    23a141218a6987f104946cdad6c9ff89753432f981ddf5c7d960cffcedfdb6e6aa  guix-build-b5a12350faf0/output/x86_64-linux-gnu/bitcoin-b5a12350faf0-x86_64-linux-gnu-debug.tar.gz
    24a921b5d7c2ce30d8e482a897c87a71724b4c6f5186ec78e2812fa522c5771035  guix-build-b5a12350faf0/output/x86_64-linux-gnu/bitcoin-b5a12350faf0-x86_64-linux-gnu.tar.gz
    25bfc445216649bffe476810b7719676b143fd4f7ee90442ad3506aeabca028f44  guix-build-b5a12350faf0/output/x86_64-w64-mingw32/SHA256SUMS.part
    26ca338c730efe1bd5682eafc0dd0f61e17dd7d6c98138683fe47ea1871d490aa0  guix-build-b5a12350faf0/output/x86_64-w64-mingw32/bitcoin-b5a12350faf0-win64-debug.zip
    2734676fbcd22bdb7c6987e2e699e672593e782d9399dc64a428c9ba9047f04de4  guix-build-b5a12350faf0/output/x86_64-w64-mingw32/bitcoin-b5a12350faf0-win64-setup-unsigned.exe
    28f18544cb06d28cd47b363ae887763f4ec94d77cb379b9c90e198400e8439b20c  guix-build-b5a12350faf0/output/x86_64-w64-mingw32/bitcoin-b5a12350faf0-win64-unsigned.tar.gz
    29d9842c26418a96104fbb46016d5c341a1d3362be1a97a0bc1e2079dbf5dd2d03  guix-build-b5a12350faf0/output/x86_64-w64-mingw32/bitcoin-b5a12350faf0-win64.zip
    
  6. maflcko commented at 10:52 am on November 17, 2024: member

    Is there a reason to pick 3.10, when someone couldn’t compile Bitcoin Core later on anyway with that version? See https://github.com/bitcoin/bitcoin/blob/ccc2d3abcd39c64a78e366f3e4794de729155e9e/CMakeLists.txt#L10

    Also, according to #31299 (comment) 3.13 may be required anyway?

  7. TheCharlatan commented at 10:00 pm on November 17, 2024: contributor
    The selected versions in the patches seem random, why not pick the same value for all of them? Is there also precedent for us making patches just to silence warnings?
  8. hebasto commented at 10:08 pm on November 17, 2024: member

    Is there also precedent for us making patches just to silence warnings?

    depends/patches/qrencode/cmake_fixups.patch?

    This PR is not about silencing warnings but ensuring that deprecated CMake versions are not used.

  9. in depends/patches/freetype/cmake_minimum.patch:22 in b5a12350fa
    17+-  cmake_policy(SET CMP0063 NEW)
    18+-
    19+-  # Support new IN_LIST if() operator.
    20+-  cmake_policy(SET CMP0057 NEW)
    21+-endif ()
    22++cmake_minimum_required(VERSION 3.16)
    


    maflcko commented at 10:20 am on November 18, 2024:
    Why not submit this upstream and update? See also https://gitlab.freedesktop.org/freetype/freetype/-/merge_requests/143/diffs
  10. fanquake commented at 1:56 pm on November 19, 2024: member

    The selected versions in the patches seem random, why not pick the same value for all of them?

    Yea. If anything, just consolidate to the same minimum required version as Core.


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-21 06:12 UTC

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