]>
Commit | Line | Data |
---|---|---|
73036130 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without qch # documentation in QCH format | |
4 | ||
5 | %define orgname qtwebkit-examples | |
6 | %define qtbase_ver %{version} | |
7 | %define qtdeclarative_ver %{version} | |
8 | %define qtscript_ver %{version} | |
9 | %define qttools_ver %{version} | |
10 | %define qtwebkit_ver %{version} | |
11 | %define qtxmlpatterns_ver %{version} | |
12 | Summary: Qt5 WebKit examples | |
13 | Summary(pl.UTF-8): Przykłady do bibliotek Qt5 WebKit | |
14 | Name: qt5-%{orgname} | |
fdeea969 | 15 | Version: 5.3.2 |
73036130 JB |
16 | Release: 1 |
17 | License: LGPL v2+ | |
18 | Group: X11/Libraries | |
19 | Source0: http://download.qt-project.org/official_releases/qt/5.3/%{version}/submodules/%{orgname}-opensource-src-%{version}.tar.xz | |
fdeea969 | 20 | # Source0-md5: 6f88c2a99002801a1943483331f8b4f0 |
73036130 JB |
21 | URL: http://qt-project.org/ |
22 | BuildRequires: OpenGL-devel | |
23 | BuildRequires: Qt5Concurrent-devel >= %{qtbase_ver} | |
24 | BuildRequires: Qt5Core-devel >= %{qtbase_ver} | |
25 | BuildRequires: Qt5Gui-devel >= %{qtbase_ver} | |
26 | BuildRequires: Qt5Network-devel >= %{qtbase_ver} | |
27 | BuildRequires: Qt5OpenGL-devel >= %{qtbase_ver} | |
28 | BuildRequires: Qt5PrintSupport-devel >= %{qtbase_ver} | |
29 | BuildRequires: Qt5Qml-devel >= %{qtdeclarative_ver} | |
30 | BuildRequires: Qt5Quick-devel >= %{qtdeclarative_ver} | |
31 | BuildRequires: Qt5Sql-devel >= %{qtbase_ver} | |
32 | BuildRequires: Qt5WebKit-devel >= %{qtwebkit_ver} | |
33 | BuildRequires: Qt5Widgets-devel >= %{qtbase_ver} | |
34 | BuildRequires: Qt5XmlPatterns-devel >= %{qtxmlpatterns_ver} | |
35 | BuildRequires: pkgconfig | |
36 | BuildRequires: rpmbuild(macros) >= 1.654 | |
37 | %if %{with qch} | |
38 | BuildRequires: qt5-assistant >= %{qttools_ver} | |
39 | %endif | |
40 | BuildRequires: qt5-build >= %{qtbase_ver} | |
41 | BuildRequires: qt5-qmake >= %{qtbase_ver} | |
42 | BuildRequires: rpmbuild(macros) >= 1.654 | |
43 | BuildRequires: tar >= 1:1.22 | |
44 | BuildRequires: xz | |
45 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
46 | ||
47 | %define specflags -fno-strict-aliasing | |
48 | ||
49 | %description | |
50 | Qt is a cross-platform application and UI framework. Using Qt, you can | |
51 | write web-enabled applications once and deploy them across desktop, | |
52 | mobile and embedded systems without rewriting the source code. | |
53 | ||
54 | This package contains Qt5 WebKit examples. | |
55 | ||
56 | %description -l pl.UTF-8 | |
57 | Qt to wieloplatformowy szkielet aplikacji i interfejsów użytkownika. | |
58 | Przy użyciu Qt można pisać aplikacje powiązane z WWW i wdrażać je w | |
59 | systemach biurkowych, przenośnych i wbudowanych bez przepisywania kodu | |
60 | źródłowego. | |
61 | ||
62 | Ten pakiet zawiera przykłady do bibliotek Qt5 WebKit. | |
63 | ||
64 | %package doc | |
65 | Summary: Qt5 WebKit examples documentation in HTML format | |
66 | Summary(pl.UTF-8): Dokumentacja przykładów do bibliotek Qt5 WebKit w formacie HTML | |
67 | Group: Documentation | |
68 | Requires: qt5-doc-common >= %{qtbase_ver} | |
69 | %if "%{_rpmversion}" >= "5" | |
70 | BuildArch: noarch | |
71 | %endif | |
72 | ||
73 | %description doc | |
74 | Qt5 WebKit examples documentation in HTML format. | |
75 | ||
76 | %description doc -l pl.UTF-8 | |
77 | Dokumentacja przykładów do bibliotek Qt5 WebKit w formacie HTML. | |
78 | ||
79 | %package doc-qch | |
80 | Summary: Qt5 WebKit examples documentation in QCH format | |
81 | Summary(pl.UTF-8): Dokumentacja przykładów do bibliotek Qt5 WebKit w formacie QCH | |
82 | Group: Documentation | |
83 | Requires: qt5-doc-common >= %{qtbase_ver} | |
84 | %if "%{_rpmversion}" >= "5" | |
85 | BuildArch: noarch | |
86 | %endif | |
87 | ||
88 | %description doc-qch | |
89 | Qt5 WebKit examples documentation in QCH format. | |
90 | ||
91 | %description doc-qch -l pl.UTF-8 | |
92 | Dokumentacja przykładów do bibliotek Qt5 WebKit w formacie QCH. | |
93 | ||
94 | %prep | |
95 | %setup -q -n %{orgname}-opensource-src-%{version} | |
96 | ||
97 | %build | |
98 | qmake-qt5 | |
99 | ||
100 | %{__make} | |
101 | %{__make} %{!?with_qch:html_}docs | |
102 | ||
103 | %install | |
104 | rm -rf $RPM_BUILD_ROOT | |
105 | ||
106 | %{__make} install \ | |
107 | INSTALL_ROOT=$RPM_BUILD_ROOT | |
108 | ||
109 | %{__make} install_%{!?with_qch:html_}docs \ | |
110 | INSTALL_ROOT=$RPM_BUILD_ROOT | |
111 | ||
112 | # Prepare some files list | |
113 | ifecho() { | |
114 | r="$RPM_BUILD_ROOT$2" | |
115 | if [ -d "$r" ]; then | |
116 | echo "%%dir $2" >> $1.files | |
117 | elif [ -x "$r" ] ; then | |
118 | echo "%%attr(755,root,root) $2" >> $1.files | |
119 | elif [ -f "$r" ]; then | |
120 | echo "$2" >> $1.files | |
121 | else | |
122 | echo "Error generation $1 files list!" | |
123 | echo "$r: no such file or directory!" | |
124 | return 1 | |
125 | fi | |
126 | } | |
127 | ifecho_tree() { | |
128 | ifecho $1 $2 | |
129 | for f in `find $RPM_BUILD_ROOT$2 -printf "%%P "`; do | |
130 | ifecho $1 $2/$f | |
131 | done | |
132 | } | |
133 | ||
134 | echo "%defattr(644,root,root,755)" > examples.files | |
135 | ifecho_tree examples %{_examplesdir}/qt5/webkitqml | |
136 | ifecho_tree examples %{_examplesdir}/qt5/webkitwidgets | |
137 | ||
138 | %clean | |
139 | rm -rf $RPM_BUILD_ROOT | |
140 | ||
141 | %files -f examples.files | |
142 | %defattr(644,root,root,755) | |
143 | %doc dist/changes-* | |
144 | # XXX: dir shared with qt5-qtbase-examples | |
145 | %dir %{_examplesdir}/qt5 | |
146 | ||
147 | %files doc | |
148 | %defattr(644,root,root,755) | |
149 | %{_docdir}/qt5-doc/qtwebkitexamples | |
150 | ||
151 | %if %{with qch} | |
152 | %files doc-qch | |
153 | %defattr(644,root,root,755) | |
154 | %{_docdir}/qt5-doc/qtwebkitexamples.qch | |
155 | %endif |