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

issue JayBitron openend 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

     0root@localhost:~/.build/bitcoin-untouched# make HOST=x86_64-apple-darwin -C depends -j32
     1make: Entering directory '/root/.build/bitcoin-untouched/depends'
     2Fetching boost_1_81_0.tar.gz from https://archives.boost.io/release/1.81.0/source/
     3  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
     4                                 Dload  Upload   Total   Spent    Left  Speed
     5100  133M  100  133M    0     0  1221k      0  0:01:52  0:01:52 --:--:-- 1183k
     6/root/.build/bitcoin-untouched/depends/work/download/boost-1.81.0/boost_1_81_0.tar.gz.temp: OK
     7Extracting boost...
     8/root/.build/bitcoin-untouched/depends/sources/boost_1_81_0.tar.gz: OK
     9Preprocessing boost...
    10Configuring boost...
    11Building boost...
    12Staging boost...
    13Postprocessing boost...
    14Caching boost...
    15Fetching libevent-2.1.12-stable.tar.gz from https://github.com/libevent/libevent/releases/download/release-2.1.12-stable/
    16  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
    17                                 Dload  Upload   Total   Spent    Left  Speed
    18  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
    19100 1075k  100 1075k    0     0   389k      0  0:00:02  0:00:02 --:--:--  885k
    20/root/.build/bitcoin-untouched/depends/work/download/libevent-2.1.12-stable/libevent-2.1.12-stable.tar.gz.temp: OK
    21Extracting libevent...
    22/root/.build/bitcoin-untouched/depends/sources/libevent-2.1.12-stable.tar.gz: OK
    23Preprocessing libevent...
    24patching file CMakeLists.txt
    25patching file cmake/AddEventLibrary.cmake
    26patching file CMakeLists.txt
    27Configuring libevent...
    28-- The C compiler identification is Clang 14.0.6
    29-- Detecting C compiler ABI info
    30-- Detecting C compiler ABI info - failed
    31-- Check for working C compiler: /usr/bin/clang
    32-- Check for working C compiler: /usr/bin/clang - broken
    33CMake Error at /usr/share/cmake-3.25/Modules/CMakeTestCCompiler.cmake:70 (message):
    34  The C compiler
    35
    36    "/usr/bin/clang"
    37
    38  is not able to compile a simple test program.
    39
    40  It fails with the following output:
    41
    42    Change Dir: /root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeScratch/TryCompile-Y3lnvg
    43
    44    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'
    45    /usr/bin/gmake  -f CMakeFiles/cmTC_bccc1.dir/build.make CMakeFiles/cmTC_bccc1.dir/build
    46    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'
    47    Building C object CMakeFiles/cmTC_bccc1.dir/testCCompiler.c.o
    48    /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
    49    Linking C executable cmTC_bccc1
    50    /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_bccc1.dir/link.txt --verbose=1
    51    /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
    52    clang: warning: argument unused during compilation: '-nostdlibinc' [-Wunused-command-line-argument]
    53    /usr/bin/ld: unrecognised emulation mode: acosx_version_min
    54    Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 elf_iamcu i386pep i386pe
    55    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    56    gmake[2]: *** [CMakeFiles/cmTC_bccc1.dir/build.make:100: cmTC_bccc1] Error 1
    57    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'
    58    gmake[1]: *** [Makefile:127: cmTC_bccc1/fast] Error 2
    59    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'
    60
    61
    62
    63
    64
    65  CMake will not be able to correctly generate this project.
    66Call Stack (most recent call first):
    67  CMakeLists.txt:47 (project)
    68
    69
    70-- Configuring incomplete, errors occurred!
    71See also "/root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeOutput.log".
    72See also "/root/.build/bitcoin-untouched/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-66fa9a79555/build/CMakeFiles/CMakeError.log".
    73make: *** [funcs.mk:302: /root/.build/bitcoin-untouched/depends/x86_64-apple-darwin/.libevent_stamp_configured] Error 1
    74make: 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

     0root@localhost:~/.build/bitcoin-macos# make HOST=x86_64-apple-darwin -C depends -j32
     1make: Entering directory '/root/.build/bitcoin-macos/depends'
     2Configuring libevent...
     3-- The C compiler identification is Clang 20.0.0
     4-- Detecting C compiler ABI info
     5-- Detecting C compiler ABI info - failed
     6-- Check for working C compiler: /usr/bin/clang
     7-- Check for working C compiler: /usr/bin/clang - broken
     8CMake Error at /usr/share/cmake-3.30/Modules/CMakeTestCCompiler.cmake:67 (message):
     9  The C compiler
    10
    11    "/usr/bin/clang"
    12
    13  is not able to compile a simple test program.
    14
    15  It fails with the following output:
    16
    17    Change Dir: '/root/.build/bitcoin-macos/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-7c8a3b34ae1/build/CMakeFiles/CMakeScratch/TryCompile-ynpflf'
    18
    19    Run Build Command(s): /usr/bin/cmake -E env VERBOSE=1 /usr/bin/gmake -f Makefile cmTC_8a4e1/fast
    20    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'
    21    /usr/bin/gmake  -f CMakeFiles/cmTC_8a4e1.dir/build.make CMakeFiles/cmTC_8a4e1.dir/build
    22    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'
    23    Building C object CMakeFiles/cmTC_8a4e1.dir/testCCompiler.c.o
    24    /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
    25    Linking C executable cmTC_8a4e1
    26    /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_8a4e1.dir/link.txt --verbose=1
    27    /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
    28    /usr/bin/ld: unrecognised emulation mode: llvm
    29    Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 elf_iamcu i386pep i386pe
    30    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    31    gmake[2]: *** [CMakeFiles/cmTC_8a4e1.dir/build.make:100: cmTC_8a4e1] Error 1
    32    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'
    33    gmake[1]: *** [Makefile:127: cmTC_8a4e1/fast] Error 2
    34    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'
    35
    36
    37
    38
    39
    40  CMake will not be able to correctly generate this project.
    41Call Stack (most recent call first):
    42  CMakeLists.txt:47 (project)
    43
    44
    45-- Configuring incomplete, errors occurred!
    46make: *** [funcs.mk:302: /root/.build/bitcoin-macos/depends/x86_64-apple-darwin/.libevent_stamp_configured] Error 1
    47make: 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:

     0apt update
     1apt install git bison cmake curl make pkg-config xz-utils wget
     2# Install minimum required version of LLVM toolchain
     3apt install clang-16 llvm-16 lld-16
     4# Create non-versioned symlinks of the tools
     5ln -s /usr/bin/clang-16 /usr/bin/clang
     6ln -s /usr/bin/clang++-16 /usr/bin/clang++
     7ln -s /usr/bin/lld-16 /usr/bin/lld
     8ln -s /usr/bin/ld.lld-16 /usr/bin/ld.lld
     9ln -s /usr/bin/lld-link-16 /usr/bin/lld-link
    10ln -s /usr/bin/llvm-ar-16 /usr/bin/llvm-ar
    11ln -s /usr/bin/llvm-ranlib-16 /usr/bin/llvm-ranlib
    12# Prepare Bitcoin Core repository
    13git clone https://github.com/bitcoin/bitcoin.git
    14wget https://raw.githubusercontent.com/hebasto/artefacts/refs/heads/Xcode/Xcode/Xcode-15.0/Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers.tar.gz
    15mkdir -p bitcoin/depends/SDKs
    16tar xf Xcode-15.0-15A240d-extracted-SDK-with-libcxx-headers.tar.gz -C bitcoin/depends/SDKs
    17cd bitcoin
    18git checkout v28.0
    19# Cross-compile non-GUI dependencies
    20make -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:

     0root@localhost:~/.build/bitcoin# make -C depends HOST=x86_64-apple-darwin -j32
     1make: Entering directory '/root/.build/bitcoin/depends'
     2Fetching boost_1_81_0.tar.gz from https://archives.boost.io/release/1.81.0/source/
     3  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
     4                                 Dload  Upload   Total   Spent    Left  Speed
     5100  133M  100  133M    0     0  1252k      0  0:01:49  0:01:49 --:--:-- 1241k
     6/root/.build/bitcoin/depends/work/download/boost-1.81.0/boost_1_81_0.tar.gz.temp: OK
     7Extracting boost...
     8/root/.build/bitcoin/depends/sources/boost_1_81_0.tar.gz: OK
     9Preprocessing boost...
    10Configuring boost...
    11Building boost...
    12Staging boost...
    13Postprocessing boost...
    14Caching boost...
    15Fetching libevent-2.1.12-stable.tar.gz from https://github.com/libevent/libevent/releases/download/release-2.1.12-stable/
    16  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
    17                                 Dload  Upload   Total   Spent    Left  Speed
    18  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
    19100 1075k  100 1075k    0     0   275k      0  0:00:03  0:00:03 --:--:--  372k
    20/root/.build/bitcoin/depends/work/download/libevent-2.1.12-stable/libevent-2.1.12-stable.tar.gz.temp: OK
    21Extracting libevent...
    22/root/.build/bitcoin/depends/sources/libevent-2.1.12-stable.tar.gz: OK
    23Preprocessing libevent...
    24patching file CMakeLists.txt
    25patching file cmake/AddEventLibrary.cmake
    26patching file CMakeLists.txt
    27Configuring libevent...
    28-- The C compiler identification is Clang 16.0.6
    29-- Detecting C compiler ABI info
    30-- Detecting C compiler ABI info - failed
    31-- Check for working C compiler: /usr/bin/clang
    32-- Check for working C compiler: /usr/bin/clang - broken
    33CMake Error at /usr/share/cmake-3.25/Modules/CMakeTestCCompiler.cmake:70 (message):
    34  The C compiler
    35
    36    "/usr/bin/clang"
    37
    38  is not able to compile a simple test program.
    39
    40  It fails with the following output:
    41
    42    Change Dir: /root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeScratch/TryCompile-RUU5h5
    43
    44    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'
    45    /usr/bin/gmake  -f CMakeFiles/cmTC_920c1.dir/build.make CMakeFiles/cmTC_920c1.dir/build
    46    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'
    47    Building C object CMakeFiles/cmTC_920c1.dir/testCCompiler.c.o
    48    /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
    49    Linking C executable cmTC_920c1
    50    /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_920c1.dir/link.txt --verbose=1
    51    /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
    52    clang: warning: argument unused during compilation: '-nostdlibinc' [-Wunused-command-line-argument]
    53    /usr/bin/ld: unrecognised emulation mode: acosx_version_min
    54    Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 elf_iamcu i386pep i386pe
    55    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    56    gmake[2]: *** [CMakeFiles/cmTC_920c1.dir/build.make:100: cmTC_920c1] Error 1
    57    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'
    58    gmake[1]: *** [Makefile:127: cmTC_920c1/fast] Error 2
    59    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'
    60
    61
    62
    63
    64
    65  CMake will not be able to correctly generate this project.
    66Call Stack (most recent call first):
    67  CMakeLists.txt:47 (project)
    68
    69
    70-- Configuring incomplete, errors occurred!
    71See also "/root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeOutput.log".
    72See also "/root/.build/bitcoin/depends/work/build/x86_64-apple-darwin/libevent/2.1.12-stable-048265ffc6b/build/CMakeFiles/CMakeError.log".
    73make: *** [funcs.mk:302: /root/.build/bitcoin/depends/x86_64-apple-darwin/.libevent_stamp_configured] Error 1
    74make: 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:

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


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 09:12 UTC

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