Skip to content

Conversation

dongcarl
Copy link
Contributor

@dongcarl dongcarl commented Apr 29, 2020

From: #18308 (comment)

The following monstrosity is quite useful when invoked inside depends, and reviewers can use it to compare the behaviour of this change against master.

make print-{{,{host,{,{i686,x86_64,riscv64}_}linux}_}{CC,CXX},boost_{cc,cxx}}

It would also be helpful to make sure that setting HOST, CC, and CXX does the right thing. The 3 hosts I found offered good coverage were: {x86_64,i686,riscv64}-linux-gnu. As we special-case the x86_64 and i686 hosts in depends/hosts/linux.mk, and riscv64 is a sanity check for a non-special-cased host.

@adamjonas
Copy link
Member

Ref #15914.

@DrahtBot
Copy link
Contributor

DrahtBot commented Apr 30, 2020

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

Conflicts

No conflicts as of last run.

@practicalswift
Copy link
Contributor

Concept ACK

Having this merged would allow enabling MemorySanitizer (MSan) more easily (#18288).

@practicalswift
Copy link
Contributor

@dongcarl It seems like the Travis macOS 10.12 job failed :)

@fanquake
Copy link
Member

fanquake commented May 6, 2020

Concept ACK

fanquake added a commit to fanquake/bitcoin that referenced this pull request May 7, 2020
As of Boost 1.72.0, the darwin toolset has been removed from Boost
Build, in favour of the Clang toolset; see this commit:
boostorg/build@eb8da52.

The reasoning (not given in the commit) being that darwin was basically
a copy of the clang toolset anyways. Some comments from the commit
author here: boostorg/build#528.

This change may also resolve the macOS issues seen in bitcoin#18820.
@hebasto
Copy link
Member

hebasto commented May 21, 2020

Tested a0e7fe7 on Linux Mint 19.3:

$ make -C depends/ CC=clang CXX=clang++
...
libtool:   error: '/home/hebasto/GitHub/bitcoin/depends/work/build/x86_64-pc-linux-gnu/freetype/2.7.1-6ee38f80395/objs/ftsystem.lo' is not a valid libtool object
config.mk:55: recipe for target '/home/hebasto/GitHub/bitcoin/depends/work/build/x86_64-pc-linux-gnu/freetype/2.7.1-6ee38f80395/objs/libfreetype.la' failed
make[1]: *** [/home/hebasto/GitHub/bitcoin/depends/work/build/x86_64-pc-linux-gnu/freetype/2.7.1-6ee38f80395/objs/libfreetype.la] Error 1
make[1]: Leaving directory '/home/hebasto/GitHub/bitcoin/depends/work/build/x86_64-pc-linux-gnu/freetype/2.7.1-6ee38f80395'
funcs.mk:260: recipe for target '/home/hebasto/GitHub/bitcoin/depends/work/build/x86_64-pc-linux-gnu/freetype/2.7.1-6ee38f80395/./.stamp_built' failed
make: *** [/home/hebasto/GitHub/bitcoin/depends/work/build/x86_64-pc-linux-gnu/freetype/2.7.1-6ee38f80395/./.stamp_built] Error 2
make: Leaving directory '/home/hebasto/GitHub/bitcoin/depends'

@maflcko
Copy link
Member

maflcko commented May 21, 2020

Concept ACK (assuming it solves my problems)

@hebasto
Copy link
Member

hebasto commented May 21, 2020

Concept ACK.

@dongcarl
Copy link
Contributor Author

Seems like the issue is that we need to separate the toolset and the target-os for b2, will investigate further tomorrow.

@dongcarl dongcarl force-pushed the 2020-04-improve-depends-hosts2 branch from a0e7fe7 to 645e080 Compare May 22, 2020 21:47
@dongcarl dongcarl marked this pull request as ready for review May 22, 2020 21:48
@dongcarl
Copy link
Contributor Author

Done, should work now. Glad to know that our build system is not the only one with weird idiosyncrasies 😬

@practicalswift
Copy link
Contributor

ACK 645e080 -- patch looks correct and Travis is happy :)

Copy link
Member

@hebasto hebasto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested 645e080 on Linux Mint 19.3 (x86_64):

$ make -C depends CC=clang CXX=clang++
$ CONFIG_SITE=$PWD/depends/x86_64-pc-linux-gnu/share/config.site ./configure
...
  CC            = /usr/bin/ccache clang
...
  CXX           = /usr/bin/ccache clang++ -std=c++11
...
$ make clean && make
...
/usr/bin/ld: /home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/share/../lib/libdb_cxx-4.8.a(cxx_db.o): relocation R_X86_64_32S against symbol `_ZTV2Db' can not be used when making a PIE object; recompile with -fPIC
/usr/bin/ld: /home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/share/../lib/libdb_cxx-4.8.a(cxx_env.o): relocation R_X86_64_32S against `.data' can not be used when making a PIE object; recompile with -fPIC
/usr/bin/ld: /home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/share/../lib/libdb_cxx-4.8.a(cxx_except.o): relocation R_X86_64_32S against symbol `_ZTV11DbException' can not be used when making a PIE object; recompile with -fPIC
# loads of "recompile with -fPIC" link errors

@hebasto
Copy link
Member

hebasto commented May 23, 2020

Maybe instead of backporting patch just bump FreeType version to the latest 2.10.2 where that patch is included?

@dongcarl
Copy link
Contributor Author

Tested 645e080 on Linux Mint 19.3 (x86_64):

$ make -C depends CC=clang CXX=clang++
$ CONFIG_SITE=$PWD/depends/x86_64-pc-linux-gnu/share/config.site ./configure
...
  CC            = /usr/bin/ccache clang
...
  CXX           = /usr/bin/ccache clang++ -std=c++11
...
$ make clean && make
...
/usr/bin/ld: /home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/share/../lib/libdb_cxx-4.8.a(cxx_db.o): relocation R_X86_64_32S against symbol `_ZTV2Db' can not be used when making a PIE object; recompile with -fPIC
/usr/bin/ld: /home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/share/../lib/libdb_cxx-4.8.a(cxx_env.o): relocation R_X86_64_32S against `.data' can not be used when making a PIE object; recompile with -fPIC
/usr/bin/ld: /home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/share/../lib/libdb_cxx-4.8.a(cxx_except.o): relocation R_X86_64_32S against symbol `_ZTV11DbException' can not be used when making a PIE object; recompile with -fPIC
# loads of "recompile with -fPIC" link errors

Can you check your logs to see the configuration logs of libdb? Can't reproduce here.

@hebasto
Copy link
Member

hebasto commented May 23, 2020

@dongcarl

