Unable to cross compile on linux for macos (28.x branch) #31027

issue JayBitron opened this issue on October 3, 2024
  1. JayBitron commented at 4:17 PM on October 3, 2024: none

    Is there an existing issue for this?

    • I have searched the existing issues

    Current behaviour

    Running the command make HOST=x86_64-apple-darwin -C depends on Bitcoin Core 28.x no longer compiles the dependencies as expected. It fails.

    Expected behaviour

    The command make HOST=x86_64-apple-darwin -C depends should successfully compile all required dependencies without errors, as it did in previous versions of Bitcoin Core.

    Steps to reproduce

    make HOST=x86_64-apple-darwin -C depends -j32

    Relevant log output

    root@localhost:~/.build/bitcoin-untouched# make HOST=x86_64-apple-darwin -C depends -j32
    make: Entering directory '/root/.build/bitcoin-untouched/depends'
    Fetching boost_1_81_0.tar.gz from https://archives.boost.io/release/1.81.0/source/
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
    100  133M  100  133M    0     0  1221k      0  0:01:52  0:01:52 --:--:-- 1183k
    /root/.build/bitcoin-untouched/depends/work/download/boost-1.81.0/boost_1_81_0.tar.gz.temp: OK
    Extracting boost...
    /root/.build/bitcoin-untouched/depends/sources/boost_1_81_0.tar.gz: OK
    Preprocessing boost...
    Configuring boost...
    Building boost...
    Staging boost...
    Postprocessing boost...
    Caching boost...
    Fetching libevent-2.1.12-stable.tar.gz from https://github.com/libevent/libevent/releases/download/release-2.1.12-stable/
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
      0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
    100 1075k  100 1075k    0     0   389k      0  0:00:02  0:00:02 --:--:--  885k
    /root/.build/bitcoin-untouched/depends/work/download/libevent-2.1.12-stable/libevent-2.1.12-stable.tar.gz.temp: OK
    Extracting libevent...
    /root/.build/bitcoin-untouched/depends/sources/libevent-2.1.12-stable.tar.gz: OK
    Preprocessing libevent...
    patching file CMakeLists.txt
    patching file cmake/AddEventLibrary.cmake
    patching file CMakeLists.txt
    Configuring libevent...
    -- The C compiler identification is Clang 14.0.6
    -- Detecting C compiler ABI info
    -- Detecting C compiler ABI info - failed
    -- Check for working C compiler: /usr/bin/clang
    -- Check for working C compiler: /usr/bin/clang - broken
    CMake Error at /usr/share/cmake-3.25/Modules/CMakeTestCCompiler.cmake:70 (message):
      The C compiler
    
        "/usr/bin/clang"
    
      is not able to compile a simple test program.
    
      It fails with the following output:
    
        Change Dir: /root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeScratch/TryCompile-Y3lnvg
    
        Run Build Command(s):/usr/bin/gmake -f Makefile cmTC_bccc1/fast && gmake[1]: Entering directory '/root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeScratch/TryCompile-Y3lnvg'
        /usr/bin/gmake  -f CMakeFiles/cmTC_bccc1.dir/build.make CMakeFiles/cmTC_bccc1.dir/build
        gmake[2]: Entering directory '/root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeScratch/TryCompile-Y3lnvg'
        Building C object CMakeFiles/cmTC_bccc1.dir/testCCompiler.c.o
        /usr/bin/clang  --target=x86_64-apple-darwin -isysroot/root/.build/bitcoin-untouched/depends/SDKs/Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers -nostdlibinc -iwithsysroot/usr/include -iframeworkwithsysroot/System/Library/Frameworks --target=x86_64-apple-darwin   -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -I/root/.build/bitcoin-untouched/depends/x86_64-apple-darwin/include -D_GNU_SOURCE -D_FORTIFY_SOURCE=3  -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -fPIE -MD -MT CMakeFiles/cmTC_bccc1.dir/testCCompiler.c.o -MF CMakeFiles/cmTC_bccc1.dir/testCCompiler.c.o.d -o CMakeFiles/cmTC_bccc1.dir/testCCompiler.c.o -c /root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeScratch/TryCompile-Y3lnvg/testCCompiler.c
        Linking C executable cmTC_bccc1
        /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_bccc1.dir/link.txt --verbose=1
        /usr/bin/clang  --target=x86_64-apple-darwin -isysroot/root/.build/bitcoin-untouched/depends/SDKs/Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers -nostdlibinc -iwithsysroot/usr/include -iframeworkwithsysroot/System/Library/Frameworks --target=x86_64-apple-darwin -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -I/root/.build/bitcoin-untouched/depends/x86_64-apple-darwin/include -D_GNU_SOURCE -D_FORTIFY_SOURCE=3  -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -Wl,-headerpad_max_install_names -L/usr/local/python-3.12.6/lib -L/usr/local/node-v22.9.0/lib -L/usr/local/python-3.12.6/lib -L/usr/local/node-v22.9.0/lib  -L/root/.build/bitcoin-untouched/depends/x86_64-apple-darwin/lib  CMakeFiles/cmTC_bccc1.dir/testCCompiler.c.o -o cmTC_bccc1
        clang: warning: argument unused during compilation: '-nostdlibinc' [-Wunused-command-line-argument]
        /usr/bin/ld: unrecognised emulation mode: acosx_version_min
        Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 elf_iamcu i386pep i386pe
        clang: error: linker command failed with exit code 1 (use -v to see invocation)
        gmake[2]: *** [CMakeFiles/cmTC_bccc1.dir/build.make:100: cmTC_bccc1] Error 1
        gmake[2]: Leaving directory '/root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeScratch/TryCompile-Y3lnvg'
        gmake[1]: *** [Makefile:127: cmTC_bccc1/fast] Error 2
        gmake[1]: Leaving directory '/root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeScratch/TryCompile-Y3lnvg'
    
    
    
    
    
      CMake will not be able to correctly generate this project.
    Call Stack (most recent call first):
      CMakeLists.txt:47 (project)
    
    
    -- Configuring incomplete, errors occurred!
    See also "/root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeOutput.log".
    See also "/root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeError.log".
    make: *** [funcs.mk:302: /root/.build/bitcoin-untouched/depends/x86_64-apple-darwin/.libevent_stamp_configured] Error 1
    make: Leaving directory '/root/.build/bitcoin-untouched/depends'
    

    How did you obtain Bitcoin Core

    Compiled from source

    What version of Bitcoin Core are you using?

    28.x

    Operating system and version

    Debian 12.7.0

    Machine specifications

    No response

  2. hebasto commented at 6:27 PM on October 3, 2024: member

    @JayBitron

    Can you reproduce the issue in a fresh Docker container?

  3. hebasto added the label Build system on Oct 3, 2024
  4. hebasto commented at 6:29 PM on October 3, 2024: member
  5. JayBitron commented at 6:36 PM on October 3, 2024: none

    @hebasto Yes, it's a fresh new intstalled linux, I don't use docker, I've been compiling bitcoin for macos since version 25.x had no problem, yes, I've the macos SDK

  6. hebasto commented at 7:15 PM on October 3, 2024: member

    @JayBitron

    -- The C compiler identification is Clang 14.0.6

    Please ensure the minimum required Clang version, which is 16.0 for v28.0.

    Additionally, you may need the lld package installed (the same version as llvm/clang).

  7. JayBitron commented at 7:17 PM on October 3, 2024: none

    @hebasto Altho the stable version of debian provides the clang 14, I have done also the clang 16 and even upper version, they throw different errors

  8. JayBitron commented at 7:26 PM on October 3, 2024: none

    @hebasto lld is installed

    root@localhost:~/.build/bitcoin-macos# make HOST=x86_64-apple-darwin -C depends -j32
    make: Entering directory '/root/.build/bitcoin-macos/depends'
    Configuring libevent...
    -- The C compiler identification is Clang 20.0.0
    -- Detecting C compiler ABI info
    -- Detecting C compiler ABI info - failed
    -- Check for working C compiler: /usr/bin/clang
    -- Check for working C compiler: /usr/bin/clang - broken
    CMake Error at /usr/share/cmake-3.30/Modules/CMakeTestCCompiler.cmake:67 (message):
      The C compiler
    
        "/usr/bin/clang"
    
      is not able to compile a simple test program.
    
      It fails with the following output:
    
        Change Dir: '/root/.build/bitcoin-macos/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-7c8a3b34ae1/build/CMakeFiles/CMakeScratch/TryCompile-ynpflf'
    
        Run Build Command(s): /usr/bin/cmake -E env VERBOSE=1 /usr/bin/gmake -f Makefile cmTC_8a4e1/fast
        gmake[1]: Entering directory '/root/.build/bitcoin-macos/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-7c8a3b34ae1/build/CMakeFiles/CMakeScratch/TryCompile-ynpflf'
        /usr/bin/gmake  -f CMakeFiles/cmTC_8a4e1.dir/build.make CMakeFiles/cmTC_8a4e1.dir/build
        gmake[2]: Entering directory '/root/.build/bitcoin-macos/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-7c8a3b34ae1/build/CMakeFiles/CMakeScratch/TryCompile-ynpflf'
        Building C object CMakeFiles/cmTC_8a4e1.dir/testCCompiler.c.o
        /usr/bin/clang  --target=x86_64-apple-darwin -isysroot/root/.build/bitcoin-macos/depends/SDKs/Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers -nostdlibinc -iwithsysroot/usr/include -iframeworkwithsysroot/System/Library/Frameworks --target=x86_64-apple-darwin   -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -I/root/.build/bitcoin-macos/depends/x86_64-apple-darwin/include -D_GNU_SOURCE -D_FORTIFY_SOURCE=3  -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -fPIE -MD -MT CMakeFiles/cmTC_8a4e1.dir/testCCompiler.c.o -MF CMakeFiles/cmTC_8a4e1.dir/testCCompiler.c.o.d -o CMakeFiles/cmTC_8a4e1.dir/testCCompiler.c.o -c /root/.build/bitcoin-macos/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-7c8a3b34ae1/build/CMakeFiles/CMakeScratch/TryCompile-ynpflf/testCCompiler.c
        Linking C executable cmTC_8a4e1
        /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_8a4e1.dir/link.txt --verbose=1
        /usr/bin/clang  --target=x86_64-apple-darwin -isysroot/root/.build/bitcoin-macos/depends/SDKs/Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers -nostdlibinc -iwithsysroot/usr/include -iframeworkwithsysroot/System/Library/Frameworks --target=x86_64-apple-darwin -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -I/root/.build/bitcoin-macos/depends/x86_64-apple-darwin/include -D_GNU_SOURCE -D_FORTIFY_SOURCE=3  -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -Wl,-headerpad_max_install_names -L/usr/local/python-3.12.6/lib -L/usr/local/node-v22.9.0/lib -L/usr/local/python-3.12.6/lib -L/usr/local/node-v22.9.0/lib  -L/root/.build/bitcoin-macos/depends/x86_64-apple-darwin/lib  CMakeFiles/cmTC_8a4e1.dir/testCCompiler.c.o -o cmTC_8a4e1
        /usr/bin/ld: unrecognised emulation mode: llvm
        Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 elf_iamcu i386pep i386pe
        clang: error: linker command failed with exit code 1 (use -v to see invocation)
        gmake[2]: *** [CMakeFiles/cmTC_8a4e1.dir/build.make:100: cmTC_8a4e1] Error 1
        gmake[2]: Leaving directory '/root/.build/bitcoin-macos/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-7c8a3b34ae1/build/CMakeFiles/CMakeScratch/TryCompile-ynpflf'
        gmake[1]: *** [Makefile:127: cmTC_8a4e1/fast] Error 2
        gmake[1]: Leaving directory '/root/.build/bitcoin-macos/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-7c8a3b34ae1/build/CMakeFiles/CMakeScratch/TryCompile-ynpflf'
    
    
    
    
    
      CMake will not be able to correctly generate this project.
    Call Stack (most recent call first):
      CMakeLists.txt:47 (project)
    
    
    -- Configuring incomplete, errors occurred!
    make: *** [funcs.mk:302: /root/.build/bitcoin-macos/depends/x86_64-apple-darwin/.libevent_stamp_configured] Error 1
    make: Leaving directory '/root/.build/bitcoin-macos/depends'
    
  9. hebasto commented at 10:29 PM on October 3, 2024: member

    Here are the steps to build depends without Qt on Debian 12:

    apt update
    apt install git bison cmake curl make pkg-config xz-utils wget
    # Install minimum required version of LLVM toolchain
    apt install clang-16 llvm-16 lld-16
    # Create non-versioned symlinks of the tools
    ln -s /usr/bin/clang-16 /usr/bin/clang
    ln -s /usr/bin/clang++-16 /usr/bin/clang++
    ln -s /usr/bin/lld-16 /usr/bin/lld
    ln -s /usr/bin/ld.lld-16 /usr/bin/ld.lld
    ln -s /usr/bin/lld-link-16 /usr/bin/lld-link
    ln -s /usr/bin/llvm-ar-16 /usr/bin/llvm-ar
    ln -s /usr/bin/llvm-ranlib-16 /usr/bin/llvm-ranlib
    # Prepare Bitcoin Core repository
    git clone https://github.com/bitcoin/bitcoin.git
    wget https://raw.githubusercontent.com/hebasto/artefacts/refs/heads/Xcode/Xcode/Xcode-15.0/Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers.tar.gz
    mkdir -p bitcoin/depends/SDKs
    tar xf Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers.tar.gz -C bitcoin/depends/SDKs
    cd bitcoin
    git checkout v28.0
    # Cross-compile non-GUI dependencies
    make -j 16 -C depends HOST=x86_64-apple-darwin NO_QT=1
    

    Please note that building the qt package requires g++ and a newer clang.

  10. JayBitron commented at 11:02 PM on October 3, 2024: none

    I'm using version 20 it returns /usr/bin/ld: unrecognised emulation mode: llvm when I create symbolic links to version 16 it returns /usr/bin/ld: unrecognised emulation mode: acosx_version_min It's is different error on each version

  11. JayBitron commented at 11:24 PM on October 3, 2024: none

    debian unstable (sid) runs on clang-20 doesn't need to downgrade it

  12. JayBitron commented at 11:37 PM on October 3, 2024: none

    I just freshly installed a linux and went the steps as you said still getting this error:

    root@localhost:~/.build/bitcoin# make -C depends HOST=x86_64-apple-darwin -j32
    make: Entering directory '/root/.build/bitcoin/depends'
    Fetching boost_1_81_0.tar.gz from https://archives.boost.io/release/1.81.0/source/
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
    100  133M  100  133M    0     0  1252k      0  0:01:49  0:01:49 --:--:-- 1241k
    /root/.build/bitcoin/depends/work/download/boost-1.81.0/boost_1_81_0.tar.gz.temp: OK
    Extracting boost...
    /root/.build/bitcoin/depends/sources/boost_1_81_0.tar.gz: OK
    Preprocessing boost...
    Configuring boost...
    Building boost...
    Staging boost...
    Postprocessing boost...
    Caching boost...
    Fetching libevent-2.1.12-stable.tar.gz from https://github.com/libevent/libevent/releases/download/release-2.1.12-stable/
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
      0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
    100 1075k  100 1075k    0     0   275k      0  0:00:03  0:00:03 --:--:--  372k
    /root/.build/bitcoin/depends/work/download/libevent-2.1.12-stable/libevent-2.1.12-stable.tar.gz.temp: OK
    Extracting libevent...
    /root/.build/bitcoin/depends/sources/libevent-2.1.12-stable.tar.gz: OK
    Preprocessing libevent...
    patching file CMakeLists.txt
    patching file cmake/AddEventLibrary.cmake
    patching file CMakeLists.txt
    Configuring libevent...
    -- The C compiler identification is Clang 16.0.6
    -- Detecting C compiler ABI info
    -- Detecting C compiler ABI info - failed
    -- Check for working C compiler: /usr/bin/clang
    -- Check for working C compiler: /usr/bin/clang - broken
    CMake Error at /usr/share/cmake-3.25/Modules/CMakeTestCCompiler.cmake:70 (message):
      The C compiler
    
        "/usr/bin/clang"
    
      is not able to compile a simple test program.
    
      It fails with the following output:
    
        Change Dir: /root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeScratch/TryCompile-RUU5h5
    
        Run Build Command(s):/usr/bin/gmake -f Makefile cmTC_920c1/fast && gmake[1]: Entering directory '/root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeScratch/TryCompile-RUU5h5'
        /usr/bin/gmake  -f CMakeFiles/cmTC_920c1.dir/build.make CMakeFiles/cmTC_920c1.dir/build
        gmake[2]: Entering directory '/root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeScratch/TryCompile-RUU5h5'
        Building C object CMakeFiles/cmTC_920c1.dir/testCCompiler.c.o
        /usr/bin/clang  --target=x86_64-apple-darwin -isysroot/root/.build/bitcoin/depends/SDKs/Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers -nostdlibinc -iwithsysroot/usr/include -iframeworkwithsysroot/System/Library/Frameworks --target=x86_64-apple-darwin   -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -I/root/.build/bitcoin/depends/x86_64-apple-darwin/include -D_GNU_SOURCE -D_FORTIFY_SOURCE=3  -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -fPIE -MD -MT CMakeFiles/cmTC_920c1.dir/testCCompiler.c.o -MF CMakeFiles/cmTC_920c1.dir/testCCompiler.c.o.d -o CMakeFiles/cmTC_920c1.dir/testCCompiler.c.o -c /root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeScratch/TryCompile-RUU5h5/testCCompiler.c
        Linking C executable cmTC_920c1
        /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_920c1.dir/link.txt --verbose=1
        /usr/bin/clang  --target=x86_64-apple-darwin -isysroot/root/.build/bitcoin/depends/SDKs/Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers -nostdlibinc -iwithsysroot/usr/include -iframeworkwithsysroot/System/Library/Frameworks --target=x86_64-apple-darwin -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -I/root/.build/bitcoin/depends/x86_64-apple-darwin/include -D_GNU_SOURCE -D_FORTIFY_SOURCE=3  -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include -I/usr/local/python-3.12.6/include -I/usr/local/node-v22.9.0/include  -Wl,-headerpad_max_install_names -L/usr/local/python-3.12.6/lib -L/usr/local/node-v22.9.0/lib -L/usr/local/python-3.12.6/lib -L/usr/local/node-v22.9.0/lib  -L/root/.build/bitcoin/depends/x86_64-apple-darwin/lib  CMakeFiles/cmTC_920c1.dir/testCCompiler.c.o -o cmTC_920c1
        clang: warning: argument unused during compilation: '-nostdlibinc' [-Wunused-command-line-argument]
        /usr/bin/ld: unrecognised emulation mode: acosx_version_min
        Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 elf_iamcu i386pep i386pe
        clang: error: linker command failed with exit code 1 (use -v to see invocation)
        gmake[2]: *** [CMakeFiles/cmTC_920c1.dir/build.make:100: cmTC_920c1] Error 1
        gmake[2]: Leaving directory '/root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeScratch/TryCompile-RUU5h5'
        gmake[1]: *** [Makefile:127: cmTC_920c1/fast] Error 2
        gmake[1]: Leaving directory '/root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeScratch/TryCompile-RUU5h5'
    
    
    
    
    
      CMake will not be able to correctly generate this project.
    Call Stack (most recent call first):
      CMakeLists.txt:47 (project)
    
    
    -- Configuring incomplete, errors occurred!
    See also "/root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeOutput.log".
    See also "/root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeError.log".
    make: *** [funcs.mk:302: /root/.build/bitcoin/depends/x86_64-apple-darwin/.libevent_stamp_configured] Error 1
    make: Leaving directory '/root/.build/bitcoin/depends'
    
  13. JayBitron commented at 11:40 PM on October 3, 2024: none

    I know now bitcoin 28.x macos builds are broken officially, in 27.x all tools were built in, about 800MB down was taken down.

  14. JayBitron commented at 11:45 PM on October 3, 2024: none

    Yes, I see native_llvm.mk was removed from 28.x

  15. hebasto commented at 9:59 AM on October 4, 2024: member

    debian unstable (sid) runs on clang-20 doesn't need to downgrade it

    Debian Sid's default clang is clang-16, which is enough to build every dependency except for the qt package.

    Here is a full log of the commands on a fresh Debian Sid image:

    # history 
        1  apt update
        2  apt install git bison cmake curl make pkg-config xz-utils wget
        3  apt install clang llvm lld
        4  git clone https://github.com/bitcoin/bitcoin.git
        5  wget https://raw.githubusercontent.com/hebasto/artefacts/refs/heads/Xcode/Xcode/Xcode-15.0/Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers.tar.gz
        6  mkdir -p bitcoin/depends/SDKs
        7  tar xf Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers.tar.gz -C bitcoin/depends/SDKs
        8  cd bitcoin
        9  git checkout v28.0
       10  make -j 16 -C depends HOST=x86_64-apple-darwin NO_QT=1
       11  history 
    

    Please ensure that your environment, including compiler-specific variables, is not modified somehow.

  16. JayBitron commented at 7:12 AM on October 5, 2024: none

    @hebasto can you try compiling yourself, including the qt wallet

  17. pinheadmz commented at 1:14 PM on October 5, 2024: member

    I'm getting the same error but inside a guix build: https://gist.github.com/pinheadmz/a2603f7f62c7627f33a10d8f39443f20

  18. pinheadmz commented at 1:52 PM on October 5, 2024: member

    Update: re-downloaded Xcode and re-extracted the SDK, guix build is proceeding again

  19. JayBitron closed this on Oct 6, 2024

  20. tofutim commented at 7:36 PM on February 8, 2025: none

    Update: re-downloaded Xcode and re-extracted the SDK, guix build is proceeding again

    Did it work after re-extracting the SDK? I had no luck with 28.1. Trying 27.2 now.

    Update. Ends with:

    checking for x86_64-apple-darwin-gcc... env -u C_INCLUDE_PATH -u CPLUS_INCLUDE_PATH -u OBJC_INCLUDE_PATH -u OBJCPLUS_INCLUDE_PATH -u CPATH -u LIBRARY_PATH /home/tim/.guix-profile/bin/clang --target=x86_64-apple-darwin -B/bitcoin/depends/x86_64-apple-darwin/native/bin -isysroot/bitcoin/depends/SDKs/Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers -nostdlibinc -iwithsysroot/usr/include -iframeworkwithsysroot/System/Library/Frameworks
    checking whether the C compiler works... no
    configure: error: in `/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-68e7f8db9ca':
    configure: error: C compiler cannot create executables
    See `config.log' for more details
    make: *** [funcs.mk:291: /bitcoin/depends/x86_64-apple-darwin/.libevent_stamp_configured] Error 77
    make: Leaving directory '/bitcoin/depends'
    

    Seems to compile boost though.

  21. bitcoin locked this on Feb 8, 2026

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-25 21:13 UTC

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