]>
Commit | Line | Data |
---|---|---|
dffafefb | 1 | # TODO: |
dffafefb WF |
2 | # - cleanup |
3 | ||
4 | %define orgname qtdeclarative | |
5 | Summary: The Qt5 Declarative | |
6 | Name: qt5-%{orgname} | |
7 | Version: 5.2.0 | |
8 | Release: 0.1 | |
9 | License: LGPL v2.1 or GPL v3.0 | |
10 | Group: X11/Libraries | |
11 | Source0: http://download.qt-project.org/official_releases/qt/5.2/%{version}/submodules/%{orgname}-opensource-src-%{version}.tar.xz | |
12 | # Source0-md5: 0f7714c5c91b8eb7cdc1071f0a51c202 | |
13 | URL: http://qt-project.org/ | |
14 | BuildRequires: qt5-qtbase-devel = %{version} | |
3329af2e | 15 | BuildRequires: qt5-qttools-devel = %{version} |
dffafefb WF |
16 | BuildRequires: rpmbuild(macros) >= 1.654 |
17 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
18 | ||
19 | %define _noautoreqdep libGL.so.1 libGLU.so.1 | |
20 | %define _noautostrip '.*_debug\\.so*' | |
21 | ||
22 | %define specflags -fno-strict-aliasing | |
23 | %define _qtdir %{_libdir}/qt5 | |
24 | ||
25 | %description | |
26 | Qt5 declarative libraries. | |
27 | ||
28 | %package devel | |
29 | Summary: The Qt5 Declarative application framework - development files | |
30 | Group: X11/Development/Libraries | |
31 | Requires: %{name} = %{version}-%{release} | |
32 | ||
33 | %description devel | |
34 | Qt5 Declarative - development files. | |
35 | ||
3329af2e WF |
36 | %package doc |
37 | Summary: The Qt5 Declarative - docs | |
38 | Group: Documentation | |
39 | ||
40 | %description doc | |
41 | Qt5 Declarative - documentation. | |
42 | ||
dffafefb WF |
43 | %package examples |
44 | Summary: Qt5 Declarative examples | |
45 | Group: X11/Development/Libraries | |
46 | ||
47 | %description examples | |
48 | Qt5 Declarative - examples. | |
49 | ||
50 | %prep | |
51 | %setup -q -n %{orgname}-opensource-src-%{version} | |
52 | ||
53 | %build | |
54 | qmake-qt5 | |
55 | %{__make} | |
56 | %{__make} docs | |
57 | ||
58 | %install | |
59 | rm -rf $RPM_BUILD_ROOT | |
3329af2e WF |
60 | %{__make} install \ |
61 | INSTALL_ROOT=$RPM_BUILD_ROOT | |
62 | ||
63 | %{__make} install_docs \ | |
dffafefb WF |
64 | INSTALL_ROOT=$RPM_BUILD_ROOT |
65 | ||
66 | # Prepare some files list | |
67 | ifecho() { | |
68 | RESULT=`echo $RPM_BUILD_ROOT$2 2>/dev/null` | |
69 | [ "$RESULT" == "" ] && return # XXX this is never true due $RPM_BUILD_ROOT being set | |
70 | r=`echo $RESULT | awk '{ print $1 }'` | |
71 | ||
72 | if [ -d "$r" ]; then | |
73 | echo "%%dir $2" >> $1.files | |
74 | elif [ -x "$r" ] ; then | |
75 | echo "%%attr(755,root,root) $2" >> $1.files | |
76 | elif [ -f "$r" ]; then | |
77 | echo "$2" >> $1.files | |
78 | else | |
79 | echo "Error generation $1 files list!" | |
80 | echo "$r: no such file or directory!" | |
81 | return 1 | |
82 | fi | |
83 | } | |
84 | ||
85 | echo "%defattr(644,root,root,755)" > examples.files | |
86 | ifecho examples %{_examplesdir}/qt5 | |
87 | for f in `find $RPM_BUILD_ROOT%{_examplesdir}/qt5 -printf "%%P "`; do | |
88 | ifecho examples %{_examplesdir}/qt5/$f | |
89 | done | |
90 | ||
91 | %clean | |
92 | rm -rf $RPM_BUILD_ROOT | |
93 | ||
94 | %post -p /sbin/ldconfig | |
95 | %postun -p /sbin/ldconfig | |
96 | ||
97 | %files | |
98 | %defattr(644,root,root,755) | |
99 | #%attr(755,root,root) %{_bindir}/* | |
100 | %attr(755,root,root) %ghost %{_libdir}/libQt5Qml.so.? | |
101 | %attr(755,root,root) %{_libdir}/libQt5Qml.so.*.* | |
102 | %attr(755,root,root) %ghost %{_libdir}/libQt5Quick.so.? | |
103 | %attr(755,root,root) %{_libdir}/libQt5Quick.so.*.* | |
104 | %attr(755,root,root) %ghost %{_libdir}/libQt5QuickParticles.so.? | |
105 | %attr(755,root,root) %{_libdir}/libQt5QuickParticles.so.*.* | |
106 | %attr(755,root,root) %ghost %{_libdir}/libQt5QuickTest.so.? | |
107 | %attr(755,root,root) %{_libdir}/libQt5QuickTest.so.*.* | |
108 | %{_libdir}/libQt5QmlDevTools.a | |
109 | %attr(755,root,root) %{_qtdir}/bin/qml* | |
110 | %attr(755,root,root) %{_qtdir}/plugins | |
111 | %attr(755,root,root) %{_qtdir}/qml | |
112 | ||
113 | %files devel | |
114 | %defattr(644,root,root,755) | |
115 | %attr(755,root,root) %{_libdir}/libQt5Qml.so | |
116 | %attr(755,root,root) %{_libdir}/libQt5Quick.so | |
117 | %attr(755,root,root) %{_libdir}/libQt5QuickParticles.so | |
118 | %attr(755,root,root) %{_libdir}/libQt5QuickTest.so | |
119 | %{_libdir}/libQt5Qml.la | |
120 | %{_libdir}/libQt5Quick.la | |
121 | %{_libdir}/libQt5QuickParticles.la | |
122 | %{_libdir}/libQt5QuickTest.la | |
123 | %{_libdir}/libQt5QmlDevTools.la | |
124 | ||
125 | %{_libdir}/libQt5Qml.prl | |
126 | %{_libdir}/libQt5Quick.prl | |
127 | %{_libdir}/libQt5QuickParticles.prl | |
128 | %{_libdir}/libQt5QuickTest.prl | |
129 | %{_libdir}/libQt5QmlDevTools.prl | |
130 | ||
131 | %{_libdir}/cmake/Qt5Qml | |
132 | %{_libdir}/cmake/Qt5Quick | |
133 | %{_libdir}/cmake/Qt5QuickTest | |
dffafefb WF |
134 | |
135 | %{_includedir}/qt5/QtQml | |
136 | %{_includedir}/qt5/QtQuick | |
137 | %{_includedir}/qt5/QtQuickParticles | |
138 | %{_includedir}/qt5/QtQuickTest | |
139 | ||
140 | %{_pkgconfigdir}/*.pc | |
141 | ||
142 | %{_qtdir}/mkspecs | |
143 | ||
3329af2e WF |
144 | %files doc |
145 | %defattr(644,root,root,755) | |
146 | %{_docdir}/qt5-doc | |
147 | ||
dffafefb | 148 | %files examples -f examples.files |