$ make -C depends bdb CC=clang CXX=clang++
output
make: Entering directory '/home/hebasto/GitHub/bitcoin/depends'
Fetching db-4.8.30.NC.tar.gz from https://download.oracle.com/berkeley-db
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 21.7M  100 21.7M    0     0  7515k      0  0:00:02  0:00:02 --:--:-- 7515k
/home/hebasto/GitHub/bitcoin/depends/work/download/bdb-4.8.30/db-4.8.30.NC.tar.gz.temp: OK
Extracting bdb...
/home/hebasto/GitHub/bitcoin/depends/sources/db-4.8.30.NC.tar.gz: OK
Preprocessing bdb...
Configuring bdb...
configure: WARNING: If you wanted to set the --build type, don't use --host.
    If a cross compiler is detected then cross compile mode will be used.
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking if building in the top-level or dist directories... no
checking if --disable-cryptography option specified... no
checking if --disable-hash option specified... no
checking if --disable-partition option specified... no
checking if --disable-compression option specified... no
checking if --disable-mutexsupport option specified... no
checking if --disable-atomicsupport option specified... no
checking if --disable-queue option specified... no
checking if --disable-replication option specified... yes
checking if --disable-statistics option specified... no
checking if --disable-verify option specified... no
checking if --enable-compat185 option specified... no
checking if --enable-cxx option specified... yes
checking if --enable-debug option specified... no
checking if --enable-debug_rop option specified... no
checking if --enable-debug_wop option specified... no
checking if --enable-diagnostic option specified... no
checking if --enable-dump185 option specified... no
checking if --enable-java option specified... no
checking if --enable-mingw option specified... no
checking if --enable-o_direct option specified... no
checking if --enable-posixmutexes option specified... no
checking if --enable-rpc option specified... no
checking if --enable-smallbuild option specified... no
checking if --enable-stl option specified... no
checking if --enable-tcl option specified... no
checking if --enable-test option specified... no
checking if --enable-uimutexes option specified... no
checking if --enable-umrw option specified... no
checking if --with-mutex=MUTEX option specified... no
checking if --with-tcl=DIR option specified... no
checking if --with-uniquename=NAME option specified... no
checking for x86_64-pc-linux-gnu-chmod... no
checking for chmod... chmod
checking for x86_64-pc-linux-gnu-cp... no
checking for cp... cp
checking for x86_64-pc-linux-gnu-ln... no
checking for ln... ln
checking for x86_64-pc-linux-gnu-mkdir... no
checking for mkdir... mkdir
checking for x86_64-pc-linux-gnu-rm... no
checking for rm... rm
checking for x86_64-pc-linux-gnu-sh... no
checking for sh... /bin/sh
checking for a BSD-compatible install... /usr/bin/install -c
checking for x86_64-pc-linux-gnu-cc... clang
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether clang accepts -g... yes
checking for clang option to accept ISO C89... none needed
checking for an ANSI C-conforming const... yes
checking for inline... inline
checking whether we are using the GNU C++ compiler... yes
checking whether clang++ accepts -g... yes
checking how to run the C++ preprocessor... clang++ -E
checking whether C++ supports the ISO C++ standard includes... yes
checking whether we are using gcc version 2.96... no
checking for a sed that does not truncate output... /bin/sed
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for fgrep... /bin/grep -F
checking for ld used by clang... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... nm
checking the name lister (nm) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking for /usr/bin/ld option to reload object files... -r
checking for x86_64-pc-linux-gnu-objdump... no
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for x86_64-pc-linux-gnu-ar... ar
checking for x86_64-pc-linux-gnu-strip... no
checking for strip... strip
checking for x86_64-pc-linux-gnu-ranlib... ranlib
checking command to parse nm output from clang object... ok
checking how to run the C preprocessor... clang -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking whether we are using the GNU C++ compiler... (cached) yes
checking whether clang++ accepts -g... (cached) yes
checking how to run the C++ preprocessor... clang++ -E
checking for objdir... .libs
checking if clang supports -fno-rtti -fno-exceptions... yes
checking for clang option to produce PIC... -fPIC -DPIC
checking if clang PIC flag -fPIC -DPIC works... yes
checking if clang static flag -static works... yes
checking if clang supports -c -o file.o... yes
checking if clang supports -c -o file.o... (cached) yes
checking whether the clang linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking for ld used by clang++... /usr/bin/ld -m elf_x86_64
checking if the linker (/usr/bin/ld -m elf_x86_64) is GNU ld... yes
checking whether the clang++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking for clang++ option to produce PIC... -fPIC -DPIC
checking if clang++ PIC flag -fPIC -DPIC works... yes
checking if clang++ static flag -static works... yes
checking if clang++ supports -c -o file.o... yes
checking if clang++ supports -c -o file.o... (cached) yes
checking whether the clang++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking SOSUFFIX from libtool... .so
checking MODSUFFIX from libtool... .so
checking JMODSUFFIX from libtool... .so
checking whether stat file-mode macros are broken... no
checking whether time.h and sys/time.h may both be included... yes
checking for dirent.h that defines DIR... yes
checking for library containing opendir... none required
checking execinfo.h usability... yes
checking execinfo.h presence... yes
checking for execinfo.h... yes
checking sys/select.h usability... yes
checking sys/select.h presence... yes
checking for sys/select.h... yes
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking for struct stat.st_blksize... yes
checking for inttypes.h... (cached) yes
checking for stdint.h... yes
checking if stdint.h can be used by C++... yes
checking stddef.h usability... yes
checking stddef.h presence... yes
checking for stddef.h... yes
checking for unistd.h... (cached) yes
checking size of char... 1
checking size of unsigned char... 1
checking size of short... 2
checking size of unsigned short... 2
checking size of int... 4
checking size of unsigned int... 4
checking size of long... 8
checking size of unsigned long... 8
checking size of long long... 8
checking size of unsigned long long... 8
checking size of char *... 8
checking for u_char... yes
checking for u_short... yes
checking for u_int... yes
checking for u_long... yes
checking for u_int8_t... yes
checking for u_int16_t... yes
checking for int16_t... yes
checking for u_int32_t... yes
checking for int32_t... yes
checking for u_int64_t... yes
checking for int64_t... yes
checking for FILE *... yes
checking for off_t... yes
checking for pid_t... yes
checking for size_t... yes
checking for time_t... yes
checking size of size_t... 8
checking for ssize_t... yes
checking for uintmax_t... yes
checking for uintptr_t... yes
checking for socklen_t... yes
checking for ANSI C exit success/failure values... yes
checking for getopt optreset variable... no
checking for mutexes... POSIX/pthreads/library/x86_64/gcc-assembly
checking pthread.h usability... yes
checking pthread.h presence... yes
checking for pthread.h... yes
checking for main in -lpthread... yes
checking for atomic operations... x86/gcc-assembly
checking for library containing sched_yield... none required
checking for library containing fdatasync... none required
checking for library containing getaddrinfo... none required
checking for library containing hstrerror... none required
checking for main in -lm... yes
checking for main in -lnsl... yes
checking for main in -lsocket... no
checking for abort... yes
checking for atoi... yes
checking for atol... yes
checking for getcwd... yes
checking for getenv... yes
checking for getopt... yes
checking for isalpha... yes
checking for isdigit... yes
checking for isprint... yes
checking for isspace... yes
checking for memcmp... yes
checking for memcpy... yes
checking for memmove... yes
checking for printf... yes
checking for qsort... yes
checking for raise... yes
checking for rand... yes
checking for strcasecmp... yes
checking for strcat... yes
checking for strchr... yes
checking for strdup... yes
checking for strerror... yes
checking for strncat... yes
checking for strncmp... yes
checking for strrchr... yes
checking for strsep... yes
checking for strtol... yes
checking for strtoul... yes
checking for _fstati64... no
checking for backtrace... yes
checking for backtrace_symbols... yes
checking for directio... no
checking for fchmod... yes
checking for fclose... yes
checking for fcntl... yes
checking for fdatasync... yes
checking for fgetc... yes
checking for fgets... yes
checking for fopen... yes
checking for fwrite... yes
checking for getgid... yes
checking for getrusage... yes
checking for getuid... yes
checking for hstrerror... yes
checking for mprotect... yes
checking for pstat_getdynamic... no
checking for pthread_self... yes
checking for pthread_yield... yes
checking for random... yes
checking for sched_yield... yes
checking for select... yes
checking for setgid... yes
checking for setuid... yes
checking for sigaction... yes
checking for snprintf... yes
checking for stat... yes
checking for sysconf... yes
checking for vsnprintf... yes
checking for yield... no
checking for gettimeofday... yes
checking for localtime... yes
checking for time... yes
checking for strftime... yes
checking for clock_gettime... yes
checking for clock_gettime monotonic clock... no
checking for ctime_r... yes
checking for 2 or 3 argument version of ctime_r... 2-argument
checking for ftruncate... yes
checking for pread... yes
checking for pwrite... yes
checking for getaddrinfo... yes
checking for fcntl/F_SETFD... yes
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... no
checking for mlock... yes
checking for munlock... yes
checking for mmap... yes
checking for munmap... yes
checking for shmget... yes
checking for shmctl... yes
checking for 64-bit integral type support for sequences... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating db_cxx.h
config.status: creating db_int.h
config.status: creating clib_port.h
config.status: creating include.tcl
config.status: creating db.h
config.status: creating db_config.h
config.status: executing libtool commands
Building bdb...
make[1]: Entering directory '/home/hebasto/GitHub/bitcoin/depends/work/build/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/build_unix'
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_db.cpp
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_dbc.cpp
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_dbt.cpp
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_env.cpp
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_except.cpp
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_lock.cpp
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_logc.cpp
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_mpool.cpp
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_multi.cpp
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_seq.cpp
clang++ -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -std=c++11     ../dist/./../cxx/cxx_txn.cpp
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mutex/mut_tas.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mutex/mut_pthread.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_compare.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_compress.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_conv.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_curadj.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_cursor.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_delete.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_open.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_put.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_rec.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_reclaim.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_recno.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_rsearch.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_search.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_split.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_compact.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_upgrade.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/btree_auto.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_auto.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_conv.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_dup.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_meta.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_open.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_page.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_rec.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_reclaim.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_upgrade.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_verify.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../qam/qam.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../qam/qam_auto.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../qam/qam_conv.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../qam/qam_files.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../qam/qam_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../qam/qam_open.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../qam/qam_rec.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../qam/qam_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../qam/qam_upgrade.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../qam/qam_verify.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../rep/rep_stub.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../repmgr/repmgr_stub.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_ovfl_vrfy.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_vrfy.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_vrfyutil.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../btree/bt_verify.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../lock/lock.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../lock/lock_deadlock.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../lock/lock_failchk.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../lock/lock_id.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../lock/lock_list.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../lock/lock_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../lock/lock_region.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../lock/lock_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../lock/lock_timer.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../lock/lock_util.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mutex/mut_alloc.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mutex/mut_failchk.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mutex/mut_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mutex/mut_region.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mutex/mut_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/crypto_stub.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/crdel_auto.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/crdel_rec.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_am.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_auto.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/db_byteorder.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_cam.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_cds.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/db_compint.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_conv.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_dispatch.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_dup.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/db_err.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/db_getlong.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/db_idspace.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_iface.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_join.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/db_log2.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_meta.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_open.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_overflow.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_pr.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_rec.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_reclaim.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_remove.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_rename.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_ret.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_setid.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_setlsn.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/db_shash.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_sort_multiple.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_stati.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_truncate.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_upg.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/db_upg_opd.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../dbm/dbm.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../dbreg/dbreg.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../dbreg/dbreg_auto.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../dbreg/dbreg_rec.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../dbreg/dbreg_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../dbreg/dbreg_util.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/dbt.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_alloc.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_config.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_failchk.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_file.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_globals.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_name.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_open.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_recover.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_region.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_register.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_sig.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../env/env_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../fileops/fileops_auto.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../fileops/fop_basic.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../fileops/fop_rec.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../fileops/fop_util.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hash/hash_func.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hmac/hmac.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hsearch/hsearch.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../log/log.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../log/log_archive.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../log/log_compare.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../log/log_debug.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../log/log_get.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../log/log_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../log/log_put.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../log/log_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/mkpath.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_alloc.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_bh.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_fget.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_fmethod.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_fopen.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_fput.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_fset.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_mvcc.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_region.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_register.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_resize.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_sync.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../mp/mp_trickle.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/openflags.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_abort.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_abs.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_alloc.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_clock.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_cpu.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_ctime.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_config.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_dir.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_errno.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_fid.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_flock.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_fsync.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_getenv.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_handle.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_map.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/os_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_mkdir.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_open.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_pid.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_rename.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_root.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_rpath.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_rw.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_seek.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_stack.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_tmpdir.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_truncate.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_uid.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_unlink.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../os/os_yield.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../db/partition.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../sequence/seq_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../sequence/sequence.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../hmac/sha1.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../clib/snprintf.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../txn/txn.c
../dist/./../txn/txn.c:171:18: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
                __db_errx(env, TxnAlloc);
                               ^~~~~~~~
