notification
libsmack
libsystemd-daemon
+ libtzplatform-config
)
IF(X11_SUPPORT)
BuildRequires: pkgconfig(sensor)
BuildRequires: pkgconfig(libsystemd-daemon)
BuildRequires: pkgconfig(capi-base-common)
+BuildRequires: pkgconfig(libtzplatform-config)
+
%{?systemd_requires}
Requires(preun): /usr/bin/systemctl
Requires(post): /usr/bin/systemctl
cp %{SOURCE4} .
cp %{SOURCE5} .
cp %{SOURCE6} .
-%cmake .
+%cmake . -DTZ_SYS_ETC=%TZ_SYS_ETC
%install
rm -rf %{buildroot}
%post
#memory type vconf key init
+users_gid=$(getent group $TZ_SYS_USER_GROUP | cut -f3 -d':')
+
vconftool set -t int memory/sysman/usbhost_status -1 -i
vconftool set -t int memory/sysman/mmc 0 -i
vconftool set -t int memory/sysman/earjack_key 0 -i
vconftool set -t int memory/sysman/mmc_format -1 -i
vconftool set -t int memory/sysman/mmc_format_progress 0 -i
vconftool set -t int memory/sysman/mmc_err_status 0 -i
-vconftool set -t int memory/sysman/power_off 0 -u 5000 -i -f
+vconftool set -t int memory/sysman/power_off 0 -g $users_gid -i -f
vconftool set -t int memory/sysman/battery_level_status -1 -i
vconftool set -t string memory/private/sysman/added_storage_uevent "" -i
-vconftool set -t string memory/private/sysman/removed_storage_uevent "" -u 5000 -i
+vconftool set -t string memory/private/sysman/removed_storage_uevent "" -g $users_gid -i
vconftool set -t int memory/sysman/hdmi 0 -i
#db type vconf key init
vconftool set -t int db/sysman/mmc_dev_changed 0 -i
-vconftool set -t int memory/pm/state 0 -i -g 5000
+vconftool set -t int memory/pm/state 0 -i -g $users_gid
vconftool set -t int memory/pm/battery_timetofull -1 -i
vconftool set -t int memory/pm/battery_timetoempty -1 -i
-vconftool set -t int memory/pm/sip_status 0 -i -g 5000
-vconftool set -t int memory/pm/custom_brightness_status 0 -i -g 5000
+vconftool set -t int memory/pm/sip_status 0 -i -g $users_gid
+vconftool set -t int memory/pm/custom_brightness_status 0 -i -g $users_gid
vconftool set -t bool memory/pm/brt_changed_lpm 0 -i
-vconftool set -t int memory/pm/current_brt 60 -i -g 5000
+vconftool set -t int memory/pm/current_brt 60 -i -g $users_gid
heynotitool set system_wakeup
heynotitool set pm_event
SET(LIBDIR "\${prefix}/lib")
SET(INCLUDEDIR "\${prefix}/include")
SET(VERSION 0.1.9)
+
INCLUDE(FindPkgConfig)
+pkg_check_modules(deep_pkgs REQUIRED libtzplatform-config)
+
FOREACH(flag ${deep_pkgs_CFLAGS})
SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}")
ENDFOREACH(flag)
#include <stdio.h>
#include <string.h>
#include <limits.h>
+#include <tzplatform_config.h>
-#define PM_EVENT_NOTI_PATH "/opt/share/noti/pm_event"
+#define PM_EVENT_NOTI_PATH tzplatform_mkpath(TZ_SYS_SHARE, "noti/pm_event")
#define PM_EVENT_CMD_LENGTH 50
int main(int argc, char *argv[])
#!/bin/bash
+source /etc/tizen-platform.conf
MOUNT_DIRECTORY=$1
-find $MOUNT_DIRECTORY -type d | xargs chsmack -a 'system::ext_storage' -t
-find $MOUNT_DIRECTORY -type f | xargs chsmack -a 'system::ext_storage'
+find $MOUNT_DIRECTORY -type d | xargs chsmack -a 'System::Shared' -t
+find $MOUNT_DIRECTORY -type f | xargs chsmack -a 'System::Shared'
find $MOUNT_DIRECTORY -type f | xargs chmod -x
-find $MOUNT_DIRECTORY | xargs chown app:app
+find $MOUNT_DIRECTORY | xargs chown $TZ_USER_NAME:$TZ_SYS_USER_GROUP
find $MOUNT_DIRECTORY | xargs chmod 777
#include "core/log.h"
#include "core/launch.h"
#include "core/devices.h"
+#include <tzplatform_config.h>
#define CRASH_WORKER_MAX 3
#define CRASH_PID_MAX 7
#define CRASH_PROCESSNAME_MAX NAME_MAX
#define CRASH_EXEPATH_MAX NAME_MAX
#define CRASH_ARG_MAX (CRASH_PROCESSNAME_MAX + CRASH_EXEPATH_MAX + CRASH_TIME_MAX + CRASH_PID_MAX + CRASH_MODE_MAX + CRASH_VERIFY_MAX)
-#define CRASH_NOTI_DIR "/opt/share/crash"
+#define CRASH_NOTI_DIR tzplatform_mkpath(TZ_SYS_SHARE, "crash")
#define CRASH_NOTI_FILE "curbs.log"
-#define CRASH_NOTI_PATH CRASH_NOTI_DIR"/"CRASH_NOTI_FILE
-#define CRASH_COREDUMP_PATH "/opt/usr/share/crash/core"
-#define CRASH_DUMP_PATH "/opt/usr/share/crash/dump"
-#define CRASH_INFO_PATH "/opt/share/crash/info"
+#define CRASH_NOTI_PATH tzplatform_mkpath(TZ_SYS_SHARE, "crash/"CRASH_NOTI_FILE)
+#define CRASH_COREDUMP_PATH tzplatform_mkpath(TZ_USER_SHARE, "crash/core")
+#define CRASH_DUMP_PATH tzplatform_mkpath(TZ_USER_SHARE, "crash/dump")
+#define CRASH_INFO_PATH tzplatform_mkpath(TZ_SYS_SHARE, "crash/info")
#define CRASH_WORKER_PATH "/usr/bin/crash-worker"
-#define CRASH_POPUP_PATH "/usr/apps/org.tizen.crash-popup/bin/crash-popup"
+#define CRASH_POPUP_PATH tzplatform_mkpath(TZ_SYS_RO_APP, "org.tizen.crash-popup/bin/crash-popup")
static int noti_fd;
static int add_noti(void);
#include <Ecore.h>
#include <unistd.h>
+#include <tzplatform_config.h>
enum {
WIN_CREATE = 0,
#define OOMADJ_APP_LIMIT (-16)
#define MOVINAND_MOUNT_POINT "/opt/media"
-#define MMC_MOUNT_POINT "/opt/storage/sdcard"
+#define MMC_MOUNT_POINT tzplatform_mkpath(TZ_SYS_STORAGE,"sdcard")
struct ui_contention_info {
#include "core/devices.h"
#include "core/device-notifier.h"
#include "core/udev.h"
+#include <tzplatform_config.h>
#define USB_CON_PIDFILE "/var/run/.system_server.pid"
#define PM_STATE_LOG_FILE "/var/log/pm_state.log"
#define PM_WAKEUP_NOTI_NAME "system_wakeup"
#define PM_EVENT_NOTI_NAME "pm_event"
-#define PM_EVENT_NOTI_PATH "/opt/share/noti/"PM_EVENT_NOTI_NAME
+#define PM_EVENT_NOTI_PATH tzplatform_mkpath(TZ_SYS_SHARE,"noti/"PM_EVENT_NOTI_NAME)
/**
* @addtogroup POWER_MANAGER
#include "core/common.h"
#include "core/devices.h"
#include "mmc-handler.h"
+#include <tzplatform_config.h>
#define VCONFKEY_INTERNAL_PRIVATE_MMC_ID "db/private/sysman/mmc_device_id"
#define VCONFKEY_SYSMAN_MMC_INIT -1
#define PREDEF_UNMOUNT_MMC "unmountmmc"
#define PREDEF_FORMAT_MMC "formatmmc"
-#define MMC_PARENT_PATH "/opt/storage"
+#define MMC_PARENT_PATH tzplatform_getenv(TZ_SYS_STORAGE)
#define MMC_DEV "/dev/mmcblk"
#define SMACKFS_MAGIC 0x43415d53
#include "core/device-handler.h"
#include "core/common.h"
#include "core/devices.h"
+#include <tzplatform_config.h>
#define BUF_LEN 20
#define SMACKFS_MOUNT_OPT "smackfsroot=*,smackfsdef=*"
-#define MMC_MOUNT_POINT "/opt/storage/sdcard"
+#define MMC_MOUNT_POINT tzplatform_getenv(TZ_SYS_STORAGE)
struct mmc_list {
struct mmc_list *prev, *next;
#include <stdio.h>
+#include <tzplatform_config.h>
#include <stdbool.h>
#include <unistd.h>
#include <sys/types.h>
#endif
static const char default_rtc0[] = "/dev/rtc0";
static const char default_rtc1[] = "/dev/rtc1";
-static const char default_localtime[] = "/opt/etc/localtime";
+static const char default_localtime[18];
static const time_t default_time = 2147483645; // max(32bit) -3sec
static Ecore_Fd_Handler *tfdh = NULL; // tfd change noti
struct stat sts;
time_t now;
struct tm *ts;
+ strcpy(default_localtime, tzplatform_mkpath(TZ_SYS_ETC, "localtime"));
const char *sympath = default_localtime;
if (str == NULL)
INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR})
INCLUDE(FindPkgConfig)
-pkg_check_modules(pkgs REQUIRED vconf dlog)
+pkg_check_modules(pkgs REQUIRED vconf dlog libtzplatform-config)
FOREACH(flag ${pkgs_CFLAGS})
SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}")
#!/bin/sh
-
+source /etc/tizen-platform.conf
# Don't regist processes on hibernation capturing sequence
-if [ -e /opt/etc/.hib_capturing ] ; then
+if [ -e $TZ_SYS_ETC/.hib_capturing ] ; then
exit 0
-elif [ -e /opt/etc/.hib_capturing_firstboot ]; then
+elif [ -e $TZ_SYS_ETC/.hib_capturing_firstboot ]; then
exit 0
fi
+++ /dev/null
-#!/bin/bash
-MOUNT_DIRECTORY=$1
-find $MOUNT_DIRECTORY -type d | xargs chsmack -a 'system::ext_storage' -t
-find $MOUNT_DIRECTORY -type f | xargs chsmack -a 'system::ext_storage'
-find $MOUNT_DIRECTORY -type f | xargs chmod -x
-find $MOUNT_DIRECTORY | xargs chown app:app
-find $MOUNT_DIRECTORY | xargs chmod 777
#!/bin/sh
-
+source /etc/tizen-platform.conf
# Don't regist processes on hibernation capturing sequence
-if [ -e /opt/etc/.hib_capturing ] ; then
+if [ -e $TZ_SYS_ETC/.hib_capturing ] ; then
exit 0
-elif [ -e /opt/etc/.hib_capturing_firstboot ]; then
+elif [ -e $TZ_SYS_ETC/.hib_capturing_firstboot ]; then
exit 0
fi