]> git.pld-linux.org Git - packages/qt5-qtsensors.git/blob - qt5-qtsensors.spec
06aeac4c4e85dc3096244a44139e5c35bd4fba77
[packages/qt5-qtsensors.git] / qt5-qtsensors.spec
1 # maybe TODO: 
2 # plugins/simulator (BR: Qt5Simulator)
3 # plugins/sensorfw for MeeGo (sensorfw / sensord-qt)
4 #
5 # Conditional build:
6 %bcond_with     bootstrap       # disable features to able to build without installed qt5
7 %bcond_without  qch     # documentation in QCH format
8
9 %if %{with bootstrap}
10 %undefine       with_qch
11 %endif
12
13 %define         orgname         qtsensors
14 %define         qtbase_ver              %{version}
15 %define         qtdeclarative_ver       %{version}
16 %define         qttools_ver             5.8
17 Summary:        The Qt5 Sensors library
18 Summary(pl.UTF-8):      Biblioteka Qt5 Sensors
19 Name:           qt5-%{orgname}
20 Version:        5.8.0
21 Release:        0.1
22 License:        LGPL v2.1 with Digia Qt LGPL Exception v1.1 or GPL v3.0
23 Group:          X11/Libraries
24 Source0:        http://download.qt.io/official_releases/qt/5.8/%{version}/submodules/%{orgname}-opensource-src-%{version}.tar.xz
25 # Source0-md5:  c2062e07ab5d52d0fb8ef19c5ef6f86d
26 URL:            http://www.qt.io/
27 BuildRequires:  Qt5Core-devel >= %{qtbase_ver}
28 BuildRequires:  Qt5Qml-devel >= %{qtdeclarative_ver}
29 BuildRequires:  Qt5Quick-devel >= %{qtdeclarative_ver}
30 %if %{with qch}
31 BuildRequires:  qt5-assistant >= %{qttools_ver}
32 %endif
33 BuildRequires:  qt5-build >= %{qtbase_ver}
34 BuildRequires:  qt5-qmake >= %{qtbase_ver}
35 BuildRequires:  rpmbuild(macros) >= 1.654
36 BuildRequires:  tar >= 1:1.22
37 BuildRequires:  xz
38 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
39
40 %define         specflags       -fno-strict-aliasing
41 %define         qt5dir          %{_libdir}/qt5
42
43 %description
44 Qt is a cross-platform application and UI framework. Using Qt, you can
45 write web-enabled applications once and deploy them across desktop,
46 mobile and embedded systems without rewriting the source code.
47
48 This package contains Qt5 Sensors library.
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 bibliotekę Qt5 Sensors.
57
58 %package -n Qt5Sensors
59 Summary:        The Qt5 Sensors library
60 Summary(pl.UTF-8):      Biblioteka Qt5 Sensors
61 Group:          Libraries
62 Requires:       Qt5Core >= %{qtbase_ver}
63 Requires:       Qt5Qml >= %{qtdeclarative_ver}
64 Obsoletes:      qt5-qtsensors
65
66 %description -n Qt5Sensors
67 Qt5 Sensors library provides classes for reading sensor data.
68
69 %description -n Qt5Sensors -l pl.UTF-8
70 Biblioteka Qt5 Sensors dostarcza klasy do odczytu danych z czujników.
71
72 %package -n Qt5Sensors-devel
73 Summary:        Qt5 Sensors library - development files
74 Summary(pl.UTF-8):      Biblioteka Qt5 Sensors - pliki programistyczne
75 Group:          Development/Libraries
76 Requires:       Qt5Core-devel >= %{qtbase_ver}
77 Requires:       Qt5Sensors = %{version}-%{release}
78 Obsoletes:      qt5-qtsensors-devel
79
80 %description -n Qt5Sensors-devel
81 Qt5 Sensors library - development files.
82
83 %description -n Qt5Sensors-devel -l pl.UTF-8
84 Biblioteka Qt5 Sensors - pliki programistyczne.
85
86 %package doc
87 Summary:        Qt5 Sensors documentation in HTML format
88 Summary(pl.UTF-8):      Dokumentacja do biblioteki Qt5 Sensors w formacie HTML
89 Group:          Documentation
90 Requires:       qt5-doc-common >= %{qtbase_ver}
91 %if "%{_rpmversion}" >= "5"
92 BuildArch:      noarch
93 %endif
94
95 %description doc
96 Qt5 Sensors documentation in HTML format.
97
98 %description doc -l pl.UTF-8
99 Dokumentacja do biblioteki Qt5 Sensors w formacie HTML.
100
101 %package doc-qch
102 Summary:        Qt5 Sensors documentation in QCH format
103 Summary(pl.UTF-8):      Dokumentacja do biblioteki Qt5 Sensors w formacie QCH
104 Group:          Documentation
105 Requires:       qt5-doc-common >= %{qtbase_ver}
106 %if "%{_rpmversion}" >= "5"
107 BuildArch:      noarch
108 %endif
109
110 %description doc-qch
111 Qt5 Sensors documentation in QCH format.
112
113 %description doc-qch -l pl.UTF-8
114 Dokumentacja do biblioteki Qt5 Sensors w formacie QCH.
115
116 %package examples
117 Summary:        Qt5 Sensors examples
118 Summary(pl.UTF-8):      Przykłady do biblioteki Qt5 Sensors
119 Group:          X11/Development/Libraries
120 %if "%{_rpmversion}" >= "5"
121 BuildArch:      noarch
122 %endif
123
124 %description examples
125 Qt5 Sensors examples.
126
127 %description examples -l pl.UTF-8
128 Przykłady do biblioteki Qt5 Sensors.
129
130 %prep
131 %setup -q -n %{orgname}-opensource-src-%{version}
132
133 %build
134 qmake-qt5
135 %{__make}
136 %{__make} %{!?with_qch:html_}docs
137
138 %install
139 rm -rf $RPM_BUILD_ROOT
140 %{__make} install \
141         INSTALL_ROOT=$RPM_BUILD_ROOT
142
143 %{__make} install_%{!?with_qch:html_}docs \
144         INSTALL_ROOT=$RPM_BUILD_ROOT
145
146 # useless symlinks
147 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libQt5*.so.5.?
148 # actually drop *.la, follow policy of not packaging them when *.pc exist
149 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libQt5*.la
150
151 # Prepare some files list
152 ifecho() {
153         r="$RPM_BUILD_ROOT$2"
154         if [ -d "$r" ]; then
155                 echo "%%dir $2" >> $1.files
156         elif [ -x "$r" ] ; then
157                 echo "%%attr(755,root,root) $2" >> $1.files
158         elif [ -f "$r" ]; then
159                 echo "$2" >> $1.files
160         else
161                 echo "Error generation $1 files list!"
162                 echo "$r: no such file or directory!"
163                 return 1
164         fi
165 }
166 ifecho_tree() {
167         ifecho $1 $2
168         for f in `find $RPM_BUILD_ROOT$2 -printf "%%P "`; do
169                 ifecho $1 $2/$f
170         done
171 }
172
173 echo "%defattr(644,root,root,755)" > examples.files
174 ifecho_tree examples %{_examplesdir}/qt5/sensors
175
176 %clean
177 rm -rf $RPM_BUILD_ROOT
178
179 %post   -n Qt5Sensors -p /sbin/ldconfig
180 %postun -n Qt5Sensors -p /sbin/ldconfig
181
182 %files -n Qt5Sensors
183 %defattr(644,root,root,755)
184 %doc LGPL_EXCEPTION.txt dist/changes-*
185 %attr(755,root,root) %{_libdir}/libQt5Sensors.so.*.*.*
186 %attr(755,root,root) %ghost %{_libdir}/libQt5Sensors.so.5
187 %dir %{qt5dir}/plugins/sensorgestures
188 %attr(755,root,root) %{qt5dir}/plugins/sensorgestures/libqtsensorgestures_counterplugin.so
189 %attr(755,root,root) %{qt5dir}/plugins/sensorgestures/libqtsensorgestures_plugin.so
190 %attr(755,root,root) %{qt5dir}/plugins/sensorgestures/libqtsensorgestures_shakeplugin.so
191 %dir %{qt5dir}/plugins/sensors
192 %attr(755,root,root) %{qt5dir}/plugins/sensors/libqtsensors_generic.so
193 %attr(755,root,root) %{qt5dir}/plugins/sensors/libqtsensors_iio-sensor-proxy.so
194 %attr(755,root,root) %{qt5dir}/plugins/sensors/libqtsensors_linuxsys.so
195 %dir %{qt5dir}/qml/QtSensors
196 %attr(755,root,root) %{qt5dir}/qml/QtSensors/libdeclarative_sensors.so
197 %{qt5dir}/qml/QtSensors/plugins.qmltypes
198 %{qt5dir}/qml/QtSensors/qmldir
199
200 %files -n Qt5Sensors-devel
201 %defattr(644,root,root,755)
202 %attr(755,root,root) %{_libdir}/libQt5Sensors.so
203 %{_libdir}/libQt5Sensors.prl
204 %{_includedir}/qt5/QtSensors
205 %{_pkgconfigdir}/Qt5Sensors.pc
206 %{_libdir}/cmake/Qt5Sensors
207 %{qt5dir}/mkspecs/modules/qt_lib_sensors.pri
208 %{qt5dir}/mkspecs/modules/qt_lib_sensors_private.pri
209
210 %files doc
211 %defattr(644,root,root,755)
212 %{_docdir}/qt5-doc/qtsensors
213
214 %if %{with qch}
215 %files doc-qch
216 %defattr(644,root,root,755)
217 %{_docdir}/qt5-doc/qtsensors.qch
218 %endif
219
220 %files examples -f examples.files
221 %defattr(644,root,root,755)
222 # XXX: dir shared with qt5-qtbase-examples
223 %dir %{_examplesdir}/qt5
This page took 0.122749 seconds and 2 git commands to generate.