dlt-daemon: fix wrong CONFIGURATION_FILES_DIR

The not aligned value of CONFIGURATION_FILES_DIR makes the configuration
file install path is different with the default configuration file path
from where the application to read, then make the service dlt/dlt-system
not works well.

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
This commit is contained in:
Changqing Li
2026-04-10 17:26:32 +08:00
committed by Khem Raj
parent 389cf85390
commit 563b91e5ca
2 changed files with 43 additions and 0 deletions
@@ -0,0 +1,42 @@
From bad5d689a69dca3d1dc3e7653946f1205661afbf Mon Sep 17 00:00:00 2001
From: Changqing Li <changqing.li@windriver.com>
Date: Fri, 10 Apr 2026 13:25:39 +0800
Subject: [PATCH 1/2] CMakeLists.txt: make CONFIGURATION_FILES_DIR aligned
Commit [723e90e dlt: Adaptation for QNX build system with SDP 7.x
(#609)], refer [1], make CONFIGURATION_FILES_DIR not aligned. the CMake
variable CONFIGURATION_FILES_DIR set to CMAKE_INSTALL_SYSCONFDIR, but
the tell the compiler to define macro CONFIGURATION_FILES_DIR as
${CMAKE_INSTALL_PREFIX}/${CONFIGURATION_FILES_DIR}.
At least for linux, this will cause failure of the systemd service. Eg:
if CMAKE_INSTALL_PREFIX is /usr, then the configuration file is
installed under ${CONFIGURATION_FILES_DIR}, usually is /etc. But the
application like dlt-daemon/dlt-system will find the default
configuration file under /usr/etc. This makes service start failed.
[1] https://github.com/COVESA/dlt-daemon/commit/723e90e77db91130375238a592b9a292302a32bb
Upstream-Status: Submitted [https://github.com/COVESA/dlt-daemon/issues/848]
Signed-off-by: Changqing Li <changqing.li@windriver.com>
---
CMakeLists.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index bb9250f..821730a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -289,7 +289,7 @@ endif()
set(CONFIGURATION_FILES_DIR ${CMAKE_INSTALL_SYSCONFDIR})
-add_definitions(-DCONFIGURATION_FILES_DIR="${CMAKE_INSTALL_PREFIX}/${CONFIGURATION_FILES_DIR}")
+add_definitions(-DCONFIGURATION_FILES_DIR="${CONFIGURATION_FILES_DIR}")
add_subdirectory(cmake)
--
2.34.1
@@ -22,6 +22,7 @@ SRC_URI = "git://github.com/COVESA/${BPN}.git;protocol=https;branch=master \
file://0001-Fix-build-failures.patch \
file://0001-fix-build-failure-when-systemd-is-enabled.patch \
file://0001-Fix-build-failure-with-glibc-2.43.patch \
file://0001-CMakeLists.txt-make-CONFIGURATION_FILES_DIR-aligned.patch \
"
SRCREV = "f595ea29d1007ca1c3b2d1fd3a88adf7d3db6320"