3 %bcond_without doc # Documentation
5 %define orgname qtwebchannel
6 %define qtbase_ver %{version}
7 %define qtdeclarative_ver %{version}
8 %define qttools_ver %{version}
9 Summary: The Qt5 WebChannel library
10 Summary(pl.UTF-8): Biblioteka Qt5 WebChannel
14 License: LGPL v2.1 with Digia Qt LGPL Exception v1.1 or GPL v3.0
16 Source0: http://download.qt.io/official_releases/qt/5.15/%{version}/submodules/%{orgname}-everywhere-src-%{version}.tar.xz
17 # Source0-md5: 3b38221f05415a941649ecc5a14034bc
18 URL: http://www.qt.io/
19 BuildRequires: Qt5Core-devel >= %{qtbase_ver}
20 BuildRequires: Qt5Network-devel >= %{qtbase_ver}
21 BuildRequires: Qt5Qml-devel >= %{qtdeclarative_ver}
22 BuildRequires: Qt5Quick-devel >= %{qtdeclarative_ver}
24 BuildRequires: qt5-assistant >= %{qttools_ver}
26 BuildRequires: qt5-build >= %{qtbase_ver}
27 BuildRequires: qt5-qmake >= %{qtbase_ver}
28 BuildRequires: rpmbuild(macros) >= 1.654
29 BuildRequires: tar >= 1:1.22
31 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33 %define specflags -fno-strict-aliasing
34 %define qt5dir %{_libdir}/qt5
37 Qt is a cross-platform application and UI framework. Using Qt, you can
38 write web-enabled applications once and deploy them across desktop,
39 mobile and embedded systems without rewriting the source code.
41 This package contains Qt5 WebChannel library.
43 %description -l pl.UTF-8
44 Qt to wieloplatformowy szkielet aplikacji i interfejsów użytkownika.
45 Przy użyciu Qt można pisać aplikacje powiązane z WWW i wdrażać je w
46 systemach biurkowych, przenośnych i wbudowanych bez przepisywania kodu
49 Ten pakiet zawiera bibliotekę Qt5 WebChannel.
51 %package -n Qt5WebChannel
52 Summary: The Qt5 WebChannel library
53 Summary(pl.UTF-8): Biblioteka Qt5 WebChannel
55 Requires: Qt5Core >= %{qtbase_ver}
56 Requires: Qt5Network >= %{qtbase_ver}
57 Requires: Qt5Qml >= %{qtdeclarative_ver}
59 %description -n Qt5WebChannel
60 Qt5 WebChannel library provides seamless integration of C++ and QML
61 applications with HTML/JavaScript clients.
63 %description -n Qt5WebChannel -l pl.UTF-8
64 Biblioteka Qt5 WebChannel udostępnia integrację aplikacji C++ i QML z
65 klientami w HTML-u/JavaScripcie.
67 %package -n Qt5WebChannel-devel
68 Summary: Qt5 WebChannel library - development files
69 Summary(pl.UTF-8): Biblioteka Qt5 WebChannel - pliki programistyczne
70 Group: Development/Libraries
71 Requires: Qt5Core-devel >= %{qtbase_ver}
72 Requires: Qt5Network-devel >= %{qtbase_ver}
73 Requires: Qt5Qml-devel >= %{qtdeclarative_ver}
74 Requires: Qt5WebChannel = %{version}-%{release}
76 %description -n Qt5WebChannel-devel
77 Qt5 WebChannel library - development files.
79 %description -n Qt5WebChannel-devel -l pl.UTF-8
80 Biblioteka Qt5 WebChannel - pliki programistyczne.
83 Summary: Qt5 WebChannel documentation in HTML format
84 Summary(pl.UTF-8): Dokumentacja do biblioteki Qt5 WebChannel w formacie HTML
86 Requires: qt5-doc-common >= %{qtbase_ver}
87 %if "%{_rpmversion}" >= "5"
92 Qt5 WebChannel documentation in HTML format.
94 %description doc -l pl.UTF-8
95 Dokumentacja do biblioteki Qt5 WebChannel w formacie HTML.
98 Summary: Qt5 WebChannel documentation in QCH format
99 Summary(pl.UTF-8): Dokumentacja do biblioteki Qt5 WebChannel w formacie QCH
101 Requires: qt5-doc-common >= %{qtbase_ver}
102 %if "%{_rpmversion}" >= "5"
107 Qt5 WebChannel documentation in QCH format.
109 %description doc-qch -l pl.UTF-8
110 Dokumentacja do biblioteki Qt5 WebChannel w formacie QCH.
113 Summary: Qt5 WebChannel examples
114 Summary(pl.UTF-8): Przykłady do biblioteki Qt5 WebChannel
115 Group: X11/Development/Libraries
116 %if "%{_rpmversion}" >= "5"
120 %description examples
121 Qt5 WebChannel examples.
123 %description examples -l pl.UTF-8
124 Przykłady do biblioteki Qt5 WebChannel.
127 %setup -q -n %{orgname}-everywhere-src-%{version}
130 s,^#!.*bin/env node,#!/usr/bin/node,
132 examples/webchannel/qwclient/qwclient.js
137 %{?with_doc:%{__make} docs}
140 rm -rf $RPM_BUILD_ROOT
142 INSTALL_ROOT=$RPM_BUILD_ROOT
145 %{__make} install_docs \
146 INSTALL_ROOT=$RPM_BUILD_ROOT
150 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libQt5*.so.5.??
151 # actually drop *.la, follow policy of not packaging them when *.pc exist
152 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libQt5*.la
154 # Prepare some files list
156 r="$RPM_BUILD_ROOT$2"
158 echo "%%dir $2" >> $1.files
159 elif [ -x "$r" ] ; then
160 echo "%%attr(755,root,root) $2" >> $1.files
161 elif [ -f "$r" ]; then
162 echo "$2" >> $1.files
164 echo "Error generation $1 files list!"
165 echo "$r: no such file or directory!"
171 for f in `find $RPM_BUILD_ROOT$2 -printf "%%P "`; do
176 echo "%defattr(644,root,root,755)" > examples.files
177 ifecho_tree examples %{_examplesdir}/qt5/webchannel
180 rm -rf $RPM_BUILD_ROOT
182 %post -n Qt5WebChannel -p /sbin/ldconfig
183 %postun -n Qt5WebChannel -p /sbin/ldconfig
185 %files -n Qt5WebChannel
186 %defattr(644,root,root,755)
187 %doc LICENSE.GPL3-EXCEPT README.md
188 %attr(755,root,root) %{_libdir}/libQt5WebChannel.so.*.*.*
189 %attr(755,root,root) %ghost %{_libdir}/libQt5WebChannel.so.5
190 %dir %{qt5dir}/qml/QtWebChannel
191 %attr(755,root,root) %{qt5dir}/qml/QtWebChannel/libdeclarative_webchannel.so
192 %{qt5dir}/qml/QtWebChannel/plugins.qmltypes
193 %{qt5dir}/qml/QtWebChannel/qmldir
195 %files -n Qt5WebChannel-devel
196 %defattr(644,root,root,755)
197 %attr(755,root,root) %{_libdir}/libQt5WebChannel.so
198 %{_libdir}/libQt5WebChannel.prl
199 %{_includedir}/qt5/QtWebChannel
200 %{_pkgconfigdir}/Qt5WebChannel.pc
201 %{_libdir}/cmake/Qt5WebChannel
202 %{qt5dir}/mkspecs/modules/qt_lib_webchannel.pri
203 %{qt5dir}/mkspecs/modules/qt_lib_webchannel_private.pri
207 %defattr(644,root,root,755)
208 %{_docdir}/qt5-doc/qtwebchannel
211 %defattr(644,root,root,755)
212 %{_docdir}/qt5-doc/qtwebchannel.qch
215 %files examples -f examples.files
216 %defattr(644,root,root,755)
217 # XXX: dir shared with qt5-qtbase-examples
218 %dir %{_examplesdir}/qt5