add config.h file in CMakefiles.txt 77/110577/1 accepted/tizen/common/20170117.174816 accepted/tizen/ivi/20170118.040154 accepted/tizen/mobile/20170118.040107 accepted/tizen/tv/20170118.040124 accepted/tizen/unified/20170309.032342 accepted/tizen/wearable/20170118.040137 submit/tizen/20170117.055115 submit/tizen_unified/20170308.100405
authorMyoungJune Park <mj2004.park@samsung.com>
Fri, 6 Jan 2017 11:36:01 +0000 (20:36 +0900)
committerMyoungJune Park <mj2004.park@samsung.com>
Tue, 17 Jan 2017 05:50:05 +0000 (14:50 +0900)
- add configurability to choose resource path with .spec

Change-Id: I52c0f249d78c4f869855316874c609bcc01b61cf
Signed-off-by: MyoungJune Park <mj2004.park@samsung.com>
CMakeLists.txt
src/system_setting_platform.c

index bf335a7..0c93dcb 100755 (executable)
@@ -20,6 +20,7 @@ set (SETTING_DEF_RES_PATH "\"${SETTING_DEF_RES}\"")
 set (SETTING_TIME_ZONEINFO_PATH "\"/usr/share/zoneinfo/\"")
 set (SETTING_TZONE_SYMLINK_PATH "\"/opt/etc/localtime\"")
 
+#      DSETTING_DEF_RES
 configure_file (
                "${PROJECT_SOURCE_DIR}/system-setting-config.h.in"
                "${PROJECT_SOURCE_DIR}/include/system-setting-config.h"
@@ -62,6 +63,8 @@ ADD_DEFINITIONS("-D_TZ_SYS_DATA=\"${TZ_SYS_DATA}\"")
 ADD_DEFINITIONS("-D_TZ_SYS_ETC=\"${TZ_SYS_ETC}\"")
 ADD_DEFINITIONS("-D_TZ_SYS_RO_SHARE=\"${TZ_SYS_RO_SHARE}\"")
 ADD_DEFINITIONS("-D_TZ_SYS_SHARE=\"${TZ_SYS_SHARE}\"")
+ADD_DEFINITIONS("-DSETTING_DEF_RES=\"${SETTING_DEF_RES}\"")
+
 
 SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed -Wl,--rpath=/usr/lib")
 
index e9a9199..491e8ae 100644 (file)
@@ -282,7 +282,7 @@ int _is_file_accessible(const char *path)
 
 /*////////////////////////////////////////////////////////////////////////////////////////////////// */
 // @todo move to CMake
-#define DEF_RINGTONE_FILE_PATH SETTING_DEF_RES_PATH"/Ringtones"
+#define DEF_RINGTONE_FILE_PATH SETTING_DEF_RES"/Ringtones"
 
 #define USR_RINGTONE_FILE_PATH "/home/owner/content/Sounds/Ringtones"
 #define JSONFILE "/opt/home/owner/apps_rw/org.tizen.setting/data/.user-ringtones.json"