]> git.pld-linux.org Git - packages/qt5-qtconnectivity.git/blob - qt5-qtconnectivity.spec
- versioned Obsoletes for qt5-qtconnectivity*
[packages/qt5-qtconnectivity.git] / qt5-qtconnectivity.spec
1 #
2 # Conditional build:
3 %bcond_without  doc     # Documentation
4 %bcond_without  qm      # QM translations
5
6 %define         orgname         qtconnectivity
7 %define         qtbase_ver              %{version}
8 %define         qtdeclarative_ver       %{version}
9 %define         qttools_ver             %{version}
10 Summary:        The Qt5 Connectivity libraries
11 Summary(pl.UTF-8):      Biblioteki Qt5 Connectivity
12 Name:           qt5-%{orgname}
13 Version:        5.15.2
14 Release:        2
15 License:        LGPL v3 or GPL v2 or GPL v3 or commercial
16 Group:          Libraries
17 Source0:        http://download.qt.io/official_releases/qt/5.15/%{version}/submodules/%{orgname}-everywhere-src-%{version}.tar.xz
18 # Source0-md5:  98ec17cf9b3181993e0bb6b599b1b9e7
19 Source1:        http://download.qt.io/official_releases/qt/5.15/%{version}/submodules/qttranslations-everywhere-src-%{version}.tar.xz
20 # Source1-md5:  9b66cdb64402e8fd9e843f8a7120abb1
21 URL:            https://www.qt.io/
22 BuildRequires:  Qt5Concurrent-devel >= %{qtbase_ver}
23 BuildRequires:  Qt5Core-devel >= %{qtbase_ver}
24 BuildRequires:  Qt5DBus-devel >= %{qtbase_ver}
25 BuildRequires:  Qt5Network-devel >= %{qtbase_ver}
26 BuildRequires:  Qt5Qml-devel >= %{qtdeclarative_ver}
27 BuildRequires:  bluez-libs-devel
28 %if %{with doc}
29 BuildRequires:  qt5-assistant >= %{qttools_ver}
30 %endif
31 BuildRequires:  qt5-build >= %{qtbase_ver}
32 %{?with_qm:BuildRequires:       qt5-linguist >= %{qttools_ver}}
33 BuildRequires:  qt5-qmake >= %{qtbase_ver}
34 BuildRequires:  rpmbuild(macros) >= 1.752
35 BuildRequires:  tar >= 1:1.22
36 BuildRequires:  xz
37 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
38
39 %define         specflags       -fno-strict-aliasing
40 %define         qt5dir          %{_libdir}/qt5
41
42 %description
43 Qt is a cross-platform application and UI framework. Using Qt, you can
44 write web-enabled applications once and deploy them across desktop,
45 mobile and embedded systems without rewriting the source code.
46
47 This package contains Qt5 Connectivity libraries: Qt5Bluetooth and
48 QtNfc.
49
50 %description -l pl.UTF-8
51 Qt to wieloplatformowy szkielet aplikacji i interfejsów użytkownika.
52 Przy użyciu Qt można pisać aplikacje powiązane z WWW i wdrażać je w
53 systemach biurkowych, przenośnych i wbudowanych bez przepisywania kodu
54 źródłowego.
55
56 Ten pakiet zawiera biblioteki Qt5 Connectivity: Qt5Bluetooth i Qt5Nfc.
57
58 %package common
59 Summary:        Common files used by all Qt5 Connectivity components
60 Summary(pl.UTF-8):      Wspólne pliki wykorzystywane przez wszystkie komponenty Qt5 Connectivity
61 Group:          Libraries
62
63 %description common
64 Common files used by all Qt5 Connectivity components.
65
66 %description common -l pl.UTF-8
67 Wspólne pliki wykorzystywane przez wszystkie komponenty Qt5
68 Connectivity.
69
70 %package -n Qt5Bluetooth
71 Summary:        Qt5 Bluetooth library
72 Summary(pl.UTF-8):      Biblioteka Qt5 Bluetooth
73 Group:          Libraries
74 Requires:       %{name}-common = %{version}-%{release}
75 Requires:       Qt5Core >= %{qtbase_ver}
76 Requires:       Qt5DBus >= %{qtbase_ver}
77 Requires:       Qt5Network >= %{qtbase_ver}
78 Requires:       Qt5Qml >= %{qtdeclarative_ver}
79 Obsoletes:      qt5-qtconnectivity < 5.3.1
80
81 %description -n Qt5Bluetooth
82 Qt5 Bluetooth library provides classes that enable basic Bluetooth
83 operations like scanning for devices and connecting them.
84
85 %description -n Qt5Bluetooth -l pl.UTF-8
86 Biblioteka Qt5 Bluetooth dostarcza klasy umożliwiające podstawowe
87 operacje Bluetooth, takie jak wyszukiwanie urządzeń i łączenie z nimi.
88
89 %package -n Qt5Bluetooth-devel
90 Summary:        The Qt5 Bluetooth - development files
91 Summary(pl.UTF-8):      Biblioteka Qt5 Bluetooth - pliki programistyczne
92 Group:          Development/Libraries
93 Requires:       Qt5Bluetooth = %{version}-%{release}
94 Requires:       Qt5Core-devel >= %{qtbase_ver}
95 Requires:       Qt5DBus-devel >= %{qtbase_ver}
96 Requires:       Qt5Qml-devel >= %{qtdeclarative_ver}
97 Obsoletes:      qt5-qtconnectivity-devel < 5.3.1
98
99 %description -n Qt5Bluetooth-devel
100 The Qt5 Bluetooth - development files.
101
102 %description -n Qt5Bluetooth-devel -l pl.UTF-8
103 Biblioteka Qt5 Bluetooth - pliki programistyczne.
104
105 %package -n Qt5Nfc
106 Summary:        Qt5 Nfc library
107 Summary(pl.UTF-8):      Biblioteka Qt5 Nfc
108 Group:          Libraries
109 Requires:       %{name}-common = %{version}-%{release}
110 Requires:       Qt5Core >= %{qtbase_ver}
111 Requires:       Qt5DBus >= %{qtbase_ver}
112 Requires:       Qt5Qml >= %{qtdeclarative_ver}
113 Obsoletes:      qt5-qtconnectivity
114
115 %description -n Qt5Nfc
116 Qt5 Nfc library provides classes to access NFC Forum Tags.
117
118 %description -n Qt5Nfc -l pl.UTF-8
119 Biblioteka Qt5 Nfc dostarcza klasy służace do dostępu do urządzeń NFC
120 Forum.
121
122 %package -n Qt5Nfc-devel
123 Summary:        The Qt5 Nfc - development files
124 Summary(pl.UTF-8):      Biblioteka Qt5 Nfc - pliki programistyczne
125 Group:          Development/Libraries
126 Requires:       Qt5Nfc = %{version}-%{release}
127 Requires:       Qt5Core-devel >= %{qtbase_ver}
128 Requires:       Qt5DBus-devel >= %{qtbase_ver}
129 Requires:       Qt5Qml-devel >= %{qtdeclarative_ver}
130 Obsoletes:      qt5-qtconnectivity-devel
131
132 %description -n Qt5Nfc-devel
133 The Qt5 Nfc - development files.
134
135 %description -n Qt5Nfc-devel -l pl.UTF-8
136 Biblioteka Qt5 Nfc - pliki programistyczne.
137
138 %package doc
139 Summary:        Qt5 Connectivity documentation in HTML format
140 Summary(pl.UTF-8):      Dokumentacja do bibliotek Qt5 Connectivity w formacie HTML
141 Group:          Documentation
142 Requires:       qt5-doc-common >= %{qtbase_ver}
143 %{?noarchpackage}
144
145 %description doc
146 Qt5 Connectivity documentation in HTML format.
147
148 %description doc -l pl.UTF-8
149 Dokumentacja do bibliotek Qt5 Connectivity w formacie HTML.
150
151 %package doc-qch
152 Summary:        Qt5 Connectivity documentation in QCH format
153 Summary(pl.UTF-8):      Dokumentacja do bibliotek Qt5 Connectivity w formacie QCH
154 Group:          Documentation
155 Requires:       qt5-doc-common >= %{qtbase_ver}
156 %{?noarchpackage}
157
158 %description doc-qch
159 Qt5 Connectivity documentation in QCH format.
160
161 %description doc-qch -l pl.UTF-8
162 Dokumentacja do bibliotek Qt5 Connectivity w formacie QCH.
163
164 %package examples
165 Summary:        Qt5 Connectivity examples
166 Summary(pl.UTF-8):      Przykłady do bibliotek Qt5 Connectivity
167 Group:          X11/Development/Libraries
168 %{?noarchpackage}
169
170 %description examples
171 Qt5 Connectivity examples.
172
173 %description examples -l pl.UTF-8
174 Przykłady do bibliotek Qt5 Connectivity.
175
176 %prep
177 %setup -q -n %{orgname}-everywhere-src-%{version} %{?with_qm:-a1}
178
179 %build
180 qmake-qt5
181 %{__make}
182 %{?with_doc:%{__make} docs}
183
184 %if %{with qm}
185 cd qttranslations-everywhere-src-%{version}
186 qmake-qt5
187 %{__make}
188 cd ..
189 %endif
190
191 %install
192 rm -rf $RPM_BUILD_ROOT
193
194 %{__make} install \
195         INSTALL_ROOT=$RPM_BUILD_ROOT
196
197 %if %{with doc}
198 %{__make} install_docs \
199         INSTALL_ROOT=$RPM_BUILD_ROOT
200 %endif
201
202 %if %{with qm}
203 %{__make} -C qttranslations-everywhere-src-%{version} install \
204         INSTALL_ROOT=$RPM_BUILD_ROOT
205 # keep only qtconnectivity
206 %{__rm} $RPM_BUILD_ROOT%{_datadir}/qt5/translations/{assistant,designer,linguist,qt,qtbase,qtdeclarative,qtlocation,qtmultimedia,qtquickcontrols,qtquickcontrols2,qtserialport,qtscript,qtwebengine,qtwebsockets,qtxmlpatterns}_*.qm
207 %endif
208
209 # useless symlinks
210 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libQt5*.so.5.??
211 # actually drop *.la, follow policy of not packaging them when *.pc exist
212 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libQt5*.la
213
214 # Prepare some files list
215 ifecho() {
216         r="$RPM_BUILD_ROOT$2"
217         if [ -d "$r" ]; then
218                 echo "%%dir $2" >> $1.files
219         elif [ -x "$r" ] ; then
220                 echo "%%attr(755,root,root) $2" >> $1.files
221         elif [ -f "$r" ]; then
222                 echo "$2" >> $1.files
223         else
224                 echo "Error generation $1 files list!"
225                 echo "$r: no such file or directory!"
226                 return 1
227         fi
228 }
229 ifecho_tree() {
230         ifecho $1 $2
231         for f in `find $RPM_BUILD_ROOT$2 -printf "%%P "`; do
232                 ifecho $1 $2/$f
233         done
234 }
235
236 echo "%defattr(644,root,root,755)" > examples.files
237 ifecho_tree examples %{_examplesdir}/qt5/bluetooth
238 ifecho_tree examples %{_examplesdir}/qt5/nfc
239
240 # find_lang --with-qm supports only PLD qt3/qt4 specific %{_datadir}/locale/*/LC_MESSAGES layout
241 find_qt5_qm()
242 {
243         name="$1"
244         find $RPM_BUILD_ROOT%{_datadir}/qt5/translations -name "${name}_*.qm" | \
245                 sed -e "s:^$RPM_BUILD_ROOT::" \
246                     -e 's:\(.*/'$name'_\)\([a-z][a-z][a-z]\?\)\(_[A-Z][A-Z]\)\?\(\.qm\)$:%lang(\2\3) \1\2\3\4:'
247 }
248
249 echo '%defattr(644,root,root,755)' > qtconnectivity.lang
250 %if %{with qm}
251 find_qt5_qm qtconnectivity >> qtconnectivity.lang
252 %endif
253
254 %clean
255 rm -rf $RPM_BUILD_ROOT
256
257 %post   -n Qt5Bluetooth -p /sbin/ldconfig
258 %postun -n Qt5Bluetooth -p /sbin/ldconfig
259
260 %post   -n Qt5Nfc -p /sbin/ldconfig
261 %postun -n Qt5Nfc -p /sbin/ldconfig
262
263 %files common -f qtconnectivity.lang
264 %defattr(644,root,root,755)
265 %doc LICENSE.GPL3-EXCEPT dist/changes-*
266
267 %files -n Qt5Bluetooth
268 %defattr(644,root,root,755)
269 %attr(755,root,root) %{_libdir}/libQt5Bluetooth.so.*.*.*
270 %attr(755,root,root) %ghost %{_libdir}/libQt5Bluetooth.so.5
271 %attr(755,root,root) %{qt5dir}/bin/sdpscanner
272 %dir %{qt5dir}/qml/QtBluetooth
273 %attr(755,root,root) %{qt5dir}/qml/QtBluetooth/libdeclarative_bluetooth.so
274 %{qt5dir}/qml/QtBluetooth/plugins.qmltypes
275 %{qt5dir}/qml/QtBluetooth/qmldir
276
277 %files -n Qt5Bluetooth-devel
278 %defattr(644,root,root,755)
279 %attr(755,root,root) %{_libdir}/libQt5Bluetooth.so
280 %{_libdir}/libQt5Bluetooth.prl
281 %{_includedir}/qt5/QtBluetooth
282 %{_pkgconfigdir}/Qt5Bluetooth.pc
283 %{_libdir}/cmake/Qt5Bluetooth
284 %{qt5dir}/mkspecs/modules/qt_lib_bluetooth.pri
285 %{qt5dir}/mkspecs/modules/qt_lib_bluetooth_private.pri
286
287 %files -n Qt5Nfc
288 %defattr(644,root,root,755)
289 %attr(755,root,root) %{_libdir}/libQt5Nfc.so.*.*.*
290 %attr(755,root,root) %ghost %{_libdir}/libQt5Nfc.so.5
291 %dir %{qt5dir}/qml/QtNfc
292 %attr(755,root,root) %{qt5dir}/qml/QtNfc/libdeclarative_nfc.so
293 %{qt5dir}/qml/QtNfc/plugins.qmltypes
294 %{qt5dir}/qml/QtNfc/qmldir
295
296 %files -n Qt5Nfc-devel
297 %defattr(644,root,root,755)
298 %attr(755,root,root) %{_libdir}/libQt5Nfc.so
299 %{_libdir}/libQt5Nfc.prl
300 %{_includedir}/qt5/QtNfc
301 %{_pkgconfigdir}/Qt5Nfc.pc
302 %{_libdir}/cmake/Qt5Nfc
303 %{qt5dir}/mkspecs/modules/qt_lib_nfc.pri
304 %{qt5dir}/mkspecs/modules/qt_lib_nfc_private.pri
305
306 %if %{with doc}
307 %files doc
308 %defattr(644,root,root,755)
309 %{_docdir}/qt5-doc/qtbluetooth
310 %{_docdir}/qt5-doc/qtnfc
311
312 %files doc-qch
313 %defattr(644,root,root,755)
314 %{_docdir}/qt5-doc/qtbluetooth.qch
315 %{_docdir}/qt5-doc/qtnfc.qch
316 %endif
317
318 %files examples -f examples.files
319 %defattr(644,root,root,755)
320 # XXX: dir shared with qt5-qtbase-examples
321 %dir %{_examplesdir}/qt5
This page took 0.086981 seconds and 3 git commands to generate.