aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfanquake <fanquake@gmail.com>2023-04-21 14:22:33 +0100
committerfanquake <fanquake@gmail.com>2023-04-21 14:29:03 +0100
commitf3f5c9712670fc2c9fb3b57580146aa248a5d36f (patch)
treedafc3741dc4283e5b603f29763f03a280aa36f90
parentc63c8a159060e5ab1e896aa6808602bcc55eae29 (diff)
parent63c0c4ff10b2f6ed8510ef372a5b1f6a6494b179 (diff)
Merge bitcoin/bitcoin#27496: depends: reuse _config_opts for CMake options
63c0c4ff10b2f6ed8510ef372a5b1f6a6494b179 depends: reuse _config_opts for CMake options (Cory Fields) Pull request description: Context: I'm [currently experimenting with building our depends with CMake when possible](https://github.com/theuni/bitcoin/commits/depends-cmake) as part of our future transition to CMake. Specifically zmq, libevent, libnatpmp, and miniupnpc all have existing CMake buildsystems. Building them with CMake will allow us to drop several deps that we currently have (autoconf, automake, pkg-config, etc) which would be unfortunate to carry over after the switch-over. But that's not relevant for this PR. This is just a very simple change that makes the above work easier to experiment with as it [adds a needed feature for CMake packages](https://github.com/theuni/bitcoin/commit/5733dc200004004dcce70eaa105d36ba2e75ce7b#diff-e6ed342a25092e0a6d0308e0bfd826044578847132cc6726ac4afa2ca767b61aR20). It's a no-op for the current builds. --- From commit description: This will allow us to use the existing machinery for filtering by arch, os, debug/release, etc. For example, the following becomes possible for libevent when building with CMake: `$(package)_config_opts_release=-DEVENT__DISABLE_DEBUG_MODE` Now the define is only set when not building depends with DEBUG=1 ACKs for top commit: hebasto: ACK 63c0c4ff10b2f6ed8510ef372a5b1f6a6494b179 Tree-SHA512: 17d123219d2f98c017880196966ffebd5d09d3e2db8e443e227eb7e49da46e9d971fbe7fd2b99a324fc367e1bbe0ac3cd15b399bce98dd87fbb144d767e15fe7
-rw-r--r--depends/funcs.mk2
-rw-r--r--depends/packages/libmultiprocess.mk4
2 files changed, 3 insertions, 3 deletions
diff --git a/depends/funcs.mk b/depends/funcs.mk
index f0bbf4a168..987be4e611 100644
--- a/depends/funcs.mk
+++ b/depends/funcs.mk
@@ -176,7 +176,7 @@ $(1)_cmake=env CC="$$($(1)_cc)" \
CXX="$$($(1)_cxx)" \
CXXFLAGS="$$($(1)_cppflags) $$($(1)_cxxflags)" \
LDFLAGS="$$($(1)_ldflags)" \
- cmake -DCMAKE_INSTALL_PREFIX:PATH="$$($($(1)_type)_prefix)" $$($(1)_cmake_opts)
+ cmake -DCMAKE_INSTALL_PREFIX:PATH="$$($($(1)_type)_prefix)" $$($(1)_config_opts)
ifeq ($($(1)_type),build)
$(1)_cmake += -DCMAKE_INSTALL_RPATH:PATH="$$($($(1)_type)_prefix)/lib"
else
diff --git a/depends/packages/libmultiprocess.mk b/depends/packages/libmultiprocess.mk
index 6da5693b3f..765d649377 100644
--- a/depends/packages/libmultiprocess.mk
+++ b/depends/packages/libmultiprocess.mk
@@ -10,8 +10,8 @@ endif
define $(package)_set_vars :=
ifneq ($(host),$(build))
-$(package)_cmake_opts := -DCAPNP_EXECUTABLE="$$(native_capnp_prefixbin)/capnp"
-$(package)_cmake_opts += -DCAPNPC_CXX_EXECUTABLE="$$(native_capnp_prefixbin)/capnpc-c++"
+$(package)_config_opts := -DCAPNP_EXECUTABLE="$$(native_capnp_prefixbin)/capnp"
+$(package)_config_opts += -DCAPNPC_CXX_EXECUTABLE="$$(native_capnp_prefixbin)/capnpc-c++"
endif
endef