mirror of
https://github.com/dashpay/dash.git
synced 2024-12-25 12:02:48 +01:00
53ad08710c
d0a829e9632379e42f0be5c554e3b692f0d14a95 build: fix mutex detection when building bdb on macOS (fanquake) Pull request description: Starting with the Apple Clang shipped with Xcode 12, [Apple has enabled -Werror=implicit-function-declaration by default](https://developer.apple.com/documentation/xcode-release-notes/xcode-12-release-notes): > Clang now reports an error when you use a function without an explicit declaration when building C or Objective-C code for macOS (-Werror=implicit-function-declaration flag is on). This additional error detection unifies Clang’s behavior for iOS/tvOS and macOS 64-bit targets for this diagnostic. (49917738) This causes bdbs mutex detection to fail when building on macOS (not cross-compiling): ```bash checking for mutexes... UNIX/fcntl configure: WARNING: NO SHARED LATCH IMPLEMENTATION FOUND FOR THIS PLATFORM. configure: error: Unable to find a mutex implementation ``` as previously emitted warnings are being turned into errors. i.e: ```bash configure:18704: checking for mutexes configure:18815: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -mmacosx-version-min=10.12 --sysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk -o conftest -pipe -O2 -I/Users/michael/github/fanquake-bitcoin/depends/x86_64-apple-darwin19.6.0/include -L/Users/michael/github/fanquake-bitcoin/depends/x86_64-apple-darwin19.6.0/lib conftest.c -lpthread >&5 conftest.c:46:1: warning: type specifier missing, defaults to 'int' [-Wimplicit-int] main() { ^ conftest.c:51:2: error: implicitly declaring library function 'exit' with type 'void (int) __attribute__((noreturn))' [-Werror,-Wimplicit-function-declaration] exit ( ^ conftest.c:51:2: note: include the header <stdlib.h> or explicitly provide a declaration for 'exit' 1 warning and 1 error generated. ``` Append `-Wno-error=implicit-function-declaration` to `cflags` so that `-Wimplicit-function-declaration` [returns to being a warning](https://clang.llvm.org/docs/UsersManual.html#cmdoption-wno-error), and the configure checks succeed. Fixes #19411. ACKs for top commit: laanwj: Code review ACK d0a829e9632379e42f0be5c554e3b692f0d14a95 Tree-SHA512: 7813005b1fc0b370f843b6c0672acab32c999416e92c3f02b75d866e9c7aa41fe5822704fc74de6b65f0d7d94f2cdd05cc7c3ee83295ff1ecbc71d8492b9a2bf |
||
---|---|---|
.. | ||
backtrace.mk | ||
bdb.mk | ||
boost.mk | ||
chia_bls.mk | ||
dbus.mk | ||
expat.mk | ||
fontconfig.mk | ||
freetype.mk | ||
gmp.mk | ||
libevent.mk | ||
libICE.mk | ||
libSM.mk | ||
libX11.mk | ||
libXau.mk | ||
libxcb.mk | ||
libXext.mk | ||
miniupnpc.mk | ||
native_biplist.mk | ||
native_cctools.mk | ||
native_cdrkit.mk | ||
native_ds_store.mk | ||
native_libdmg-hfsplus.mk | ||
native_mac_alias.mk | ||
native_protobuf.mk | ||
openssl.mk | ||
packages.mk | ||
protobuf.mk | ||
qrencode.mk | ||
qt.mk | ||
xcb_proto.mk | ||
xextproto.mk | ||
xproto.mk | ||
xtrans.mk | ||
zeromq.mk | ||
zlib.mk |