Change VC engine as a service app 26/170926/1
authorsooyeon.kim <sooyeon.kim@samsung.com>
Fri, 23 Feb 2018 07:39:47 +0000 (16:39 +0900)
committersooyeon.kim <sooyeon.kim@samsung.com>
Fri, 23 Feb 2018 07:40:45 +0000 (16:40 +0900)
Change-Id: Ic05bb2058f1a9afb1d9ab7b4c81a51abee2b71c4
Signed-off-by: sooyeon.kim <sooyeon.kim@samsung.com>
CMakeLists.txt
bin/aarch64/org.tizen.vc-engine-default [moved from lib/aarch64/libvc-engine-default.so with 87% similarity]
bin/arm/org.tizen.vc-engine-default [moved from lib/arm/libvc-engine-default.so with 88% similarity]
bin/i586/org.tizen.vc-engine-default [moved from lib/i586/libvc-engine-default.so with 87% similarity]
bin/x86_64/org.tizen.vc-engine-default [moved from lib/x86_64/libvc-engine-default.so with 85% similarity]
org.tizen.vc-engine-default.xml [new file with mode: 0755]
packaging/org.tizen.vc-engine-default.manifest [moved from packaging/vc-engine-default.manifest with 100% similarity]
packaging/org.tizen.vc-engine-default.spec [new file with mode: 0644]
packaging/vc-engine-default.spec [deleted file]

index e5817a5..9b4b133 100644 (file)
@@ -1,22 +1,27 @@
 CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
-PROJECT(vc-engine-default C)
+PROJECT(org.tizen.vc-engine-default C)
 
-SET(VERSION 0.2.0)
+SET(VERSION 1.0.1)
 
 FIND_PROGRAM(UNAME NAMES uname)
 EXEC_PROGRAM("${UNAME}" ARGS "-m" OUTPUT_VARIABLE "ARCH")
 IF("${ARCH}" MATCHES "^arm.*")
 SET(INSTALL_ARCH arm)
+INSTALL(PROGRAMS ${CMAKE_SOURCE_DIR}/bin/arm/org.tizen.vc-engine-default DESTINATION ${APP_INSTALL_PREFIX}/bin/)
 ELSEIF("${ARCH}" MATCHES "^i586.*")
 SET(INSTALL_ARCH i586)
+INSTALL(PROGRAMS ${CMAKE_SOURCE_DIR}/bin/i586/org.tizen.vc-engine-default DESTINATION ${APP_INSTALL_PREFIX}/bin/)
 ELSEIF("${ARCH}" MATCHES "^i686.*")
 SET(INSTALL_ARCH i586)
+INSTALL(PROGRAMS ${CMAKE_SOURCE_DIR}/bin/i586/org.tizen.vc-engine-default DESTINATION ${APP_INSTALL_PREFIX}/bin/)
 ELSEIF("${ARCH}" MATCHES "^aarch64.*")
 SET(INSTALL_ARCH aarch64)
+INSTALL(PROGRAMS ${CMAKE_SOURCE_DIR}/bin/aarch64/org.tizen.vc-engine-default DESTINATION ${APP_INSTALL_PREFIX}/bin/)
 ELSEIF("${ARCH}" MATCHES "^x86_64.*")
 SET(INSTALL_ARCH x86_64)
