qt: Windows build with DEBUG=1 is broken #29734

issue fanquake openend this issue on March 26, 2024
  1. fanquake commented at 2:16 pm on March 26, 2024: member

    If you try and cross-compile for Windows using master (d04324a7056a735c1127ba8ccdc720a16e7281a3) DEBUG=1, it fails. This is on a Ubuntu Noble machine, with x86_64-w64-mingw32-g++ (GCC) 13-win32. Noticed in #29527.

     0make -C depends HOST=x86_64-w64-mingw32 DEBUG=1 -j17
     1<snip>
     2Checking for STL compatibility... 
     3+ cd /root/ci_scratch/depends/work/build/x86_64-w64-mingw32/qt/5.15.11-8c515c34c2a/config.tests/stl && PKG_CONFIG_SYSROOT_DIR=/ PKG_CONFIG_LIBDIR=/root/ci_scratch/depends/x86_64-w64-mingw32/lib/pkgconfig /root/ci_scratch/depends/work/build/x86_64-w64-mingw32/qt/5.15.11-8c515c34c2a/qtbase/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += static warn_off console single_arch" 'QMAKE_CFLAGS = '\''-pipe -std=c11 -O1 -g  -D_GLIBCXX_DEBUG -D_GLIBCXX_DEBUG_PEDANTIC -I/root/ci_scratch/depends/x86_64-w64-mingw32/include'\''' 'QMAKE_CXX = '\''x86_64-w64-mingw32-g++-posix'\''' 'QMAKE_CXXFLAGS = '\''-pipe -std=c++20 -O1 -g  -D_GLIBCXX_DEBUG -D_GLIBCXX_DEBUG_PEDANTIC -I/root/ci_scratch/depends/x86_64-w64-mingw32/include'\''' 'QMAKE_LFLAGS = '\''  -L/root/ci_scratch/depends/x86_64-w64-mingw32/lib'\''' 'QMAKE_LIB = '\''x86_64-w64-mingw32-ar rc'\''' -early "CONFIG += cross_compile" /root/ci_scratch/depends/work/build/x86_64-w64-mingw32/qt/5.15.11-8c515c34c2a/qtbase/config.tests/stl
     4+ cd /root/ci_scratch/depends/work/build/x86_64-w64-mingw32/qt/5.15.11-8c515c34c2a/config.tests/stl && MAKEFLAGS= /usr/bin/gmake
     5> gmake[1]: Entering directory '/root/ci_scratch/depends/work/build/x86_64-w64-mingw32/qt/5.15.11-8c515c34c2a/config.tests/stl'
     6> x86_64-w64-mingw32-g++-posix -c -pipe -std=c++20 -O1 -g  -D_GLIBCXX_DEBUG -D_GLIBCXX_DEBUG_PEDANTIC -I/root/ci_scratch/depends/x86_64-w64-mingw32/include -O2 -w -fexceptions -mthreads -DUNICODE -D_UNICODE -DWIN32 -DMINGW_HAS_SECURE_API=1 -I/root/ci_scratch/depends/work/build/x86_64-w64-mingw32/qt/5.15.11-8c515c34c2a/qtbase/config.tests/stl -I. -I/root/ci_scratch/depends/work/build/x86_64-w64-mingw32/qt/5.15.11-8c515c34c2a/qtbase/mkspecs/win32-g++  -o stltest.o /root/ci_scratch/depends/work/build/x86_64-w64-mingw32/qt/5.15.11-8c515c34c2a/qtbase/config.tests/stl/stltest.cpp
     7> x86_64-w64-mingw32-g++ -L/root/ci_scratch/depends/x86_64-w64-mingw32/lib -Wl,-s -Wl,-subsystem,console -mthreads -o stl.exe stltest.o  
     8> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_lock':
     9> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:749:(.text+0x809): undefined reference to `pthread_mutex_lock'
    10> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_unlock':
    11> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:779:(.text+0x81d): undefined reference to `pthread_mutex_unlock'
    12> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_lock':
    13> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:749:(.text$_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_[_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_]+0x2ce): undefined reference to `pthread_mutex_lock'
    14> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_unlock':
    15> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:779:(.text$_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_[_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_]+0x2e7): undefined reference to `pthread_mutex_unlock'
    16> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_lock':
    17> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:749:(.text$_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_[_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_]+0x3c0): undefined reference to `pthread_mutex_lock'
    18> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_unlock':
    19> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:779:(.text$_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_[_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_]+0x3d9): undefined reference to `pthread_mutex_unlock'
    20> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_lock':
    21> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:749:(.text$_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_[_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_]+0x4b6): undefined reference to `pthread_mutex_lock'
    22> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_unlock':
    23> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:779:(.text$_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_[_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_]+0x4cf): undefined reference to `pthread_mutex_unlock'
    24> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_lock':
    25> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:749:(.text$_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_[_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_]+0x5ac): undefined reference to `pthread_mutex_lock'
    26> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_unlock':
    27> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:779:(.text$_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_[_ZSt4findIN11__gnu_debug14_Safe_iteratorIN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS7_EESt26random_access_iterator_tagEEiET_SF_SF_RKT0_]+0x5c5): undefined reference to `pthread_mutex_unlock'
    28> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_lock':
    29> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:749:(.text$_ZSt13__copy_move_aILb0EN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS5_EESt26random_access_iterator_tagSt20back_insert_iteratorISA_EET3_RKN11__gnu_debug14_Safe_iteratorIT0_T1_T2_EESM_SE_[_ZSt13__copy_move_aILb0EN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS5_EESt26random_access_iterator_tagSt20back_insert_iteratorISA_EET3_RKN11__gnu_debug14_Safe_iteratorIT0_T1_T2_EESM_SE_]+0x352): undefined reference to `pthread_mutex_lock'
    30> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_unlock':
    31> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:779:(.text$_ZSt13__copy_move_aILb0EN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS5_EESt26random_access_iterator_tagSt20back_insert_iteratorISA_EET3_RKN11__gnu_debug14_Safe_iteratorIT0_T1_T2_EESM_SE_[_ZSt13__copy_move_aILb0EN9__gnu_cxx17__normal_iteratorIPiNSt9__cxx19986vectorIiSaIiEEEEENSt7__debug6vectorIiS5_EESt26random_access_iterator_tagSt20back_insert_iteratorISA_EET3_RKN11__gnu_debug14_Safe_iteratorIT0_T1_T2_EESM_SE_]+0x36b): undefined reference to `pthread_mutex_unlock'
    32> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_lock':
    33> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:749:(.text.startup+0x60b): undefined reference to `pthread_mutex_lock'
    34> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_unlock':
    35> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:779:(.text.startup+0x62a): undefined reference to `pthread_mutex_unlock'
    36> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_lock':
    37> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:749:(.text.startup+0x84b): undefined reference to `pthread_mutex_lock'
    38> /usr/bin/x86_64-w64-mingw32-ld: stltest.o: in function `__gthread_mutex_unlock':
    39> /usr/lib/gcc/x86_64-w64-mingw32/13-posix/include/c++/x86_64-w64-mingw32/bits/gthr-default.h:779:(.text.startup+0x879): undefined reference to `pthread_mutex_unlock'
    40> collect2: error: ld returned 1 exit status
    41> gmake[1]: *** [Makefile:69: stl.exe] Error 1
    42> gmake[1]: Leaving directory '/root/ci_scratch/depends/work/build/x86_64-w64-mingw32/qt/5.15.11-8c515c34c2a/config.tests/stl'
    43test config.qtbase.tests.stl FAILED
    44<snip>
    45Note: Using static linking will disable the use of dynamically
    46loaded plugins. Make sure to import all needed static plugins,
    47or compile needed modules into the library.
    48
    49ERROR: Qt requires a compliant STL library.
    50make: *** [funcs.mk:298: /root/ci_scratch/depends/x86_64-w64-mingw32/.qt_stamp_configured] Error 3
    51make: Leaving directory '/root/ci_scratch/depends'
    
  2. fanquake referenced this in commit b7e7e727ab on Mar 27, 2024
  3. hebasto commented at 2:02 pm on March 27, 2024: member

    If you try and cross-compile for Windows using master (d04324a) DEBUG=1, it fails. This is on a Ubuntu Noble machine, with x86_64-w64-mingw32-g++ (GCC) 13-win32.

    This error also might be triggered on Ubuntu 22,04 by installing the g++-mingw-w64-x86-64 package.

  4. fanquake closed this on Mar 27, 2024

  5. fanquake referenced this in commit 7a12cbed99 on Mar 27, 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-09-29 01:12 UTC

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