Name: stt
Summary: Speech To Text client library and daemon
-Version: 0.2.53
+Version: 0.2.56
Release: 1
-Group: Graphics & UI Framework/Libraries
+Group: Graphics & UI Framework/Voice Framework
License: Apache-2.0
Source0: %{name}-%{version}.tar.gz
Source1001: %{name}.manifest
BuildRequires: pkgconfig(capi-media-audio-io)
BuildRequires: pkgconfig(capi-media-wav-player)
BuildRequires: pkgconfig(capi-system-info)
+BuildRequires: pkgconfig(cynara-client)
+BuildRequires: pkgconfig(cynara-session)
BuildRequires: pkgconfig(dbus-1)
BuildRequires: pkgconfig(dlog)
BuildRequires: pkgconfig(ecore)
BuildRequires: pkgconfig(libtzplatform-config)
BuildRequires: pkgconfig(libxml-2.0)
BuildRequires: pkgconfig(vconf)
-
+%if "%{PRODUCT_TYPE}" == "TV"
+BuildRequires: pkgconfig(capi-network-bluetooth)
+%endif
BuildRequires: cmake
export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE"
export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
+%if "%{PRODUCT_TYPE}" == "TV"
+export CFLAGS="$CFLAGS -DTV_PRODUCT"
+cmake . -DCMAKE_INSTALL_PREFIX=/usr -DLIBDIR=%{_libdir} -DINCLUDEDIR=%{_includedir} \
+ -DTZ_SYS_RO_SHARE=%TZ_SYS_RO_SHARE -DTZ_SYS_BIN=%TZ_SYS_BIN -D_TV_PRODUCT=TRUE
+%else
+cmake . -DCMAKE_INSTALL_PREFIX=/usr -DLIBDIR=%{_libdir} -DINCLUDEDIR=%{_includedir} \
+ -DTZ_SYS_RO_SHARE=%TZ_SYS_RO_SHARE -DTZ_SYS_BIN=%TZ_SYS_BIN
+%endif
-
-cmake . -DCMAKE_INSTALL_PREFIX=/usr -DLIBDIR=%{_libdir} -DINCLUDEDIR=%{_includedir}
make %{?jobs:-j%jobs}
%install
rm -rf %{buildroot}
-mkdir -p %{buildroot}/usr/share/license
-install LICENSE.APLv2 %{buildroot}/usr/share/license/%{name}
+mkdir -p %{buildroot}%{TZ_SYS_RO_SHARE}/license
+install LICENSE.APLv2 %{buildroot}%{TZ_SYS_RO_SHARE}/license/%{name}
+
+%if "%{PRODUCT_TYPE}" == "TV"
+mv -f org.tizen.voice.sttserver.tv.service org.tizen.voice.sttserver.service
+%endif
%make_install
-%post
+%post
/sbin/ldconfig
-mkdir -p /usr/lib/voice
+mkdir -p %{_libdir}/voice/
-mkdir -p /usr/share/voice
-
-mkdir -p /opt/home/app/.voice
-chown 5000:5000 /opt/home/app/.voice
-
-mkdir -p /opt/usr/data/voice/stt/1.0
-chown 5000:5000 /opt/usr/data/voice
-chown 5000:5000 /opt/usr/data/voice/stt
-chown 5000:5000 /opt/usr/data/voice/stt/1.0
+mkdir -p %{TZ_SYS_RO_SHARE}/voice/test
%postun -p /sbin/ldconfig
-/usr/bin/vconftool set -t string db/voice_input/language "auto" -g 5000 -f -s system::vconf_inhouse
-
%files
%manifest %{name}.manifest
%license LICENSE.APLv2
%defattr(-,root,root,-)
-%{_libdir}/libstt.so
-%{_libdir}/libstt_file.so
-%{_libdir}/libstt_setting.so
-/usr/lib/voice/stt/1.0/stt-config.xml
-%{_bindir}/stt-daemon
-/opt/usr/devel/bin/stt-test
-/usr/share/license/%{name}
+%{_libdir}/lib*.so
+/etc/dbus-1/session.d/stt-server.conf
+%{TZ_SYS_RO_SHARE}/upgrade/scripts/500.stt_upgrade_24to30.sh
+%{TZ_SYS_RO_SHARE}/voice/stt/1.0/stt-config.xml
+%{TZ_SYS_RO_SHARE}/dbus-1/services/org.tizen.voice.sttserver.service
+%{TZ_SYS_RO_SHARE}/voice/test/stt-test
+%{TZ_SYS_RO_SHARE}/license/%{name}
%files devel
%manifest %{name}-devel.manifest
%files engine-devel
%defattr(-,root,root,-)
%{_libdir}/pkgconfig/stt-engine.pc
-%{_includedir}/sttp.h
+%{_includedir}/stte.h