../dist/./../txn/txn.c:171:18: note: treat the string as an argument to avoid this
                __db_errx(env, TxnAlloc);
                               ^
                               "%s", 
../dist/./../txn/txn.c:318:18: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
                __db_errx(env, TxnAlloc);
                               ^~~~~~~~
../dist/./../txn/txn.c:318:18: note: treat the string as an argument to avoid this
                __db_errx(env, TxnAlloc);
                               ^
                               "%s", 
2 warnings generated.
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../txn/txn_auto.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../txn/txn_chkpt.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../txn/txn_failchk.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../txn/txn_method.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../txn/txn_rec.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../txn/txn_recover.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../txn/txn_region.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../txn/txn_stat.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../txn/txn_util.c
clang -c -I. -I../dist/./.. -I/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include     -D_GNU_SOURCE -D_REENTRANT -pipe -O2      ../dist/./../common/zerofill.c
ar cr libdb_cxx-4.8.a cxx_db.o cxx_dbc.o cxx_dbt.o cxx_env.o cxx_except.o cxx_lock.o cxx_logc.o cxx_mpool.o cxx_multi.o cxx_seq.o cxx_txn.o mut_tas.o mut_pthread.o  bt_compare.o bt_compress.o bt_conv.o bt_curadj.o bt_cursor.o bt_delete.o bt_method.o bt_open.o bt_put.o bt_rec.o bt_reclaim.o bt_recno.o bt_rsearch.o bt_search.o bt_split.o bt_stat.o bt_compact.o bt_upgrade.o btree_auto.o hash.o hash_auto.o hash_conv.o hash_dup.o hash_meta.o hash_method.o hash_open.o hash_page.o hash_rec.o hash_reclaim.o hash_stat.o hash_upgrade.o hash_verify.o qam.o qam_auto.o qam_conv.o qam_files.o qam_method.o qam_open.o qam_rec.o qam_stat.o qam_upgrade.o qam_verify.o rep_stub.o repmgr_stub.o db_ovfl_vrfy.o db_vrfy.o db_vrfyutil.o bt_verify.o lock.o lock_deadlock.o lock_failchk.o lock_id.o lock_list.o lock_method.o lock_region.o lock_stat.o lock_timer.o lock_util.o mut_alloc.o mut_failchk.o mut_method.o mut_region.o mut_stat.o  crypto_stub.o crdel_auto.o crdel_rec.o db.o db_am.o db_auto.o db_byteorder.o db_cam.o db_cds.o db_compint.o db_conv.o db_dispatch.o db_dup.o db_err.o db_getlong.o db_idspace.o db_iface.o db_join.o db_log2.o db_meta.o db_method.o db_open.o db_overflow.o db_pr.o db_rec.o db_reclaim.o db_remove.o db_rename.o db_ret.o db_setid.o db_setlsn.o db_shash.o db_sort_multiple.o db_stati.o db_truncate.o db_upg.o db_upg_opd.o dbm.o dbreg.o dbreg_auto.o dbreg_rec.o dbreg_stat.o dbreg_util.o dbt.o env_alloc.o env_config.o env_failchk.o env_file.o env_globals.o env_method.o env_name.o env_open.o env_recover.o env_region.o env_register.o env_sig.o env_stat.o fileops_auto.o fop_basic.o fop_rec.o fop_util.o hash_func.o hmac.o hsearch.o log.o log_archive.o log_compare.o log_debug.o log_get.o log_method.o log_put.o log_stat.o mkpath.o mp_alloc.o mp_bh.o mp_fget.o mp_fmethod.o mp_fopen.o mp_fput.o mp_fset.o mp_method.o mp_mvcc.o mp_region.o mp_register.o mp_resize.o mp_stat.o mp_sync.o mp_trickle.o openflags.o os_abort.o os_abs.o os_alloc.o os_clock.o os_cpu.o os_ctime.o os_config.o os_dir.o os_errno.o os_fid.o os_flock.o os_fsync.o os_getenv.o os_handle.o os_map.o os_method.o os_mkdir.o os_open.o os_pid.o os_rename.o os_root.o os_rpath.o os_rw.o os_seek.o os_stack.o os_stat.o os_tmpdir.o os_truncate.o os_uid.o os_unlink.o os_yield.o partition.o seq_stat.o sequence.o sha1.o snprintf.o txn.o txn_auto.o txn_chkpt.o txn_failchk.o txn_method.o txn_rec.o txn_recover.o txn_region.o txn_stat.o txn_util.o zerofill.o
ranlib libdb_cxx-4.8.a
rm -f libdb_cxx.a
ln -s libdb_cxx-4.8.a libdb_cxx.a
ar cr libdb-4.8.a mut_tas.o mut_pthread.o  bt_compare.o bt_compress.o bt_conv.o bt_curadj.o bt_cursor.o bt_delete.o bt_method.o bt_open.o bt_put.o bt_rec.o bt_reclaim.o bt_recno.o bt_rsearch.o bt_search.o bt_split.o bt_stat.o bt_compact.o bt_upgrade.o btree_auto.o hash.o hash_auto.o hash_conv.o hash_dup.o hash_meta.o hash_method.o hash_open.o hash_page.o hash_rec.o hash_reclaim.o hash_stat.o hash_upgrade.o hash_verify.o qam.o qam_auto.o qam_conv.o qam_files.o qam_method.o qam_open.o qam_rec.o qam_stat.o qam_upgrade.o qam_verify.o rep_stub.o repmgr_stub.o db_ovfl_vrfy.o db_vrfy.o db_vrfyutil.o bt_verify.o lock.o lock_deadlock.o lock_failchk.o lock_id.o lock_list.o lock_method.o lock_region.o lock_stat.o lock_timer.o lock_util.o mut_alloc.o mut_failchk.o mut_method.o mut_region.o mut_stat.o  crypto_stub.o crdel_auto.o crdel_rec.o db.o db_am.o db_auto.o db_byteorder.o db_cam.o db_cds.o db_compint.o db_conv.o db_dispatch.o db_dup.o db_err.o db_getlong.o db_idspace.o db_iface.o db_join.o db_log2.o db_meta.o db_method.o db_open.o db_overflow.o db_pr.o db_rec.o db_reclaim.o db_remove.o db_rename.o db_ret.o db_setid.o db_setlsn.o db_shash.o db_sort_multiple.o db_stati.o db_truncate.o db_upg.o db_upg_opd.o dbm.o dbreg.o dbreg_auto.o dbreg_rec.o dbreg_stat.o dbreg_util.o dbt.o env_alloc.o env_config.o env_failchk.o env_file.o env_globals.o env_method.o env_name.o env_open.o env_recover.o env_region.o env_register.o env_sig.o env_stat.o fileops_auto.o fop_basic.o fop_rec.o fop_util.o hash_func.o hmac.o hsearch.o log.o log_archive.o log_compare.o log_debug.o log_get.o log_method.o log_put.o log_stat.o mkpath.o mp_alloc.o mp_bh.o mp_fget.o mp_fmethod.o mp_fopen.o mp_fput.o mp_fset.o mp_method.o mp_mvcc.o mp_region.o mp_register.o mp_resize.o mp_stat.o mp_sync.o mp_trickle.o openflags.o os_abort.o os_abs.o os_alloc.o os_clock.o os_cpu.o os_ctime.o os_config.o os_dir.o os_errno.o os_fid.o os_flock.o os_fsync.o os_getenv.o os_handle.o os_map.o os_method.o os_mkdir.o os_open.o os_pid.o os_rename.o os_root.o os_rpath.o os_rw.o os_seek.o os_stack.o os_stat.o os_tmpdir.o os_truncate.o os_uid.o os_unlink.o os_yield.o partition.o seq_stat.o sequence.o sha1.o snprintf.o txn.o txn_auto.o txn_chkpt.o txn_failchk.o txn_method.o txn_rec.o txn_recover.o txn_region.o txn_stat.o txn_util.o zerofill.o
ranlib libdb-4.8.a
rm -f libdb.a
ln -s libdb-4.8.a libdb.a
make[1]: Leaving directory '/home/hebasto/GitHub/bitcoin/depends/work/build/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/build_unix'
Staging bdb...
make[1]: Entering directory '/home/hebasto/GitHub/bitcoin/depends/work/build/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/build_unix'
Installing DB library: /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib ...
libtool: install: cp -p libdb-4.8.a /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb-4.8.a
libtool: install: chmod 644 /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb-4.8.a
libtool: install: ranlib /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb-4.8.a
libtool: install: cp -p libdb.a /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb.a
libtool: install: chmod 644 /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb.a
libtool: install: ranlib /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb.a
libtool: install: cp -p libdb_cxx-4.8.a /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb_cxx-4.8.a
libtool: install: chmod 644 /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb_cxx-4.8.a
libtool: install: ranlib /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb_cxx-4.8.a
libtool: install: cp -p libdb_cxx.a /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb_cxx.a
libtool: install: chmod 644 /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb_cxx.a
libtool: install: ranlib /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/lib/libdb_cxx.a
Installing DB include files: /home/hebasto/GitHub/bitcoin/depends/work/staging/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/home/hebasto/GitHub/bitcoin/depends/x86_64-pc-linux-gnu/include ...
make[1]: Leaving directory '/home/hebasto/GitHub/bitcoin/depends/work/build/x86_64-pc-linux-gnu/bdb/4.8.30-5333bbfcc74/build_unix'
Postprocessing bdb...
Caching bdb...
make: Leaving directory '/home/hebasto/GitHub/bitcoin/depends'

