update CMakefile and rpm spec file 85/159085/1
authorJeonghoon Park <jh1979.park@samsung.com>
Tue, 7 Nov 2017 02:31:07 +0000 (11:31 +0900)
committerJeonghoon Park <jh1979.park@samsung.com>
Tue, 7 Nov 2017 02:31:07 +0000 (11:31 +0900)
Change-Id: I7b5457e3ff13716c14deae4f1308f6a5eb061bb9

CMakeLists.txt
packaging/org.tizen.position-finder-server.spec

index bd6c79c..737bea3 100644 (file)
@@ -26,6 +26,7 @@ pkg_check_modules(APP_PKGS REQUIRED
 
 ADD_DEFINITIONS(-DCBOR_FILE_IN_RES="${INSTALL_RESDIR}/${CBOR_FILE}")
 ADD_DEFINITIONS(-DCBOR_FILE_IN_DATA="${INSTALL_OWNER_DATADIR}/${CBOR_FILE}")
+ADD_DEFINITIONS(-DCONF_FILE="${INSTALL_RESDIR}/${CONF_FILE}")
 
 FOREACH (flag ${APP_PKGS_CFLAGS})
     SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}")
@@ -40,7 +41,9 @@ INCLUDE_DIRECTORIES(${PROJECT_ROOT_DIR}/inc)
 ADD_EXECUTABLE(${PROJECT_NAME}
        ${PROJECT_ROOT_DIR}/src/controller.c
        ${PROJECT_ROOT_DIR}/src/controller_internal.c
+       ${PROJECT_ROOT_DIR}/src/controller_util.c
        ${PROJECT_ROOT_DIR}/src/connectivity.c
+       ${PROJECT_ROOT_DIR}/src/webutil.c
        ${PROJECT_ROOT_DIR}/src/resource.c
        ${PROJECT_ROOT_DIR}/src/resource/resource_illuminance_sensor.c
        ${PROJECT_ROOT_DIR}/src/resource/resource_infrared_motion_sensor.c
@@ -69,5 +72,6 @@ INSTALL(TARGETS ${PROJECT_NAME} DESTINATION ${INSTALL_EXEC_PREFIX})
 INSTALL(FILES ${ORG_PREFIX}.${PROJECT_NAME}.xml DESTINATION ${SYS_PACKAGES_DIR})
 INSTALL(FILES ${PROJECT_ROOT_DIR}/shared/res/default_icon.png DESTINATION ${SYS_ICONS_DIR} RENAME ${PROJECT_NAME}.png)
 INSTALL(FILES ${PROJECT_ROOT_DIR}/res/${CBOR_FILE} DESTINATION ${INSTALL_RESDIR})
+INSTALL(FILES ${PROJECT_ROOT_DIR}/res/${CONF_FILE} DESTINATION ${INSTALL_RESDIR})
 
 # End of a file
index dbb783b..f44cb0e 100644 (file)
@@ -44,6 +44,7 @@ Server for Position Finder
 %define _sys_packages_dir %{TZ_SYS_RO_PACKAGES}
 %define _sys_license_dir %{TZ_SYS_SHARE}/license
 %define _cbor_file iotcon-test-svr-db-server.dat
+%define _conf_file pi.conf
 
 %ifarch %{arm}
 export CFLAGS="$CFLAGS -DTIZEN_BUILD_TARGET"
@@ -62,7 +63,8 @@ cmake . -DP_NAME=%{P_NAME} \
        -DINSTALL_RESDIR=%{_pkg_res_dir} \
        -DSYS_ICONS_DIR=%{_sys_icons_dir} \
        -DSYS_PACKAGES_DIR=%{_sys_packages_dir} \
-       -DCBOR_FILE=%{_cbor_file}
+       -DCBOR_FILE=%{_cbor_file} \
+       -DCONF_FILE=%{_conf_file}
 make %{?jobs:-j%jobs}
 
 %install
@@ -84,6 +86,7 @@ chmod 444 %{_pkg_res_dir}/*.dat
 
 %files
 %{_pkg_res_dir}/*.dat
+%{_pkg_res_dir}/*.conf
 %manifest %{alias}.manifest
 %defattr(-,root,root,-)
 %{_pkg_dir}/bin/%{P_NAME}