## Config ##
INSTALL(FILES ${CMAKE_SOURCE_DIR}/tts-config.xml DESTINATION ${TZ_SYS_RO_SHARE}/voice/tts/1.0)
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/tts-server.conf DESTINATION /etc/dbus-1/session.d)
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/tts-server.conf DESTINATION /etc/dbus-1/system.d)
## Dbus service ##
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/org.tizen.voice.ttsserver.service DESTINATION ${TZ_SYS_RO_SHARE}/dbus-1/services)
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/org.tizen.voice.ttsnotiserver.service DESTINATION ${TZ_SYS_RO_SHARE}/dbus-1/services)
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/org.tizen.voice.ttssrserver.service DESTINATION ${TZ_SYS_RO_SHARE}/dbus-1/services)
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/org.tizen.voice.ttsinterruptserver.service DESTINATION ${TZ_SYS_RO_SHARE}/dbus-1/services)
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/org.tizen.voice.ttsserver.service DESTINATION ${TZ_SYS_RO_SHARE}/dbus-1/system-services)
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/org.tizen.voice.ttsnotiserver.service DESTINATION ${TZ_SYS_RO_SHARE}/dbus-1/system-services)
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/org.tizen.voice.ttssrserver.service DESTINATION ${TZ_SYS_RO_SHARE}/dbus-1/system-services)
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/org.tizen.voice.ttsinterruptserver.service DESTINATION ${TZ_SYS_RO_SHARE}/dbus-1/system-services)
## voice_getengine ##
IF("${ARCH}" MATCHES "^arm.*")
dbus_error_init(&err);
/* connect to the DBUS system bus, and check for errors */
- g_conn_sender = dbus_bus_get_private(DBUS_BUS_SESSION, &err);
+ g_conn_sender = dbus_bus_get_private(DBUS_BUS_SYSTEM, &err);
if (dbus_error_is_set(&err)) {
SLOG(LOG_ERROR, TAG_TTSC, "[ERROR] Dbus Connection Error (%s)", err.message);
dbus_error_free(&err);
dbus_connection_set_exit_on_disconnect(g_conn_sender, false);
- g_conn_listener = dbus_bus_get_private(DBUS_BUS_SESSION, &err);
+ g_conn_listener = dbus_bus_get_private(DBUS_BUS_SYSTEM, &err);
if (dbus_error_is_set(&err)) {
SLOG(LOG_ERROR, TAG_TTSC, "[ERROR] Dbus Connection Error (%s)", err.message);
dbus_error_free(&err);
Name=org.tizen.voice.ttsinterruptserver
Exec=/bin/sh -c "voice_getengine get system db/voice/tts/engine/default | awk '{print$5}' | xargs -t -i launch_app {}-interrupt mode interrupt"
#Exec=/bin/sh -c "launch_app org.tizen.tts-engine-default-noti mode noti"
+User=system
+Group=system
\ No newline at end of file
#Exec=/bin/sh -c "buxton2ctl get user db/voice/tts_engine | awk '{print$5}' | xargs -t -i launch_app {}-noti"
#Exec=/bin/sh -c "launch_app org.tizen.tts-engine-default-noti mode noti"
Exec=/bin/sh -c "launch_app org.tizen.tts-engine-vd-interrupt mode interrupt"
+User=system
+Group=system
\ No newline at end of file
Name=org.tizen.voice.ttsnotiserver
Exec=/bin/sh -c "voice_getengine get system db/voice/tts/engine/default | awk '{print$5}' | xargs -t -i launch_app {}-noti mode noti"
#Exec=/bin/sh -c "launch_app org.tizen.tts-engine-default-noti mode noti"
+User=system
+Group=system
\ No newline at end of file
#Exec=/bin/sh -c "buxton2ctl get user db/voice/tts_engine | awk '{print$5}' | xargs -t -i launch_app {}-noti"
#Exec=/bin/sh -c "launch_app org.tizen.tts-engine-default-noti mode noti"
Exec=/bin/sh -c "launch_app org.tizen.tts-engine-vd-noti mode noti"
+User=system
+Group=system
\ No newline at end of file
Name=org.tizen.voice.ttsserver
Exec=/bin/sh -c "voice_getengine get system db/voice/tts/engine/default | awk '{print$5}' | xargs -t -i launch_app {}"
#Exec=/bin/sh -c "launch_app org.tizen.tts-engine-default"
+User=system
+Group=system
\ No newline at end of file
#Exec=/bin/sh -c "buxton2ctl get user db/voice/tts_engine | awk '{print$5}' | xargs -t -i launch_app {}"
#Exec=/bin/sh -c "launch_app org.tizen.tts-engine-default"
Exec=/bin/sh -c "launch_app org.tizen.tts-engine-vd"
+User=system
+Group=system
\ No newline at end of file
Name=org.tizen.voice.ttssrserver
Exec=/bin/sh -c "voice_getengine get system db/voice/tts/engine/default | awk '{print$5}' | xargs -t -i launch_app {}-sr mode sr"
#Exec=/bin/sh -c "launch_app org.tizen.tts-engine-default-sr mode sr"
+User=system
+Group=system
\ No newline at end of file
#Exec=/bin/sh -c "buxton2ctl get user db/voice/tts_engine | awk '{print$5}' | xargs -t -i launch_app {}-sr"
#Exec=/bin/sh -c "launch_app org.tizen.tts-engine-default-sr mode sr"
Exec=/bin/sh -c "launch_app org.tizen.tts-engine-vd-sr mode sr"
+User=system
+Group=system
\ No newline at end of file
%defattr(-,root,root,-)
%{_libdir}/lib*.so
%{TZ_SYS_RO_SHARE}/voice/tts/1.0/tts-config.xml
-%{TZ_SYS_RO_SHARE}/dbus-1/services/org.tizen.voice.ttsserver.service
-%{TZ_SYS_RO_SHARE}/dbus-1/services/org.tizen.voice.ttsnotiserver.service
-%{TZ_SYS_RO_SHARE}/dbus-1/services/org.tizen.voice.ttssrserver.service
-%{TZ_SYS_RO_SHARE}/dbus-1/services/org.tizen.voice.ttsinterruptserver.service
+%{TZ_SYS_RO_SHARE}/dbus-1/system-services/org.tizen.voice.ttsserver.service
+%{TZ_SYS_RO_SHARE}/dbus-1/system-services/org.tizen.voice.ttsnotiserver.service
+%{TZ_SYS_RO_SHARE}/dbus-1/system-services/org.tizen.voice.ttssrserver.service
+%{TZ_SYS_RO_SHARE}/dbus-1/system-services/org.tizen.voice.ttsinterruptserver.service
#%{TZ_SYS_RO_SHARE}/voice/test/tts-test
%{_bindir}/voice_getengine
%{TZ_SYS_RO_ETC}/package-manager/parserlib/metadata/libtts-engine-parser.so*
#%{TZ_SYS_RO_ETC}/package-manager/parserlib/metadata/libtts-engine-language-pack-parser.so*
-/etc/dbus-1/session.d/tts-server.conf
+/etc/dbus-1/system.d/tts-server.conf
%files devel
%manifest %{name}-devel.manifest
int ret;
/* Create connection for sender */
- g_conn_sender = dbus_bus_get_private(DBUS_BUS_SESSION, &err);
+ g_conn_sender = dbus_bus_get_private(DBUS_BUS_SYSTEM, &err);
if (dbus_error_is_set(&err)) {
SLOG(LOG_ERROR, tts_tag(), "[Dbus ERROR] Fail dbus_bus_get : %s", err.message);
dbus_error_free(&err);
dbus_connection_set_exit_on_disconnect(g_conn_sender, false);
/* connect to the bus and check for errors */
- g_conn_listener = dbus_bus_get_private(DBUS_BUS_SESSION, &err);
+ g_conn_listener = dbus_bus_get_private(DBUS_BUS_SYSTEM, &err);
if (dbus_error_is_set(&err)) {
SLOG(LOG_ERROR, tts_tag(), "[Dbus ERROR] Fail dbus_bus_get : %s", err.message);
dbus_error_free(&err);
"http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
<busconfig>
-<!-- root can own the service -->
- <policy context="default">
- <allow own_prefix="org.tizen.tts"/>
+ <policy user="root">
<allow send_destination="org.tizen.tts"/>
-
- <allow own="org.tizen.voice.ttsserver"/>
<allow send_destination="org.tizen.voice.ttsserver"/>
-
- <allow own="org.tizen.voice.ttsnotiserver"/>
<allow send_destination="org.tizen.voice.ttsnotiserver"/>
+ <allow send_destination="org.tizen.voice.ttssrserver"/>
+ <allow send_destination="org.tizen.voice.ttsinterruptserver"/>
+ </policy>
- <allow own="org.tizen.voice.ttssrserver"/>
+ <policy group="users">
+ <allow send_destination="org.tizen.tts"/>
+ <allow send_destination="org.tizen.voice.ttsserver"/>
+ <allow send_destination="org.tizen.voice.ttsnotiserver"/>
<allow send_destination="org.tizen.voice.ttssrserver"/>
+ <allow send_destination="org.tizen.voice.ttsinterruptserver"/>
+ </policy>
+ <policy user="system">
+ <allow own_prefix="org.tizen.tts"/>
+ <allow own="org.tizen.voice.ttsserver"/>
+ <allow own="org.tizen.voice.ttsnotiserver"/>
+ <allow own="org.tizen.voice.ttssrserver"/>
<allow own="org.tizen.voice.ttsinterruptserver"/>
- <allow send_destination="org.tizen.voice.ttsinterruptserver"/>
+ </policy>
+
+ <policy context="default">
+ <deny send_destination="org.tizen.tts"/>
+ <deny own_prefix="org.tizen.tts"/>
+
+ <deny send_destination="org.tizen.voice.ttsserver"/>
+ <deny own="org.tizen.voice.ttsserver"/>
+
+ <deny send_destination="org.tizen.voice.ttsnotiserver"/>
+ <deny own="org.tizen.voice.ttsnotiserver"/>
+
+ <deny send_destination="org.tizen.voice.ttssrserver"/>
+ <deny own="org.tizen.voice.ttssrserver"/>
+
+ <deny send_destination="org.tizen.voice.ttsinterruptserver"/>
+ <deny own="org.tizen.voice.ttsinterruptserver"/>
</policy>
</busconfig>