package/tipidee: fix install without config file

When the tipidee package was added in commit
17deaf60f6, the committer refactored it so
no separate boolean option is required to enable the config file.
However, in doing so, the case where the config file is empty was not
correctly handled: BR2_PACKAGE_TIPIDEE_CONFIG_FILE is never empty
because even with the empty string it contains "".

Fox by qstrip'ing before checking for empty.

Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
This commit is contained in:
Arnout Vandecappelle 2024-07-19 20:03:53 +02:00
parent 89e3b2fb84
commit 27e7b0bf14

View File

@ -33,12 +33,13 @@ define TIPIDEE_INSTALL_TARGET_CMDS
rm -f $(TARGET_DIR)/libexec/tipidee-config-preprocess
endef
ifneq ($(BR2_PACKAGE_TIPIDEE_CONFIG_FILE),)
TIPIDEE_CONFIG_FILE = $(call qstrip, $(BR2_PACKAGE_TIPIDEE_CONFIG_FILE))
ifneq ($(TIPIDEE_CONFIG_FILE),)
TIPIDEE_DEPENDENCIES += host-tipidee
define TIPIDEE_INSTALL_CONFIG
$(HOST_DIR)/bin/tipidee-config \
-i $(call qstrip, $(BR2_PACKAGE_TIPIDEE_CONFIG_FILE)) \
-i "$(TIPIDEE_CONFIG_FILE)" \
-o $(TARGET_DIR)/etc/tipidee.conf.cdb
endef
TIPIDEE_POST_INSTALL_TARGET_HOOKS += TIPIDEE_INSTALL_CONFIG