1 # Do not create provides from emulator .so files because the main package
2 # should anchor any reverse-dependencies
3 %global __provides_exclude_from ^(.*\\.emulator)$
7 %define _ugdir %{_usrdir}/ug
10 Summary: UI gadget about the bluetooth
15 Source0: %{name}-%{version}.tar.gz
17 Requires(post): coreutils
19 BuildRequires: edje-tools
20 BuildRequires: pkgconfig(edje)
21 BuildRequires: gettext-tools
22 BuildRequires: pkgconfig(elementary)
23 BuildRequires: pkgconfig(efl-extension)
24 BuildRequires: pkgconfig(bundle)
25 BuildRequires: pkgconfig(ui-gadget-1)
26 BuildRequires: pkgconfig(dlog)
27 BuildRequires: pkgconfig(vconf)
28 BuildRequires: pkgconfig(evas)
29 BuildRequires: pkgconfig(edje)
30 BuildRequires: pkgconfig(ecore)
31 BuildRequires: pkgconfig(eina)
32 BuildRequires: pkgconfig(aul)
33 BuildRequires: pkgconfig(appcore-efl)
34 BuildRequires: pkgconfig(syspopup-caller)
35 BuildRequires: pkgconfig(capi-network-bluetooth)
36 BuildRequires: pkgconfig(capi-network-connection)
37 BuildRequires: pkgconfig(capi-system-device)
38 BuildRequires: pkgconfig(capi-system-info)
39 BuildRequires: pkgconfig(motion)
40 BuildRequires: pkgconfig(dbus-glib-1)
41 BuildRequires: pkgconfig(capi-appfw-application)
42 BuildRequires: pkgconfig(notification)
43 BuildRequires: pkgconfig(glib-2.0)
44 BuildRequires: pkgconfig(gio-2.0)
45 BuildRequires: pkgconfig(dpm)
47 # TV profile does not have contacts-service2.
48 # Do not build for unified environment if it is TV.
49 # ==> The usage of "profile" in this spec file is allowed only for excluding TV profile
50 # from unified building.
51 %if "%{?profile}" != "tv"
52 BuildRequires: pkgconfig(contacts-service2)
54 # Dummy contacts for TV product optimization.
55 # Note that even if it includes contacts-service2, the behavior is not chanaged
56 # because the code determines profile at runtime.
61 UI gadget about the bluetooth
63 %ifarch %{ix86} x86_64
64 %package extension-emulator
65 Summary: UI gadget about the bluetooth for emulator
66 Requires: %{name} = %{version}-%{release}
67 %description extension-emulator
68 UI gadget about the bluetooth for emulator
69 %endif // ifarch %{ix86} x86_64
75 # TV profile does not have contacts-service2.
76 # Do not build for unified environment if it is TV.
77 # ==> The usage of "profile" in this spec file is allowed only for excluding TV profile
78 # from unified building.
79 %if "%{?profile}" == "tv"
80 cp %SOURCE1 common/include/contacts.h
83 LDFLAGS="$LDFLAGS -Wl,-z -Wl,nodelete"
85 export CFLAGS_BASE="${CFLAGS}"
86 export CXXFLAGS_BASE="${CXXFLAGS}"
87 export FFLAGS_BASE="${FFLAGS}"
89 # Uncomment to disable BT_HOG of mobile. (refer to the end of common/include/bt-util.h)
90 # Without TIZEN_FEATURE_DISBALE_BT_HOG, BT_HOG is enabled for mobile.
91 #export CFLAGS+=" -DTIZEN_FEATURE_DISABLE_BT_HOG"
94 %ifarch %{ix86} x86_64
95 export CFLAGS="${CFLAGS_BASE} -DTIZEN_TEST_EMUL"
96 export CXXFLAGS="${CXXFLAGS_BASE} -DTIZEN_TEST_EMUL"
97 export FFLAGS="${FFLAGS_BASE} -DTIZEN_TEST_EMUL"
99 mkdir -p build_emulator
101 # TV profile does not have contacts-service2.
102 # Do not build for unified environment if it is TV.
103 # ==> The usage of "profile" in this spec file is allowed only for excluding TV profile
104 # from unified building.
105 %if "%{?profile}" != "tv"
106 %cmake .. -DCMAKE_INSTALL_PREFIX=%{_ugdir}/
108 %cmake .. -DTIZEN_WITHOUT_CONTACTS="1" -DCMAKE_INSTALL_PREFIX=%{_ugdir}/
111 %endif // ifarch %{ix86} x86_64
114 export CFLAGS="${CFLAGS_BASE} -DTIZEN_DEBUG_ENABLE"
115 export CXXFLAGS="${CXXFLAGS_BASE} -DTIZEN_DEBUG_ENABLE"
116 export FFLAGS="${FFLAGS_BASE} -DTIZEN_DEBUG_ENABLE"
118 # TV profile does not have contacts-service2.
119 # Do not build for unified environment if it is TV.
120 # ==> The usage of "profile" in this spec file is allowed only for excluding TV profile
121 # from unified building.
122 %if "%{?profile}" != "tv"
123 %cmake . -DCMAKE_INSTALL_PREFIX=%{_ugdir}/
125 %cmake . -DTIZEN_WITHOUT_CONTACTS="1" -DCMAKE_INSTALL_PREFIX=%{_ugdir}/
128 make %{?jobs:-j%jobs}
131 mkdir -p /usr/ug/bin/
132 ln -sf /usr/bin/ug-client /usr/ug/bin/setting-bluetooth-efl
133 ln -sf /usr/bin/ug-client /usr/ug/bin/setting-bluetooth-efl-single
139 %ifarch %{ix86} x86_64
143 pushd %{buildroot}%{_ugdir}/lib/
144 for FILE in libug-setting-bluetooth-efl.so*; do mv "${FILE}" "${FILE}.emulator"; done
146 %endif // ifarch %{ix86} x86_64
152 %manifest ug-bluetooth-efl.manifest
154 %defattr(-,root,root,-)
156 %{_ugdir}/res/edje/ug-setting-bluetooth-efl/*.edj
157 %{_ugdir}/res/locale/*/LC_MESSAGES/*
158 %{_ugdir}/res/images/ug-setting-bluetooth-efl/*
159 %{_ugdir}/lib/libug-setting-bluetooth-efl.so
160 %{_usrdir}/share/packages/ug-bluetooth-efl.xml
161 %{_usrdir}/share/icons/default/small/ug-bluetooth-efl.png
162 %exclude %{_ugdir}/res/tables/ug-setting-bluetooth-efl/ug-bluetooth-efl_ChangeableColorTable.xml
163 %exclude %{_ugdir}/res/tables/ug-setting-bluetooth-efl/ug-bluetooth-efl_FontInfoTable.xml
164 %{_ugdir}/lib/libug-setting-bluetooth-efl.so.*
165 %exclude %{_ugdir}/lib/libug-setting-bluetooth-efl.so.emulator
166 %exclude %{_ugdir}/lib/libug-setting-bluetooth-efl.so.*.emulator
168 %ifarch %{ix86} x86_64
169 %post extension-emulator
171 for FILE in libug-setting-bluetooth-efl.so*.emulator; do mv "${FILE}" "${FILE%.emulator}"; done
174 %preun extension-emulator
176 for FILE in libug-setting-bluetooth-efl.so*; do mv "${FILE}" "${FILE}.emulator"; done
178 %postun extension-emulator -p /sbin/ldconfig
179 %files extension-emulator
180 %manifest ug-bluetooth-efl.manifest
181 %{_ugdir}/lib/libug-setting-bluetooth-efl.so.emulator
182 %{_ugdir}/lib/libug-setting-bluetooth-efl.so.*.emulator
183 %endif // ifarch %{ix86} x86_64