Add engine app info parser
[platform/core/uifw/stt.git] / packaging / stt.spec
1 Name:       stt
2 Summary:    Speech To Text client library and daemon
3 Version:    0.2.56
4 Release:    1
5 Group:      Graphics & UI Framework/Voice Framework
6 License:    Apache-2.0
7 Source0:    %{name}-%{version}.tar.gz
8 Source1001: %{name}.manifest
9 Source1002: %{name}-devel.manifest
10 Requires(post): /sbin/ldconfig
11 Requires(postun): /sbin/ldconfig
12 BuildRequires:  pkgconfig(aul)
13 BuildRequires:  pkgconfig(capi-appfw-app-manager)
14 BuildRequires:  pkgconfig(capi-base-common)
15 BuildRequires:  pkgconfig(capi-media-audio-io)
16 BuildRequires:  pkgconfig(capi-media-wav-player)
17 BuildRequires:  pkgconfig(capi-system-info)
18 BuildRequires:  pkgconfig(cynara-client)
19 BuildRequires:  pkgconfig(cynara-session)
20 BuildRequires:  pkgconfig(dbus-1)
21 BuildRequires:  pkgconfig(dlog)
22 BuildRequires:  pkgconfig(ecore)
23 BuildRequires:  pkgconfig(glib-2.0)
24 BuildRequires:  pkgconfig(libtzplatform-config)
25 BuildRequires:  pkgconfig(libxml-2.0)
26 BuildRequires:  pkgconfig(pkgmgr)
27 BuildRequires:  pkgconfig(pkgmgr-info)
28 BuildRequires:  pkgconfig(pkgmgr-installer)
29 BuildRequires:  pkgconfig(vconf)
30 %if "%{PRODUCT_TYPE}" == "TV"
31 BuildRequires:  pkgconfig(capi-network-bluetooth)
32 %endif
33
34 BuildRequires:  cmake
35
36 %description
37 Speech To Text client library and daemon.
38
39
40 %package devel
41 Summary:    Speech To Text header files for STT development
42 Group:      Graphics & UI Framework/Development
43 Requires:   %{name} = %{version}-%{release}
44
45 %package file-devel
46 Summary:    File To Text header files for STT FILE development
47 Group:      Graphics & UI Framework/Development
48 Requires:   %{name} = %{version}-%{release}
49
50 %package setting-devel
51 Summary:    Speech To Text setting header files for STT development
52 Group:      Graphics & UI Framework/Development
53 Requires:   %{name} = %{version}-%{release}
54
55 %package engine-devel
56 Summary:    Speech To Text engine header files for STT development
57 Group:      Graphics & UI Framework/Development
58 Requires:   %{name} = %{version}-%{release}
59
60 %description devel
61 Speech To Text header files for STT development.
62
63 %description file-devel
64 File To Text header files for STT FILE development.
65
66 %description setting-devel
67 Speech To Text setting header files for STT development.
68
69 %description engine-devel
70 Speech To Text engine header files for STT development.
71
72 %prep
73 %setup -q -n %{name}-%{version}
74 cp %{SOURCE1001} %{SOURCE1002} .
75
76
77 %build
78 export CFLAGS="$CFLAGS -DTIZEN_ENGINEER_MODE"
79 export CXXFLAGS="$CXXFLAGS -DTIZEN_ENGINEER_MODE"
80 export FFLAGS="$FFLAGS -DTIZEN_ENGINEER_MODE"
81
82 export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE"
83 export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
84 export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
85 %if "%{PRODUCT_TYPE}" == "TV"
86 export CFLAGS="$CFLAGS -DTV_PRODUCT"
87 cmake . -DCMAKE_INSTALL_PREFIX=/usr -DLIBDIR=%{_libdir} -DINCLUDEDIR=%{_includedir} \
88         -DTZ_SYS_RO_SHARE=%TZ_SYS_RO_SHARE -DTZ_SYS_BIN=%TZ_SYS_BIN -D_TV_PRODUCT=TRUE
89 %else
90 cmake . -DCMAKE_INSTALL_PREFIX=/usr -DLIBDIR=%{_libdir} -DINCLUDEDIR=%{_includedir} \
91         -DTZ_SYS_RO_SHARE=%TZ_SYS_RO_SHARE -DTZ_SYS_BIN=%TZ_SYS_BIN
92 %endif
93
94 make %{?jobs:-j%jobs}
95
96 %install
97 rm -rf %{buildroot}
98 mkdir -p %{buildroot}%{TZ_SYS_RO_SHARE}/license
99 install LICENSE.APLv2 %{buildroot}%{TZ_SYS_RO_SHARE}/license/%{name}
100
101 %make_install
102
103 %post
104 /sbin/ldconfig
105
106 mkdir -p %{_libdir}/voice/
107
108 mkdir -p %{TZ_SYS_RO_SHARE}/voice/test
109
110
111 %postun -p /sbin/ldconfig
112
113 %files
114 %manifest %{name}.manifest
115 %license LICENSE.APLv2
116 %defattr(-,root,root,-)
117 %{_libdir}/lib*.so
118 /etc/dbus-1/session.d/stt-server.conf
119 %{TZ_SYS_RO_SHARE}/upgrade/scripts/500.stt_upgrade_24to30.sh
120 %{TZ_SYS_RO_SHARE}/voice/stt/1.0/stt-config.xml
121 %{TZ_SYS_RO_SHARE}/dbus-1/services/org.tizen.voice*
122 %{TZ_SYS_RO_SHARE}/voice/test/stt-test
123 %{TZ_SYS_RO_SHARE}/license/%{name}
124 %{TZ_SYS_RO_ETC}/package-manager/parserlib/metadata/libstt-engine-parser.so*
125
126 %files devel
127 %manifest %{name}-devel.manifest
128 %defattr(-,root,root,-)
129 %{_libdir}/pkgconfig/stt.pc
130 %{_includedir}/stt.h
131
132 %files file-devel
133 %defattr(-,root,root,-)
134 %{_libdir}/pkgconfig/stt-file.pc
135 %{_includedir}/stt_file.h
136
137 %files setting-devel
138 %defattr(-,root,root,-)
139 %{_libdir}/pkgconfig/stt-setting.pc
140 %{_includedir}/stt_setting.h
141
142 %files engine-devel
143 %defattr(-,root,root,-)
144 %{_libdir}/pkgconfig/stt-engine.pc
145 %{_includedir}/stte.h