From f6a6c1bd4d4b69f7e24a2a5024f6a3519ffc3386 Mon Sep 17 00:00:00 2001 From: Michael Spang Date: Thu, 22 Oct 2020 19:45:40 -0400 Subject: [PATCH] Remove support for unified BuildConfig.h (#3355) This mode was only used by autoconf. Rename CHIP_SEPARATE_CONFIG_H to CHIP_HAVE_CONFIG_H since that's the only mode now. --- config/nrfconnect/nrfconnect-app.cmake | 2 +- examples/wifi-echo/server/esp32/Makefile | 2 +- src/BUILD.gn | 2 +- src/ble/BleConfig.h | 2 +- src/crypto/CHIPCryptoPAL.h | 2 +- src/include/platform/CHIPDeviceConfig.h | 2 +- src/inet/InetConfig.h | 2 +- src/inet/RawEndPoint.cpp | 4 ++-- src/inet/UDPEndPoint.cpp | 4 ++-- src/lib/core/CHIPConfig.h | 2 +- src/lib/message/support/crypto/CHIPCrypto.h | 2 +- src/lwip/efr32/lwipopts.h | 2 +- src/lwip/k32w/lwipopts.h | 2 +- src/lwip/nrf5/lwipopts.h | 2 +- src/lwip/standalone/lwipopts.h | 2 +- src/system/SystemConfig.h | 4 +--- src/test_driver/esp32/Makefile | 2 +- src/test_driver/nrfconnect/CMakeLists.txt | 2 +- third_party/lwip/repo/lwip/src/include/lwip/arch.h | 2 +- 19 files changed, 21 insertions(+), 23 deletions(-) diff --git a/config/nrfconnect/nrfconnect-app.cmake b/config/nrfconnect/nrfconnect-app.cmake index 36742f4ad275a3..88dec9dafebe44 100644 --- a/config/nrfconnect/nrfconnect-app.cmake +++ b/config/nrfconnect/nrfconnect-app.cmake @@ -106,4 +106,4 @@ chip_build(ChipLib ChipConfig # ================================================== target_link_libraries(app PUBLIC ChipLib) -target_compile_definitions(app PRIVATE CHIP_SEPARATE_CONFIG_H) +target_compile_definitions(app PRIVATE CHIP_HAVE_CONFIG_H) diff --git a/examples/wifi-echo/server/esp32/Makefile b/examples/wifi-echo/server/esp32/Makefile index ae79a3aaa876dd..4140c5ee5215f6 100644 --- a/examples/wifi-echo/server/esp32/Makefile +++ b/examples/wifi-echo/server/esp32/Makefile @@ -27,7 +27,7 @@ EXTRA_COMPONENT_DIRS += $(PROJECT_PATH)/third_party/connectedhomeip/config/esp32 $(PROJECT_PATH)/../../../common/screen-framework \ CXXFLAGS += -std=c++11 -Os -DLWIP_IPV6_SCOPES=0 -CPPFLAGS += -Os -DLWIP_IPV6_SCOPES=0 -DCHIP_SEPARATE_CONFIG_H +CPPFLAGS += -Os -DLWIP_IPV6_SCOPES=0 -DCHIP_HAVE_CONFIG_H CFLAGS += -Os -DLWIP_IPV6_SCOPES=0 top: all flashing_script diff --git a/src/BUILD.gn b/src/BUILD.gn index 86495962ffe022..eefe21a1528ada 100644 --- a/src/BUILD.gn +++ b/src/BUILD.gn @@ -26,7 +26,7 @@ config("includes") { "${root_gen_dir}/include", ] - defines = [ "CHIP_SEPARATE_CONFIG_H=1" ] + defines = [ "CHIP_HAVE_CONFIG_H=1" ] if (chip_device_platform == "linux" || chip_device_platform == "darwin") { defines += [ "CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE=${chip_enable_ble}" ] diff --git a/src/ble/BleConfig.h b/src/ble/BleConfig.h index 038d4745b82b81..1626dd67f37f9d 100644 --- a/src/ble/BleConfig.h +++ b/src/ble/BleConfig.h @@ -35,7 +35,7 @@ #pragma once -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif diff --git a/src/crypto/CHIPCryptoPAL.h b/src/crypto/CHIPCryptoPAL.h index 6a97704b17a0b0..06aa8bfa20bc3f 100644 --- a/src/crypto/CHIPCryptoPAL.h +++ b/src/crypto/CHIPCryptoPAL.h @@ -23,7 +23,7 @@ #ifndef _CHIP_CRYPTO_PAL_H_ #define _CHIP_CRYPTO_PAL_H_ -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif diff --git a/src/include/platform/CHIPDeviceConfig.h b/src/include/platform/CHIPDeviceConfig.h index c5e39d839da4f6..816a248fb7358b 100644 --- a/src/include/platform/CHIPDeviceConfig.h +++ b/src/include/platform/CHIPDeviceConfig.h @@ -24,7 +24,7 @@ #pragma once -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif diff --git a/src/inet/InetConfig.h b/src/inet/InetConfig.h index 3f88e1a2daea85..1e0997f211ed44 100644 --- a/src/inet/InetConfig.h +++ b/src/inet/InetConfig.h @@ -35,7 +35,7 @@ #pragma once -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif diff --git a/src/inet/RawEndPoint.cpp b/src/inet/RawEndPoint.cpp index dad825334f6da6..0f275deea77a0f 100644 --- a/src/inet/RawEndPoint.cpp +++ b/src/inet/RawEndPoint.cpp @@ -42,9 +42,9 @@ #include #include #include -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include -#endif // CHIP_SEPARATE_CONFIG_H +#endif // CHIP_HAVE_CONFIG_H #endif // CHIP_SYSTEM_CONFIG_USE_LWIP #if CHIP_SYSTEM_CONFIG_USE_SOCKETS diff --git a/src/inet/UDPEndPoint.cpp b/src/inet/UDPEndPoint.cpp index b75d49bdc4b637..5a7714eea1e309 100644 --- a/src/inet/UDPEndPoint.cpp +++ b/src/inet/UDPEndPoint.cpp @@ -41,9 +41,9 @@ #include #include #include -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include -#endif // CHIP_SEPARATE_CONFIG_H +#endif // CHIP_HAVE_CONFIG_H #endif // CHIP_SYSTEM_CONFIG_USE_LWIP #if CHIP_SYSTEM_CONFIG_USE_SOCKETS diff --git a/src/lib/core/CHIPConfig.h b/src/lib/core/CHIPConfig.h index 94746ed50c96cd..642df836e68767 100644 --- a/src/lib/core/CHIPConfig.h +++ b/src/lib/core/CHIPConfig.h @@ -35,7 +35,7 @@ #pragma once -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif diff --git a/src/lib/message/support/crypto/CHIPCrypto.h b/src/lib/message/support/crypto/CHIPCrypto.h index 51c214fc7710c7..42ea7592f5801f 100644 --- a/src/lib/message/support/crypto/CHIPCrypto.h +++ b/src/lib/message/support/crypto/CHIPCrypto.h @@ -26,7 +26,7 @@ #ifndef CHIPCRYPTO_H_ #define CHIPCRYPTO_H_ -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif diff --git a/src/lwip/efr32/lwipopts.h b/src/lwip/efr32/lwipopts.h index 312e28836e4c6f..20abd90ab84dea 100644 --- a/src/lwip/efr32/lwipopts.h +++ b/src/lwip/efr32/lwipopts.h @@ -26,7 +26,7 @@ #ifndef __LWIPOPTS_H__ #define __LWIPOPTS_H__ -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif diff --git a/src/lwip/k32w/lwipopts.h b/src/lwip/k32w/lwipopts.h index e78906707c80ca..046e9364e753ed 100644 --- a/src/lwip/k32w/lwipopts.h +++ b/src/lwip/k32w/lwipopts.h @@ -26,7 +26,7 @@ #ifndef __LWIPOPTS_H__ #define __LWIPOPTS_H__ -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif diff --git a/src/lwip/nrf5/lwipopts.h b/src/lwip/nrf5/lwipopts.h index 70282bee561e1d..808e7b76ff8242 100644 --- a/src/lwip/nrf5/lwipopts.h +++ b/src/lwip/nrf5/lwipopts.h @@ -26,7 +26,7 @@ #ifndef __LWIPOPTS_H__ #define __LWIPOPTS_H__ -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif diff --git a/src/lwip/standalone/lwipopts.h b/src/lwip/standalone/lwipopts.h index 8c9450e4e07b99..c3243adbc1d01a 100644 --- a/src/lwip/standalone/lwipopts.h +++ b/src/lwip/standalone/lwipopts.h @@ -28,7 +28,7 @@ #ifndef __LWIPOPTS_H__ #define __LWIPOPTS_H__ -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif diff --git a/src/system/SystemConfig.h b/src/system/SystemConfig.h index 05a53a64c48f50..5c0fa17b070193 100644 --- a/src/system/SystemConfig.h +++ b/src/system/SystemConfig.h @@ -37,10 +37,8 @@ #pragma once /* Platform include headers */ -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include -#elif defined(HAVE_CONFIG_H) -#include #endif /* Include a CHIP project-specific configuration file, if defined. diff --git a/src/test_driver/esp32/Makefile b/src/test_driver/esp32/Makefile index 1ea00deb87f830..b3769634145d98 100644 --- a/src/test_driver/esp32/Makefile +++ b/src/test_driver/esp32/Makefile @@ -8,7 +8,7 @@ PROJECT_NAME := chip-tests CXXFLAGS += -DCHIP_SUPPORT_FOREIGN_TEST_DRIVERS -DCHIP_TARGET_STYLE_EMBEDDED -Wno-deprecated-declarations CXXFLAGS += -DLWIP_IPV6_SCOPES=0 -CPPFLAGS += -DLWIP_IPV6_SCOPES=0 -DCHIP_SEPARATE_CONFIG_H +CPPFLAGS += -DLWIP_IPV6_SCOPES=0 -DCHIP_HAVE_CONFIG_H CFLAGS += -DLWIP_IPV6_SCOPES=0 EXTRA_COMPONENT_DIRS += $(PROJECT_PATH)/third_party/connectedhomeip/config/esp32/components diff --git a/src/test_driver/nrfconnect/CMakeLists.txt b/src/test_driver/nrfconnect/CMakeLists.txt index c650f7ca1eab1c..bbf1baf6130d5a 100644 --- a/src/test_driver/nrfconnect/CMakeLists.txt +++ b/src/test_driver/nrfconnect/CMakeLists.txt @@ -99,6 +99,6 @@ chip_build(ChipLib ChipConfig target_sources(app PRIVATE main/runner.cpp) target_link_options(app PUBLIC -Wl,--whole-archive ${CHIP_TESTS} -Wl,--no-whole-archive) target_link_libraries(app PUBLIC ChipLib $) -target_compile_definitions(app PUBLIC CHIP_SEPARATE_CONFIG_H) +target_compile_definitions(app PUBLIC CHIP_HAVE_CONFIG_H) add_test(AllChipTests zephyr/zephyr.exe) diff --git a/third_party/lwip/repo/lwip/src/include/lwip/arch.h b/third_party/lwip/repo/lwip/src/include/lwip/arch.h index 03cd9758aa9435..1ab171ba60e6ab 100644 --- a/third_party/lwip/repo/lwip/src/include/lwip/arch.h +++ b/third_party/lwip/repo/lwip/src/include/lwip/arch.h @@ -37,7 +37,7 @@ #ifndef LWIP_HDR_ARCH_H #define LWIP_HDR_ARCH_H -#if CHIP_SEPARATE_CONFIG_H +#if CHIP_HAVE_CONFIG_H #include #endif