Change path of configuration file 05/259205/4 accepted/tizen/unified/20210608.131728 submit/tizen/20210604.030216
authorJaechul Lee <jcsing.lee@samsung.com>
Wed, 2 Jun 2021 05:36:41 +0000 (14:36 +0900)
committerJaechul Lee <jcsing.lee@samsung.com>
Thu, 3 Jun 2021 05:53:12 +0000 (14:53 +0900)
[Version] 0.0.9
[Issue Type] Update

Change-Id: I8c6673a1678adf4fc4e3cca618cbe521aaa0ba96
Signed-off-by: Jaechul Lee <jcsing.lee@samsung.com>
packaging/hal-api-audio.spec
testcase/parser.cpp

index 3d2947e1e5f582c4a916aff178f2a33a00f66a31..958b69c7d0a30dfe2789388671d5aea918f0c4b7 100644 (file)
@@ -1,6 +1,6 @@
 Name:       hal-api-audio
 Summary:    TIZEN Audio HAL
-Version:    0.0.8
+Version:    0.0.9
 Release:    0
 Group:      System/Libraries
 License:    Apache-2.0
@@ -35,12 +35,12 @@ haltests for audio HAL APIs.
 
 %prep
 %setup -q -n %{name}-%{version}
-%cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DCMAKE_LIBDIR_PREFIX=%{_libdir}
 
 %build
-export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE -DSYSCONFDIR=\\\"%{_sysconfdir}\\\""
-export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
-export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
+export CFLAGS+=" -DTIZEN_DEBUG_ENABLE -DSYSCONFDIR=\\\"%{_hal_sysconfdir}\\\""
+export CXXFLAGS+=" -DTIZEN_DEBUG_ENABLE -DSYSCONFDIR=\\\"%{_hal_sysconfdir}\\\""
+export FFLAGS+=" -DTIZEN_DEBUG_ENABLE"
+%cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DCMAKE_LIBDIR_PREFIX=%{_libdir}
 
 make %{?jobs:-j%jobs}
 
index 608ed3a060cd8ee15d2d3ea4d1f6faf75b4c1636..e22a95085538a0a4f854ea6ba70c7e442035b4e0 100644 (file)
@@ -6,6 +6,8 @@
 
 #include "parser.hh"
 
+#define DEVICE_MAP_FILE                     SYSCONFDIR"/pulse/device-map.json"
+
 #define DEVICE_FILE_OBJECT                  "device-files"
 #define DEVICE_TYPE_PROP_PLAYBACK_DEVICES   "playback-devices"
 #define DEVICE_TYPE_PROP_CAPTURE_DEVICES    "capture-devices"
@@ -38,7 +40,7 @@ using namespace std;
 CDeviceMapParser::CDeviceMapParser()
        : m_json_obj(nullptr), m_json_device_files_obj(nullptr)
 {
-       open_json("/etc/pulse/device-map.json");
+       open_json(DEVICE_MAP_FILE);
 }
 
 CDeviceMapParser::CDeviceMapParser(const char* map_file)