+INSTALL(PROGRAMS ${CMAKE_SOURCE_DIR}/bin/x86_64/org.tizen.vc-engine-default DESTINATION ${APP_INSTALL_PREFIX}/bin/)
 ENDIF()
 
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/lib/${INSTALL_ARCH}/libvc-engine-default.so DESTINATION ${TZ_SYS_RO_SHARE}/voice/vc/1.0/engine/ COMPONENT RuntimeLibraries)
 INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/engine_data/ DESTINATION ${TZ_SYS_RO_SHARE}/voice/vc/engine_data)
 INSTALL(FILES ${CMAKE_SOURCE_DIR}/vc-default-info.xml DESTINATION ${TZ_SYS_RO_SHARE}/voice/vc/1.0/engine-info/)
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/org.tizen.vc-engine-default.xml DESTINATION ${APP_MANIFESTDIR})
similarity index 87%
rename from lib/aarch64/libvc-engine-default.so
rename to bin/aarch64/org.tizen.vc-engine-default
index 6554478..a254ebb 100755 (executable)
Binary files a/lib/aarch64/libvc-engine-default.so and b/bin/aarch64/org.tizen.vc-engine-default differ
similarity index 88%
rename from lib/arm/libvc-engine-default.so
rename to bin/arm/org.tizen.vc-engine-default
index 43a923f..58cf32c 100755 (executable)
Binary files a/lib/arm/libvc-engine-default.so and b/bin/arm/org.tizen.vc-engine-default differ
similarity index 87%
rename from lib/i586/libvc-engine-default.so
rename to bin/i586/org.tizen.vc-engine-default
index d7196bb..4fb2946 100755 (executable)
Binary files a/lib/i586/libvc-engine-default.so and b/bin/i586/org.tizen.vc-engine-default differ
similarity index 85%
rename from lib/x86_64/libvc-engine-default.so
rename to bin/x86_64/org.tizen.vc-engine-default
index a54447f..5bf13f0 100755 (executable)
Binary files a/lib/x86_64/libvc-engine-default.so and b/bin/x86_64/org.tizen.vc-engine-default differ
diff --git a/org.tizen.vc-engine-default.xml b/org.tizen.vc-engine-default.xml
new file mode 100755 (executable)
index 0000000..139ea13
--- /dev/null
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<manifest xmlns="http://tizen.org/ns/packages" api-version="5.0" package="org.tizen.vc-engine-default" version="1.0.1">
+    <profile name="mobile"/>
+    <service-application appid="org.tizen.vc-engine-default" exec="org.tizen.vc-engine-default" multiple="false" nodisplay="true" taskmanage="false" type="capp">
+        <label>org.tizen.vc-engine-default</label>
+        <icon>vc-engine-default.png</icon>
+       <background-category value="media"/>
+       <background-category value="background-network"/>
+    </service-application>
+    <privileges>
+        <privilege>http://tizen.org/privilege/network.get</privilege>
+        <privilege>http://tizen.org/privilege/recorder</privilege>
+    </privileges>
+</manifest>
diff --git a/packaging/org.tizen.vc-engine-default.spec b/packaging/org.tizen.vc-engine-default.spec
new file mode 100644 (file)
index 0000000..3807d33
--- /dev/null
@@ -0,0 +1,51 @@
+Name:       org.tizen.vc-engine-default
+Summary:    Voice control default engine service app
+Version:    1.0.1
+Release:    1
+Group:      Graphics & UI Framework/Voice Framework
+License:    Flora-1.1
+Source0:    %{name}-%{version}.tar.gz
+Source1001: %{name}.manifest
+BuildRequires:  cmake
+BuildRequires:  pkgconfig(libtzplatform-config)
+
+%description
+Description: Voice control default engine service app
+
+%prep
+%setup -q
+cp %{SOURCE1001} .
+
+%define APP_PREFIX %{TZ_SYS_RO_APP}/%{name}
+%define MANIFESTDIR %{TZ_SYS_RO_PACKAGES}
+
+cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DLIBDIR=%{_libdir} -DTZ_SYS_RO_SHARE=%TZ_SYS_RO_SHARE \
+       -DAPP_INSTALL_PREFIX=%{APP_PREFIX} -DAPP_MANIFESTDIR=%{MANIFESTDIR}
+
+%build
+export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE"
+export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
+export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
+make %{?jobs:-j%jobs}
+
+%install
+rm -rf %{buildroot}
+%make_install
+
+%post
+/sbin/ldconfig
+exit 0
+
+%postun
+/sbin/ldconfig
+exit 0
+
+%files
+%license LICENSE
+%manifest %{name}.manifest
+%defattr(-,root,root,-)
+%{APP_PREFIX}/bin/*
+%{MANIFESTDIR}/org.tizen.vc-engine-default.xml
+#%{TZ_SYS_RO_SHARE}/voice/vc/1.0/engine/lib*.so
+%{TZ_SYS_RO_SHARE}/voice/vc/1.0/engine-info/vc-default-info.xml
+%{TZ_SYS_RO_SHARE}/voice/vc/engine_data/*
diff --git a/packaging/vc-engine-default.spec b/packaging/vc-engine-default.spec
deleted file mode 100644 (file)
index adca64e..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-Name:       vc-engine-default
-Summary:    Voice control default engine library
-Version:    0.2.1
-Release:    1
-Group:      Graphics & UI Framework/Voice Framework
-License:    Flora-1.1
-Source0:    %{name}-%{version}.tar.gz
-Source1001: %{name}.manifest
-BuildRequires:  cmake
-BuildRequires:  pkgconfig(libtzplatform-config)
-
-%description
-Description: Voice control default engine library
-
-%prep
-%setup -q
-cp %{SOURCE1001} .
-cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DLIBDIR=%{_libdir} -DTZ_SYS_RO_SHARE=%TZ_SYS_RO_SHARE
-
-%build
-make %{?jobs:-j%jobs}
-
-%install
-rm -rf %{buildroot}
-%make_install
-
-%files
-%license LICENSE
-%manifest vc-engine-default.manifest
-%defattr(-,root,root,-)
-%{TZ_SYS_RO_SHARE}/voice/vc/1.0/engine/lib*.so
-%{TZ_SYS_RO_SHARE}/voice/vc/1.0/engine-info/vc-default-info.xml
-%{TZ_SYS_RO_SHARE}/voice/vc/engine_data/*
\ No newline at end of file