@hebasto
Copy link
Member

hebasto commented May 23, 2020

@dongcarl
Another approach (EDITED):

$ make -C depends CC='clang -fPIC' CXX='clang++ -fPIC'
$ CONFIG_SITE=$PWD/depends/x86_64-pc-linux-gnu/share/config.site ./configure
$ make check
# ok :)

@hebasto
Copy link
Member

hebasto commented May 23, 2020

REMOVED

@DrahtBot
Copy link
Contributor

Gitian builds

File commit fa3288c
(master)
commit 798774a
(master and this pull)
bitcoin-core-linux-0.21-res.yml 904ff6de15a70fa1... df0ac98b9c89fedf...
bitcoin-core-osx-0.21-res.yml 28bcad94c69be44d... 6e4aa7603b345a60...
bitcoin-core-win-0.21-res.yml aca1079fadc10ef9... fc2f8c77fa1641f5...
*-aarch64-linux-gnu-debug.tar.gz 4a7076bfebd28fbc... 74675583bf3ab2c6...
*-aarch64-linux-gnu.tar.gz 0b7cc0188560a260... 744ef8dcf3270691...
*-arm-linux-gnueabihf-debug.tar.gz 14bcd730b41009cd... d12bcde085b71329...
*-arm-linux-gnueabihf.tar.gz 08262926e2d1fe57... 7ad974515de113f6...
*-osx-unsigned.dmg 5e4228bb455ef5fd... e78888f24ec4d9f2...
*-osx64.tar.gz 6e6a376ac433f607... 3cf2a2c764553dc0...
*-riscv64-linux-gnu-debug.tar.gz 3552abe60138873e... bfa76de804997e83...
*-riscv64-linux-gnu.tar.gz 4d5b5029e7ac049d... 002fc37b01b2b2c5...
*-win64-debug.zip cf90dd99f8ed4ac8... 6c0b32115edb506d...
*-win64-setup-unsigned.exe 9dcc0a0078a44bf8... 98c3f0434e2e12f6...
*-win64.zip b1e41d29571d318e... db67a13ff73b50d2...
*-x86_64-linux-gnu-debug.tar.gz 5783f4d5854d4a36... 1deaee5574f49f6b...
*-x86_64-linux-gnu.tar.gz a0c5a9a872a9f0e6... 09cf0b30ad792a2b...
*.tar.gz 2ce5333a4100c9dc... e222219867136cfb...
linux-build.log 32813738fb84936d... 9215f24e0daa26d2...
osx-build.log 44322b87853696d8... 93e474b2210ba1c6...
win-build.log 5bb46200e5f3b841... b034a9a679555d75...
bitcoin-core-linux-0.21-res.yml.diff 8f85b847e0b2c107...
bitcoin-core-osx-0.21-res.yml.diff 0694fc8443140174...
bitcoin-core-win-0.21-res.yml.diff 9a379c9693df5843...
linux-build.log.diff b2ceaa10cd55cacf...
osx-build.log.diff 376669a93c7f2135...
win-build.log.diff 6803fcae8c6aa08e...

