Add code for checking profile to support TV profile
[platform/core/uifw/inputdelegator.git] / packaging / org.tizen.inputdelegator.spec
1 # For the backward compatibility, this is to be built for
2 # wearable profile or 4.0 unified building environment.
3 # This cannot be built for non-wearable in conventional 3.0 build environment.
4 # Note that it is not a good idea to limit building with ExcludeArch because there are new architectures being tested.
5 # Use ExclusiveArch istead.
6 %if "%{?profile}" == "mobile" || "%{?profile}" == "tv" || "%{?profile}" == "ivi" || "%{?profile}" == "common"
7 ExclusiveArch:  none
8 %endif
9
10 Name: org.tizen.inputdelegator
11 Summary: Input Delegator Application
12 Version: 0.1.170316
13 Release: 1
14 Group: Applications
15 License: Apache-2.0
16 Source0: %{name}-%{version}.tar.gz
17
18 %define enable_log_manager 1
19
20 BuildRequires:  pkgconfig(ecore)
21 BuildRequires:  pkgconfig(evas)
22 BuildRequires:  pkgconfig(edje)
23
24 BuildRequires: cmake
25 BuildRequires: edje-bin
26 BuildRequires: gettext-tools
27
28 BuildRequires: pkgconfig(dlog)
29 BuildRequires: pkgconfig(capi-appfw-application)
30 BuildRequires: pkgconfig(capi-appfw-app-control)
31 BuildRequires: pkgconfig(capi-appfw-preference)
32 BuildRequires: pkgconfig(capi-media-wav-player)
33 BuildRequires: pkgconfig(capi-system-device)
34 BuildRequires: pkgconfig(eina)
35 BuildRequires: pkgconfig(elementary)
36 BuildRequires: pkgconfig(efl-extension)
37 BuildRequires: pkgconfig(feedback)
38 BuildRequires: pkgconfig(stt)
39 BuildRequires: pkgconfig(vconf)
40 BuildRequires: pkgconfig(capi-media-audio-io)
41 BuildRequires: pkgconfig(smartreply)
42 BuildRequires: pkgconfig(capi-system-info)
43
44 %if %{enable_log_manager}
45 BuildRequires:  pkgconfig(bundle)
46 %endif
47
48 %define _appdir         /usr/apps
49 %define _app_destdir    %{_appdir}/%{name}
50
51 # Sandboxed prefix '/'
52 %define _app_prefix     /
53 %define _app_localedir %{_app_prefix}res/locale
54
55 %description
56 Input Delegator Application for Wearable environment
57
58 %prep
59 %setup -q
60
61 %build
62 export CFLAGS+=" -DTIZEN_DEBUG_ENABLE -Werror -fvisibility=hidden"
63 export CXXFLAGS+=" -DTIZEN_DEBUG_ENABLE -Werror -fvisibility=hidden -fvisibility-inlines-hidden"
64 export FFLAGS+=" -DTIZEN_DEBUG_ENABLE -Werror"
65
66 export CXXFLAGS="$CXXFLAGS -std=gnu++0x"
67
68
69 cmake . -DCMAKE_INSTALL_PREFIX=%{_app_prefix} \
70         -DCMAKE_INSTALL_LOCALEDIR=%{_app_localedir} \
71         -DENABLE_LOG_MANAGER=%{enable_log_manager}
72
73 # compile warning & error filtering
74 make %{?jobs:-j%jobs} \
75   2>&1 | sed \
76   -e 's%^.*: error: .*$%\x1b[1;31;40m&\x1b[m%' \
77   -e 's%^.*: warning: .*$%\x1b[1;33;40m&\x1b[m%'
78
79 %install
80 rm -rf %{buildroot}
81 make install DESTDIR=%{buildroot}%{_app_destdir}
82
83 mkdir -p %{buildroot}%{_datadir}/packages/
84 cp -rf org.tizen.inputdelegator.xml %{buildroot}%{_datadir}/packages
85
86 %post
87 #nothing
88
89 /usr/bin/vconftool -u 5000 set -t int db/private/ise/stt/language "0" -f -s tizen::vconf::platform::rw
90
91 %files
92 %manifest org.tizen.inputdelegator.manifest
93 %defattr(-,root,root,-)
94 %license LICENSE
95 %{_datadir}/packages/org.tizen.inputdelegator.xml
96 %{_app_destdir}%{_app_prefix}/bin/inputdelegator
97 %{_app_destdir}%{_app_prefix}/res/edje/w-input-selector.edj
98 %{_app_destdir}%{_app_prefix}/res/edje/w-input-stt.edj
99 %{_app_destdir}%{_app_prefix}/res/edje/w-input-stt-button.edj
100 %{_app_destdir}%{_app_prefix}/res/images/*
101 %{_app_destdir}%{_app_prefix}/shared/res/w-input-selector.png
102 %{_app_destdir}%{_app_localedir}/*/LC_MESSAGES/org.tizen.inputdelegator.mo