drivers: led: build as static library

Instead of putting object files inside libzephyr.a,
simply build a separate static library as most other
driver types are doing this already.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This commit is contained in:
Daniel Leung 2021-08-04 14:47:42 -07:00 committed by Christopher Friedt
parent 95782108dd
commit 583d392477

View file

@ -1,14 +1,16 @@
# SPDX-License-Identifier: Apache-2.0
zephyr_sources_ifdef(CONFIG_HT16K33 ht16k33.c)
zephyr_sources_ifdef(CONFIG_LED_GPIO led_gpio.c)
zephyr_sources_ifdef(CONFIG_LED_PWM led_pwm.c)
zephyr_sources_ifdef(CONFIG_LP3943 lp3943.c)
zephyr_sources_ifdef(CONFIG_LP503X lp503x.c)
zephyr_sources_ifdef(CONFIG_LP5562 lp5562.c)
zephyr_sources_ifdef(CONFIG_PCA9633 pca9633.c)
zephyr_sources_ifdef(CONFIG_TLC59108 tlc59108.c)
zephyr_library()
zephyr_sources_ifdef(CONFIG_LED_SHELL led_shell.c)
zephyr_library_sources_ifdef(CONFIG_HT16K33 ht16k33.c)
zephyr_library_sources_ifdef(CONFIG_LED_GPIO led_gpio.c)
zephyr_library_sources_ifdef(CONFIG_LED_PWM led_pwm.c)
zephyr_library_sources_ifdef(CONFIG_LP3943 lp3943.c)
zephyr_library_sources_ifdef(CONFIG_LP503X lp503x.c)
zephyr_library_sources_ifdef(CONFIG_LP5562 lp5562.c)
zephyr_library_sources_ifdef(CONFIG_PCA9633 pca9633.c)
zephyr_library_sources_ifdef(CONFIG_TLC59108 tlc59108.c)
zephyr_sources_ifdef(CONFIG_USERSPACE led_handlers.c)
zephyr_library_sources_ifdef(CONFIG_LED_SHELL led_shell.c)
zephyr_library_sources_ifdef(CONFIG_USERSPACE led_handlers.c)