Copy link
Contributor

@ryanofsky ryanofsky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review ACK f0d7ed1. Changes since last review: adding comment explaining check for predefined make variables, dropping freetype commit, adding commit whitelisting overrides for recursive makes

@fanquake
Copy link
Member

Please don't merge this just yet. There's at least one build failure that will need addressing (likely in a follow up, but I want to understand it before merging).

@fanquake
Copy link
Member

There is a at least one failure building zlib, when you cross-compile for macOS and you set CC=clang:

make -C depends/ -j6 V=1 HOST=x86_64-apple-darwin16 CC=clang CXX=clang++
....
echo Configuring zlib...
Configuring zlib...
rm -rf /bitcoin/depends/x86_64-apple-darwin16; mkdir -p /bitcoin/depends/x86_64-apple-darwin16/lib; cd /bitcoin/depends/x86_64-apple-darwin16;  tar --no-same-owner -xf /bitcoin/depends/built/x86_64-apple-darwin16/native_cctools/native_cctools-3764b223c011574971ee3ae09ce968ba5dc2f00f-d41d83b91be.tar.gz; 
mkdir -p /bitcoin/depends/work/build/x86_64-apple-darwin16/zlib/1.2.11-9d169cb6e6c/.
cd /bitcoin/depends/work/build/x86_64-apple-darwin16/zlib/1.2.11-9d169cb6e6c/.;     PKG_CONFIG_LIBDIR=/bitcoin/depends/x86_64-apple-darwin16/lib/pkgconfig PKG_CONFIG_PATH=/bitcoin/depends/x86_64-apple-darwin16/share/pkgconfig CMAKE_MODULE_PATH=/bitcoin/depends/x86_64-apple-darwin16/lib/cmake PATH=/bitcoin/depends/x86_64-apple-darwin16/native/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin   env CC="clang" CFLAGS="-pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC" RANLIB="x86_64-apple-darwin16-ranlib" AR="x86_64-apple-darwin16-ar"    AR="x86_64-apple-darwin16-libtool" ARFLAGS="-o"    ./configure --static --prefix=/bitcoin/depends/x86_64-apple-darwin16
Building static library libz.a version 1.2.11 with clang.
Checking for size_t... Yes.
Checking for off64_t... Yes.
Checking for fseeko... Yes.
Checking for strerror... Yes.
Checking for unistd.h... Yes.
Checking for stdarg.h... Yes.
Checking whether to use vs[n]printf() or s[n]printf()... using vs[n]printf().
Checking for vsnprintf() in stdio.h... Yes.
Checking for return value of vsnprintf()... Yes.
Checking for attribute(visibility) support... Yes.
touch /bitcoin/depends/work/build/x86_64-apple-darwin16/zlib/1.2.11-9d169cb6e6c/./.stamp_configured
echo Building zlib...
Building zlib...
mkdir -p /bitcoin/depends/work/build/x86_64-apple-darwin16/zlib/1.2.11-9d169cb6e6c/.
cd /bitcoin/depends/work/build/x86_64-apple-darwin16/zlib/1.2.11-9d169cb6e6c/.; PATH=/bitcoin/depends/x86_64-apple-darwin16/native/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin   make libz.a
make[1]: Entering directory '/bitcoin/depends/work/build/x86_64-apple-darwin16/zlib/1.2.11-9d169cb6e6c'
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o adler32.o adler32.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o crc32.o crc32.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o deflate.o deflate.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o infback.o infback.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o inffast.o inffast.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o inflate.o inflate.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o inftrees.o inftrees.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o trees.o trees.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o zutil.o zutil.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o compress.o compress.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o uncompr.o uncompr.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o gzclose.o gzclose.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o gzlib.o gzlib.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o gzread.o gzread.c
clang -pipe -O2 -I/bitcoin/depends/x86_64-apple-darwin16/include -fPIC -D_LARGEFILE64_SOURCE=1 -DHAVE_HIDDEN  -c -o gzwrite.o gzwrite.c
x86_64-apple-darwin16-libtool -o libz.a adler32.o crc32.o deflate.o infback.o inffast.o inflate.o inftrees.o trees.o zutil.o compress.o uncompr.o gzclose.o gzlib.o gzread.o gzwrite.o 
error: x86_64-apple-darwin16-libtool: file: adler32.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: crc32.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: deflate.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: infback.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: inffast.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: inflate.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: inftrees.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: trees.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: zutil.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: compress.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: uncompr.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: gzclose.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: gzlib.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: gzread.o is not an object file (not allowed in a library)
error: x86_64-apple-darwin16-libtool: file: gzwrite.o is not an object file (not allowed in a library)
make[1]: *** [Makefile:131: libz.a] Error 1
make[1]: Leaving directory '/bitcoin/depends/work/build/x86_64-apple-darwin16/zlib/1.2.11-9d169cb6e6c'
make: *** [funcs.mk:262: /bitcoin/depends/work/build/x86_64-apple-darwin16/zlib/1.2.11-9d169cb6e6c/./.stamp_built] Error 2
make: Leaving directory '/bitcoin/depends'

