From 5ce92ca9ea19b70f65532ac53415eea8d2470dbe Mon Sep 17 00:00:00 2001 From: fanquake Date: Wed, 3 Apr 2024 10:43:14 +0100 Subject: [PATCH] Merge bitcoin/bitcoin#29527: depends: add -g to DEBUG=1 flags 84fbf9b2841a9ba1ebd1421b9ff9fe444bb1abd9 depends: remove -g from sqlite debug flags (fanquake) eef51afc6a29c693a68400930ef8011be41b7401 depends: add -g to DEBUG=1 flags (fanquake) Pull request description: Add `-g` to the base DEBUG=1 flags in depends. Avoids the need to specify it per-package. More alignment with `--enable-debug` behaviour in configure. We also want to align the optimization flags, currently -O1 vs -O0, however that can be it's own PR. ACKs for top commit: theuni: ACK 84fbf9b2841a9ba1ebd1421b9ff9fe444bb1abd9 Tree-SHA512: 1ee98ba0c13e4b80bb87632658b4f53ce49c73e0e7712990c30da60deca4a349a744232f2d78f243dee9a07f5b9b70f9c2c4ae34082c34ae51b37b054fac61fd --- depends/hosts/darwin.mk | 2 +- depends/hosts/linux.mk | 2 +- depends/hosts/mingw32.mk | 2 +- depends/packages/sqlite.mk | 1 - 4 files changed, 3 insertions(+), 4 deletions(-) diff --git a/depends/hosts/darwin.mk b/depends/hosts/darwin.mk index 0ee08ea8dd..c8fe2c949c 100644 --- a/depends/hosts/darwin.mk +++ b/depends/hosts/darwin.mk @@ -123,7 +123,7 @@ darwin_CXXFLAGS=$(darwin_CFLAGS) darwin_release_CFLAGS=-O2 darwin_release_CXXFLAGS=$(darwin_release_CFLAGS) -darwin_debug_CFLAGS=-O1 +darwin_debug_CFLAGS=-O1 -g darwin_debug_CXXFLAGS=$(darwin_debug_CFLAGS) darwin_cmake_system=Darwin diff --git a/depends/hosts/linux.mk b/depends/hosts/linux.mk index c9669c9219..c06d64f452 100644 --- a/depends/hosts/linux.mk +++ b/depends/hosts/linux.mk @@ -10,7 +10,7 @@ linux_CXXFLAGS=$(linux_CFLAGS) linux_release_CFLAGS=-O2 linux_release_CXXFLAGS=$(linux_release_CFLAGS) -linux_debug_CFLAGS=-O1 +linux_debug_CFLAGS=-O1 -g linux_debug_CXXFLAGS=$(linux_debug_CFLAGS) linux_debug_CPPFLAGS=-D_GLIBCXX_DEBUG -D_GLIBCXX_DEBUG_PEDANTIC -D_LIBCPP_ENABLE_DEBUG_MODE=1 diff --git a/depends/hosts/mingw32.mk b/depends/hosts/mingw32.mk index 979280b5cb..c781a1541b 100644 --- a/depends/hosts/mingw32.mk +++ b/depends/hosts/mingw32.mk @@ -14,7 +14,7 @@ mingw32_CXXFLAGS=$(mingw32_CFLAGS) mingw32_release_CFLAGS=-O2 mingw32_release_CXXFLAGS=$(mingw32_release_CFLAGS) -mingw32_debug_CFLAGS=-O1 +mingw32_debug_CFLAGS=-O1 -g mingw32_debug_CXXFLAGS=$(mingw32_debug_CFLAGS) mingw32_debug_CPPFLAGS=-D_GLIBCXX_DEBUG -D_GLIBCXX_DEBUG_PEDANTIC diff --git a/depends/packages/sqlite.mk b/depends/packages/sqlite.mk index 7d175ec4bb..15bc0f4d7a 100644 --- a/depends/packages/sqlite.mk +++ b/depends/packages/sqlite.mk @@ -8,7 +8,6 @@ define $(package)_set_vars $(package)_config_opts=--disable-shared --disable-readline --disable-dynamic-extensions --enable-option-checking $(package)_config_opts+= --disable-rtree --disable-fts4 --disable-fts5 # We avoid using `--enable-debug` because it overrides CFLAGS, a behavior we want to prevent. -$(package)_cflags_debug += -g $(package)_cppflags_debug += -DSQLITE_DEBUG $(package)_cppflags+=-DSQLITE_DQS=0 -DSQLITE_DEFAULT_MEMSTATUS=0 -DSQLITE_OMIT_DEPRECATED $(package)_cppflags+=-DSQLITE_OMIT_SHARED_CACHE -DSQLITE_OMIT_JSON -DSQLITE_LIKE_DOESNT_MATCH_BLOBS