<!-- This issue tracker is only for technical issues related to Bitcoin Core. General bitcoin questions and/or support requests are best directed to the Bitcoin StackExchange at https://bitcoin.stackexchange.com. For reporting security issues, please read instructions at https://bitcoincore.org/en/contact/. If the node is "stuck" during sync or giving "block checksum mismatch" errors, please ensure your hardware is stable by running memtest and observe CPU temperature with a load-test tool such as linpack before creating an issue! -->
<!-- Describe the issue -->
I have an error while I'm compiling bitcoin on my Ubuntu machine to Windows libs using the mingw32
Expected behavior Compiling the bitcoin library (v0.20.1) by using the x86_64-w64-mingw32 compiler.
<!--- What behavior did you expect? -->
Actual behavior
CXXLD libbitcoinconsensus.la
CXX bitcoind-bitcoind.o
/usr/bin/x86_64-w64-mingw32-ld: crypto/.libs/libbitcoinconsensus_la-sha256.o:sha256.cpp:(.text+0x20f): undefined reference to `sha256_sse4::Transform(unsigned int*, unsigned char const*, unsigned long long)'
/usr/bin/x86_64-w64-mingw32-ld: crypto/.libs/libbitcoinconsensus_la-sha256.o:sha256.cpp:(.text+0x224): undefined reference to `sha256_sse4::Transform(unsigned int*, unsigned char const*, unsigned long long)'
/usr/bin/x86_64-w64-mingw32-ld: crypto/.libs/libbitcoinconsensus_la-sha256.o:sha256.cpp:(.text+0x29b): undefined reference to `sha256_sse4::Transform(unsigned int*, unsigned char const*, unsigned long long)'
/usr/bin/x86_64-w64-mingw32-ld: crypto/.libs/libbitcoinconsensus_la-sha256.o:sha256.cpp:(.rdata$.refptr._ZN11sha256_sse49TransformEPjPKhy[.refptr._ZN11sha256_sse49TransformEPjPKhy]+0x0): undefined reference to `sha256_sse4::Transform(unsigned int*, unsigned char const*, unsigned long long)'
/usr/bin/x86_64-w64-mingw32-ld: .libs/libbitcoinconsensus_la-arith_uint256.o:arith_uint256.cpp:(.text$_ZN9base_uintILj256EE6SetHexEPKc[_ZN9base_uintILj256EE6SetHexEPKc]+0x48): undefined reference to `base_blob<256u>::SetHex(char const*)'
/usr/bin/x86_64-w64-mingw32-ld: .libs/libbitcoinconsensus_la-arith_uint256.o:arith_uint256.cpp:(.text$_ZNK9base_uintILj256EE6GetHexB5cxx11Ev[_ZNK9base_uintILj256EE6GetHexB5cxx11Ev]+0x51): undefined reference to `base_blob<256u>::GetHex[abi:cxx11]() const'
/usr/bin/x86_64-w64-mingw32-ld: .libs/libbitcoinconsensus_la-hash.o:hash.cpp:(.text+0x167): undefined reference to `CHMAC_SHA512::CHMAC_SHA512(unsigned char const*, unsigned long long)'
/usr/bin/x86_64-w64-mingw32-ld: .libs/libbitcoinconsensus_la-hash.o:hash.cpp:(.text+0x1ac): undefined reference to `CHMAC_SHA512::Finalize(unsigned char*)'
/usr/bin/x86_64-w64-mingw32-ld: primitives/.libs/libbitcoinconsensus_la-block.o:block.cpp:(.text+0x307): undefined reference to `base_blob<256u>::ToString[abi:cxx11]() const'
/usr/bin/x86_64-w64-mingw32-ld: primitives/.libs/libbitcoinconsensus_la-block.o:block.cpp:(.text+0x323): undefined reference to `base_blob<256u>::ToString[abi:cxx11]() const'
/usr/bin/x86_64-w64-mingw32-ld: primitives/.libs/libbitcoinconsensus_la-block.o:block.cpp:(.text+0x35a): undefined reference to `base_blob<256u>::ToString[abi:cxx11]() const'
/usr/bin/x86_64-w64-mingw32-ld: primitives/.libs/libbitcoinconsensus_la-transaction.o:transaction.cpp:(.text+0xb26): undefined reference to `base_blob<256u>::ToString[abi:cxx11]() const'
/usr/bin/x86_64-w64-mingw32-ld: primitives/.libs/libbitcoinconsensus_la-transaction.o:transaction.cpp:(.text+0x20e3): undefined reference to `base_blob<256u>::ToString[abi:cxx11]() const'
<!--- What was the actual behavior (provide screenshots if the issue is GUI-related)? -->
To reproduce
CONFIG_SITE=$PWD/depends/x86_64-w64-mingw32/share/config.site ./configure --prefix=/ --disable-qt
make -j4
<!--- How reliably can you reproduce the issue, what are the steps to do so? -->
System information No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 20.04.1 LTS Release: 20.04 Codename: focal
<!-- What version of Bitcoin Core are you using, where did you get it (website, self-compiled, etc)? -->
<!-- What type of machine are you observing the error on (OS/CPU and disk type)? -->
<!-- GUI-related issue? What is your operating system and its version? If Linux, what is your desktop environment and graphical shell? -->
<!-- Any extra information that might be useful in the debugging process. -->
<!--- This is normally the contents of a `debug.log` or `config.log` file. Raw text or a link to a pastebin type site are preferred. -->