I assume this is because we lose our macOS flags. i.e CC becomes just clang instead of clang -target x86_64-apple-darwin16 -mmacosx-version-min=10.12 --sysroot /bitcoin/depends/SDKs/MacOSX10.14.sdk. You also end up with -D_LARGEFILE64_SOURCE=1 being passed.

@dongcarl thoughts? If you want to address this in a follow up I think that's reasonable.

@fanquake
Copy link
Member

I'll also just mention that you can't seem to cross-compile for Windows when using Clang. The build bombs out at Boost (haven't looked into this at all 😴):

echo Building boost...
Building boost...
mkdir -p /bitcoin/depends/work/build/x86_64-w64-mingw32/boost/1_70_0-d650037a261/.
cd /bitcoin/depends/work/build/x86_64-w64-mingw32/boost/1_70_0-d650037a261/.; PATH=/bitcoin/depends/x86_64-w64-mingw32/native/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin   ./b2 -d2 -j2 -d1 --prefix=/bitcoin/depends/work/staging/x86_64-w64-mingw32/boost/1_70_0-d650037a261/bitcoin/depends/x86_64-w64-mingw32 --layout=tagged --build-type=complete --user-config=user-config.jam threading=multi link=static -sNO_BZIP2=1 -sNO_ZLIB=1 variant=release   target-os=windows binary-format=pe threadapi=win32 runtime-link=static  address-model=64  toolset=clang stage
Performing configuration checks

    - default address-model    : 64-bit (cached)
    - default architecture     : x86 (cached)
    - BOOST_COMP_GNUC >= 4.3.0 : no  (cached)

Component configuration:

    - atomic                   : not building
    - chrono                   : not building
    - container                : not building
    - context                  : not building
    - contract                 : not building
    - coroutine                : not building
    - date_time                : not building
    - exception                : not building
    - fiber                    : not building
    - filesystem               : building
    - graph                    : not building
    - graph_parallel           : not building
    - headers                  : not building
    - iostreams                : not building
    - locale                   : not building
    - log                      : not building
    - math                     : not building
    - mpi                      : not building
    - program_options          : not building
    - python                   : not building
    - random                   : not building
    - regex                    : not building
    - serialization            : not building
    - stacktrace               : not building
    - system                   : building
    - test                     : building
    - thread                   : building
    - timer                    : not building
    - type_erasure             : not building
    - wave                     : not building

...patience...
...patience...
...found 1632 targets...
...updating 5 targets...
clang-linux.compile.c++.without-pch bin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden/win32/thread_primitives.obj

  "clang++" -c -x c++ -fvisibility-inlines-hidden -std=c++11 -fvisibility=hidden     -I/bitcoin/depends/x86_64-w64-mingw32/include     -m64 -O3 -Wall -fvisibility=hidden -Wno-inline -pthread -Wextra -Wno-long-long -Wno-unused-parameter -Wno-variadic-macros -Wunused-function -DBOOST_ALL_NO_LIB=1 -DBOOST_CHRONO_STATIC_LINK=1 -DBOOST_THREAD_BUILD_LIB=1 -DBOOST_THREAD_USES_CHRONO -DBOOST_THREAD_WIN32 -DBOOST_USE_WINDOWS_H -DNDEBUG -DWIN32_LEAN_AND_MEAN -I"." -o "bin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden/win32/thread_primitives.obj" "libs/thread/src/win32/thread_primitives.cpp"

In file included from libs/thread/src/win32/thread_primitives.cpp:10:
In file included from ./boost/winapi/dll.hpp:14:
./boost/winapi/basic_types.hpp:19:11: fatal error: 'windows.h' file not found
# include <windows.h>
          ^~~~~~~~~~~
1 error generated.
...failed clang-linux.compile.c++.without-pch bin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden/win32/thread_primitives.obj...
clang-linux.compile.c++.without-pch bin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden/win32/thread.obj

  "clang++" -c -x c++ -fvisibility-inlines-hidden -std=c++11 -fvisibility=hidden     -I/bitcoin/depends/x86_64-w64-mingw32/include     -m64 -O3 -Wall -fvisibility=hidden -Wno-inline -pthread -Wextra -Wno-long-long -Wno-unused-parameter -Wno-variadic-macros -Wunused-function -DBOOST_ALL_NO_LIB=1 -DBOOST_CHRONO_STATIC_LINK=1 -DBOOST_THREAD_BUILD_LIB=1 -DBOOST_THREAD_USES_CHRONO -DBOOST_THREAD_WIN32 -DBOOST_USE_WINDOWS_H -DNDEBUG -DWIN32_LEAN_AND_MEAN -I"." -o "bin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden/win32/thread.obj" "libs/thread/src/win32/thread.cpp"

In file included from libs/thread/src/win32/thread.cpp:11:
In file included from ./boost/thread/thread_only.hpp:15:
In file included from ./boost/thread/win32/thread_data.hpp:11:
In file included from ./boost/thread/win32/thread_primitives.hpp:18:
./boost/detail/interlocked.hpp:53:11: fatal error: 'windows.h' file not found
# include <windows.h>
          ^~~~~~~~~~~
1 error generated.
...failed clang-linux.compile.c++.without-pch bin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden/win32/thread.obj...
...skipped <pbin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden>libboost_thread-mt-s-x64.lib(clean) for lack of <pbin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden>win32/thread.obj...
...skipped <pbin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden>libboost_thread-mt-s-x64.lib for lack of <pbin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden>win32/thread.obj...
...skipped <p/bitcoin/depends/work/build/x86_64-w64-mingw32/boost/1_70_0-d650037a261/stage/lib>libboost_thread-mt-s-x64.lib for lack of <pbin.v2/libs/thread/build/clang-linux-7.0.1/release/link-static/target-os-windows/threadapi-win32/threading-multi/visibility-hidden>libboost_thread-mt-s-x64.lib...
...failed updating 2 targets...
...skipped 3 targets...
make: *** [funcs.mk:262: /bitcoin/depends/work/build/x86_64-w64-mingw32/boost/1_70_0-d650037a261/./.stamp_built] Error 1
make: Leaving directory '/bitcoin/depends'

@maflcko
Copy link
Member

maflcko commented May 29, 2020

There is also a build failure on a fresh Ubuntu focal vm:

checking for QT5... yes
checking for QT_TEST... yes
checking for QT_DBUS... yes
checking for static Qt... yes
checking for QTFONTDATABASE... yes
checking for QTEVENTDISPATCHER... yes
checking for QTTHEME... yes
checking for QTDEVICEDISCOVERY... yes
checking for QTACCESSIBILITY... yes
checking for QTFB... yes
checking for QTXCBQPA... yes
checking for static Qt plugins: -lqminimal... yes
checking for static Qt plugins: -lqxcb -lxcb-static... no
configure: error: Could not resolve: -lqxcb -lxcb-static

Steps to reproduce:

# history 
    1  apt update && apt install git vim htop -y
    2  cd bitcoin-core/
    3  git clone --depth=1 https://github.com/dongcarl/bitcoin/ ./bitcoin-core --branch 2020-04-improve-depends-hosts2
    4  cd bitcoin-core/
    5  apt install curl wget htop git vim ccache build-essential libtool autotools-dev automake pkg-config bsdmainutils python3-zmq clang libc++abi-dev libc++-dev -y
    7  make -C depends CC=clang CXX='clang++ -stdlib=libc++' -j 16
   11  ./autogen.sh && CONFIG_SITE=$PWD/depends/x86_64-pc-linux-gnu/share/config.site ./configure --with-gui=qt5 && make clean && make -j 16

@dongcarl
Copy link
Contributor Author

dongcarl commented May 29, 2020

I think this PR by itself is already an improvement over the current situation (all cases that worked before still works, and a few cases that didn't work before now works) and I don't really want to overload this PR any longer. After doing some investigation, I think the following are worthwhile followups:

  1. Make cross-compiles work with user-specified well-known vars
  2. Make qt's build system work better with user-specified well-known vars (i.e. choose the right platform/xplatform based on CC, CXX, CFLAGS, and CXXFLAGS)

One thing to keep in mind for both of these followups is that we've been abusing CC and CXX for too long, I think it's time to put things that are flags into CFLAGS and CXXFLAGS.

@fanquake @MarcoFalke Let me know if that sounds okay.
Many thanks to @ryanofsky for his diligent reviews.

@maflcko
Copy link
Member

maflcko commented May 29, 2020

I think it's time to put things that are flags into CFLAGS and CXXFLAGS

Is there documentation on how to pass CXXFLAGS into depends qt? I recently tried that and it appeared they were not picked up.

@maflcko
Copy link
Member

maflcko commented May 29, 2020

Concept ACK on merging this

@dongcarl
Copy link
Contributor Author

dongcarl commented May 29, 2020

Is there documentation on how to pass CXXFLAGS into depends qt? I recently tried that and it appeared they were not picked up.

We do some extremely nasty seds in qtbase/mkspecs :-( See: #16837

A cleanup of how we interact with QT's build system probably also deserves to be a followup

@fanquake
Copy link
Member

@dongcarl followups sound ok. I think we've figured out a path to improving the macOS CFLAGS post this change as well.

@fanquake fanquake merged commit 98ebe78 into bitcoin:master May 30, 2020
@DrahtBot
Copy link
Contributor

Gitian builds

File commit ea3e9e0
(master)
commit c403792
(master and this pull)
bitcoin-core-linux-0.21-res.yml e00ff2634378492a... f1657e6d6fd46291...
bitcoin-core-osx-0.21-res.yml 6bea577c165f0a1c... 274dc8c79ecdb481...
bitcoin-core-win-0.21-res.yml 341ace21b5e1295b... 5e76dc7241d1ef32...
*-aarch64-linux-gnu-debug.tar.gz 70bdba0505ce8924... a2b469888544efd4...
*-aarch64-linux-gnu.tar.gz 7f9920875e142a5f... f3f3e47f7cbbb446...
*-arm-linux-gnueabihf-debug.tar.gz 5d8bb5e81780ec2e... 04dd46b3749c90ba...
*-arm-linux-gnueabihf.tar.gz 15bd3cc2ea2bfb73... 92cf39e22f831092...
*-osx-unsigned.dmg 46dc5ef797690385... 004d1742259024db...
*-osx64.tar.gz af4955425388e87b... 220b45fc070f0e22...
*-riscv64-linux-gnu-debug.tar.gz 0df800aaef4b91d7... 22db593173f6fdf7...
*-riscv64-linux-gnu.tar.gz 1bf701bd1e7608ef... cc04955f0b972db9...
*-win64-debug.zip b919457ca624ba40... f2de6f91405312b9...
*-win64-setup-unsigned.exe 182e96364ac633ab... 872b21ea65498680...
*-win64.zip 64904b99bcba46f7... 125f1c16bcf8625f...
*-x86_64-linux-gnu-debug.tar.gz d07957307fb8ce8c... 31548ea02305fedb...
*-x86_64-linux-gnu.tar.gz a96c250cbaa8f15b... cd2cafb477cabe20...
*.tar.gz ac0bd374e33512cc... 0d7f44492e6b6ece...
linux-build.log aa0e26db766077b4... e80a33cd5780e51d...
osx-build.log a08ad58eaf7be853... 848c2feab0cdc3ca...
win-build.log e66b6e6870cf3457... f8605a444f37fbab...
bitcoin-core-linux-0.21-res.yml.diff ac03ea350f9452c8...
bitcoin-core-osx-0.21-res.yml.diff 4e28bb0f4500cc42...
bitcoin-core-win-0.21-res.yml.diff c3333024a1f7c025...
linux-build.log.diff 36776edcb5f6cdf4...
osx-build.log.diff af39421aa2997139...
win-build.log.diff d3be33a912ad67e8...

sidhujag pushed a commit to syscoin/syscoin that referenced this pull request May 31, 2020
f0d7ed1 depends: Propagate only specific CLI variables to sub-makes (Carl Dong)
0a33803 depends: boost: Use clang toolset if clang in CXX (Carl Dong)
1ce74bc depends: boost: Split target-os from toolset (Carl Dong)
2d4e480 depends: boost: Specify toolset to bootstrap.sh (Carl Dong)
3d6603e depends: Propagate well-known vars into depends (Carl Dong)

Pull request description:

  From: bitcoin#18308 (comment)

  The following monstrosity is quite useful when invoked inside `depends`, and reviewers can use it to compare the behaviour of this change against master.
  ```bash
  make print-{{,{host,{,{i686,x86_64,riscv64}_}linux}_}{CC,CXX},boost_{cc,cxx}}
  ```

  It would also be helpful to make sure that setting `HOST`, `CC`, and `CXX` does the right thing. The 3 hosts I found offered good coverage were: `{x86_64,i686,riscv64}-linux-gnu`. As we special-case the `x86_64` and `i686` hosts in `depends/hosts/linux.mk`, and `riscv64` is a sanity check for a non-special-cased host.

ACKs for top commit:
  hebasto:
    ACK f0d7ed1, tested on Linux Mint 19.3 (x86_64):
  practicalswift:
    ACK f0d7ed1 -- patch looks correct
  laanwj:
    Code review and concept ACK f0d7ed1
  ryanofsky:
    Code review ACK f0d7ed1. Changes since last review: adding comment explaining check for predefined make variables, dropping freetype commit, adding commit whitelisting overrides for recursive makes

Tree-SHA512: b6b8e76f713c26a0add6cd685824e2f5639109236ee9f89338f7c79cb1b1f2c3897bfb62b80b023d6d1943b5a6eb282a2f827f1f499c5e556eca015d6635fa65
jasonbcox pushed a commit to Bitcoin-ABC/bitcoin-abc that referenced this pull request Sep 29, 2020
Summary:
This will makes the boost depends build follow the CC/CXX environment
variables (and allow the build with clang).

Backport of core [[bitcoin/bitcoin#18820 | PR18820]].

Test Plan: Run the Gitian builds.

Reviewers: #bitcoin_abc, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

Differential Revision: https://reviews.bitcoinabc.org/D7672
zkbot added a commit to zcash/zcash that referenced this pull request Jan 15, 2021
Boost build backports

Cherry-picked from the following upstream PRs:
- bitcoin/bitcoin#17087
- bitcoin/bitcoin#17231
- bitcoin/bitcoin#17928
- bitcoin/bitcoin#18820
- bitcoin/bitcoin#19764

Kudos to @dongcarl for all the excellent upstream depends system hackery!
furszy added a commit to PIVX-Project/PIVX that referenced this pull request May 9, 2021
de7766c Build: Update Boost download URL (Fuzzbawls)
7be66c9 Doc: document updated boost version in dependencies.md (Fuzzbawls)
bcb77b6 depends: boost: Specify cflags+compileflags (Carl Dong)
b8f8574 depends: boost: Remove unnecessary _archiver_ (Carl Dong)
29fdbd9 depends: boost: Cleanup toolset selection (Carl Dong)
28393b6 depends: boost: Cleanup architecture/address-model (Carl Dong)
6af3ffa depends: boost: Disable all compression (Carl Dong)
0f09788 depends: boost: Split into non-/native packages (Carl Dong)
de97b06 depends: boost: Bump to 1.71.0 (Carl Dong)
19f474b depends: boost: Refer to version in URL (Carl Dong)
7d4257c depends: Propagate only specific CLI variables to sub-makes (Carl Dong)
fcbf870 depends: boost: Use clang toolset if clang in CXX (Carl Dong)
aad5009 depends: boost: Split target-os from toolset (Carl Dong)
fae749b depends: boost: Specify toolset to bootstrap.sh (Carl Dong)
c2bfedb depends: Propagate well-known vars into depends (Carl Dong)
091ae4a depends: Consistent use of package variable (Peter Bushnell)
635bdc1 depends: fix boost mac cross build with clang 9+ (Cory Fields)
d796365 build: Add variable printing target to Makefiles (Carl Dong)

Pull request description:

  Backports the following upstream PRs to clean up and update the Boost dependency

  - bitcoin#17087
  - bitcoin#17231
  - bitcoin#17928
  - bitcoin#18820
  - bitcoin#19764

ACKs for top commit:
  random-zebra:
    ACK de7766c
  furszy:
    no code changes after rebase, utACK de7766c and merging..

Tree-SHA512: 4abe88718892bce40a2df023e99a26a16ce3c5d470f55e70d6c6cca117ee8b8bb29968be6d40873bc9ece3f9df769bea248cbb38c1c5c2f318016702533f2736
kwvg added a commit to kwvg/dash that referenced this pull request Aug 22, 2021
kwvg added a commit to kwvg/dash that referenced this pull request Aug 22, 2021
kwvg added a commit to kwvg/dash that referenced this pull request Aug 27, 2021
PastaPastaPasta added a commit to dashpay/dash that referenced this pull request Aug 31, 2021
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Feb 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants