From 21c6ca9487e0f77fb55412945a926b5c235b9f6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mart=C3=AD=20Bol=C3=ADvar?= Date: Mon, 30 Aug 2021 11:09:22 -0700 Subject: [PATCH] drivers: sensor: clean up zephyr_library calls, again MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Apply the same fix in bd8afe9365e19d579417a514dd3bc87ee1667b9f (" drivers: sensor: clean up zephyr_library calls") to remove redundant code in the sensor driver build system files. Additional instances of the antipattern have crept in. Signed-off-by: Martí Bolívar --- drivers/sensor/lsm303dlhc_magn/CMakeLists.txt | 2 +- drivers/sensor/ms5607/CMakeLists.txt | 5 ++--- drivers/sensor/shtcx/CMakeLists.txt | 3 +-- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/sensor/lsm303dlhc_magn/CMakeLists.txt b/drivers/sensor/lsm303dlhc_magn/CMakeLists.txt index e55822cad27..be88701f6fc 100644 --- a/drivers/sensor/lsm303dlhc_magn/CMakeLists.txt +++ b/drivers/sensor/lsm303dlhc_magn/CMakeLists.txt @@ -5,4 +5,4 @@ zephyr_library() -zephyr_library_sources_ifdef(CONFIG_LSM303DLHC_MAGN lsm303dlhc_magn.c) +zephyr_library_sources(lsm303dlhc_magn.c) diff --git a/drivers/sensor/ms5607/CMakeLists.txt b/drivers/sensor/ms5607/CMakeLists.txt index 2fcc0bfee2b..e9c3aaf2590 100644 --- a/drivers/sensor/ms5607/CMakeLists.txt +++ b/drivers/sensor/ms5607/CMakeLists.txt @@ -1,6 +1,5 @@ # Copyright (c) 2019 Thomas Schmid # SPDX-License-Identifier: Apache-2.0 -zephyr_library_sources(ms5607.c) -zephyr_library_sources(ms5607_i2c.c) -zephyr_library_sources_ifdef(CONFIG_MS5607 ms5607_spi.c) +zephyr_library() +zephyr_library_sources(ms5607.c ms5607_i2c.c ms5607_spi.c) diff --git a/drivers/sensor/shtcx/CMakeLists.txt b/drivers/sensor/shtcx/CMakeLists.txt index 47a1daa731e..8fbec86ad2d 100644 --- a/drivers/sensor/shtcx/CMakeLists.txt +++ b/drivers/sensor/shtcx/CMakeLists.txt @@ -1,5 +1,4 @@ # SPDX-License-Identifier: Apache-2.0 zephyr_library() - -zephyr_library_sources_ifdef(CONFIG_SHTCX shtcx.c) +zephyr_library_sources(shtcx.c)