From: SangYoun Kwak Date: Wed, 12 Mar 2025 02:22:48 +0000 (+0900) Subject: hal-backend-service: Add json configs for various build profiles X-Git-Tag: accepted/tizen/unified/20250322.012724~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c7f2efa1a92fa520abb23e01926b357db45bc914;p=platform%2Fhal%2Fapi%2Fcommon.git hal-backend-service: Add json configs for various build profiles To support various build profiles, json config files are added for profiles. Also, 'if statement' is added to the spec file to use appropriate json config file by the build profile. Change-Id: I3989207849471031d98df8438841d3fb1b1cef75 Signed-off-by: SangYoun Kwak --- diff --git a/hal-backend-service/config/hal-backend-service-config-da.json b/hal-backend-service/config/hal-backend-service-config-da.json new file mode 100644 index 0000000..c0aca11 --- /dev/null +++ b/hal-backend-service/config/hal-backend-service-config-da.json @@ -0,0 +1,14 @@ +{ + "process": [ + { + "type": "systemd", + "property": { + "name": "hal-backend-service-device" + }, + "thread": [ + { "hal_module_name": [ "device_display" ] }, + { "hal_module_name": [ "device_led" ] } + ] + } + ] +} diff --git a/hal-backend-service/config/hal-backend-service-config-vd.json b/hal-backend-service/config/hal-backend-service-config-vd.json new file mode 100644 index 0000000..e69de29 diff --git a/packaging/hal-api-common.spec b/packaging/hal-api-common.spec index b2b5e32..f68335c 100644 --- a/packaging/hal-api-common.spec +++ b/packaging/hal-api-common.spec @@ -87,11 +87,22 @@ Haltests for hal-api-common %setup -q %if %{enable_hal_backend_service} -hal-backend-service/hal-backend-service-generator.py \ + # Use different json config file depending on the build profile + %define hal_backend_service_config "hal-backend-service-config.json" + + %if "%{WITH_DA}" == "1" + %define hal_backend_service_config "hal-backend-service-config-da.json" + %endif + + %if "%{WITH_VD}" == "1" || "%{WITH_VD_MV}" == "1" + %define hal_backend_service_config "hal-backend-service-config-vd.json" + %endif + + hal-backend-service/hal-backend-service-generator.py \ --enable \ - --config=hal-backend-service-config.json + --config=%{hal_backend_service_config} %else -hal-backend-service/hal-backend-service-generator.py --disable + hal-backend-service/hal-backend-service-generator.py --disable %endif cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} \