]> git.pld-linux.org Git - packages/qt5-qtserialport.git/blob - qt5-qtserialport.spec
- unconditional noarch subpackages
[packages/qt5-qtserialport.git] / qt5-qtserialport.spec
1 #
2 # Conditional build:
3 %bcond_without  doc     # Documentation
4
5 %define         orgname         qtserialport
6 %define         qtbase_ver      %{version}
7 %define         qttools_ver     %{version}
8 Summary:        The Qt5 SerialPort library
9 Summary(pl.UTF-8):      Biblioteka Qt5 SerialPort
10 Name:           qt5-%{orgname}
11 Version:        5.15.2
12 Release:        3
13 License:        LGPL v3 or GPL v2 or GPL v3 or commercial
14 Group:          Libraries
15 Source0:        http://download.qt.io/official_releases/qt/5.15/%{version}/submodules/%{orgname}-everywhere-src-%{version}.tar.xz
16 # Source0-md5:  ae1506fc8adc811e0aefff9aff70de3b
17 URL:            https://www.qt.io/
18 BuildRequires:  Qt5Core-devel >= %{qtbase_ver}
19 BuildRequires:  Qt5Gui-devel >= %{qtbase_ver}
20 BuildRequires:  Qt5Widgets-devel >= %{qtbase_ver}
21 %if %{with doc}
22 BuildRequires:  qt5-assistant >= %{qttools_ver}
23 %endif
24 BuildRequires:  qt5-build >= %{qtbase_ver}
25 BuildRequires:  qt5-qmake >= %{qtbase_ver}
26 BuildRequires:  rpmbuild(macros) >= 1.752
27 BuildRequires:  tar >= 1:1.22
28 BuildRequires:  udev-devel
29 BuildRequires:  xz
30 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32 %define         specflags       -fno-strict-aliasing
33 %define         qt5dir          %{_libdir}/qt5
34
35 %description
36 Qt is a cross-platform application and UI framework. Using Qt, you can
37 write web-enabled applications once and deploy them across desktop,
38 mobile and embedded systems without rewriting the source code.
39
40 This package contains Qt5 SerialPort library.
41
42 %description -l pl.UTF-8
43 Qt to wieloplatformowy szkielet aplikacji i interfejsów użytkownika.
44 Przy użyciu Qt można pisać aplikacje powiązane z WWW i wdrażać je w
45 systemach biurkowych, przenośnych i wbudowanych bez przepisywania kodu
46 źródłowego.
47
48 Ten pakiet zawiera bibliotekę Qt5 SerialPort.
49
50 %package -n Qt5SerialPort
51 Summary:        The Qt5 SerialPort library
52 Summary(pl.UTF-8):      Biblioteka Qt5 SerialPort
53 Group:          Libraries
54 Requires:       Qt5Core >= %{qtbase_ver}
55 Obsoletes:      qt5-qtserialport < 5.2.0-1
56
57 %description -n Qt5SerialPort
58 Qt5 SerialPort library provides classes that enable access to a serial
59 port.
60
61 %description -n Qt5SerialPort -l pl.UTF-8
62 Biblioteka Qt5 SerialPort udostępnia klasy pozwalające na dostęp do
63 portu szeregowego.
64
65 %package -n Qt5SerialPort-devel
66 Summary:        Qt5 SerialPort library - development files
67 Summary(pl.UTF-8):      Biblioteka Qt5 SerialPort - pliki programistyczne
68 Group:          Development/Libraries
69 Requires:       Qt5Core-devel >= %{qtbase_ver}
70 Requires:       Qt5SerialPort = %{version}-%{release}
71 Requires:       udev-devel
72 Obsoletes:      qt5-qtserialport-devel < 5.2.0-1
73
74 %description -n Qt5SerialPort-devel
75 Qt5 SerialPort library - development files.
76
77 %description -n Qt5SerialPort-devel -l pl.UTF-8
78 Biblioteka Qt5 SerialPort - pliki programistyczne.
79
80 %package doc
81 Summary:        Qt5 SerialPort documentation in HTML format
82 Summary(pl.UTF-8):      Dokumentacja do biblioteki Qt5 SerialPort w formacie HTML
83 Group:          Documentation
84 Requires:       qt5-doc-common >= %{qtbase_ver}
85 BuildArch:      noarch
86
87 %description doc
88 Qt5 SerialPort documentation in HTML format.
89
90 %description doc -l pl.UTF-8
91 Dokumentacja do biblioteki Qt5 SerialPort w formacie HTML.
92
93 %package doc-qch
94 Summary:        Qt5 SerialPort documentation in QCH format
95 Summary(pl.UTF-8):      Dokumentacja do biblioteki Qt5 SerialPort w formacie QCH
96 Group:          Documentation
97 Requires:       qt5-doc-common >= %{qtbase_ver}
98 BuildArch:      noarch
99
100 %description doc-qch
101 Qt5 SerialPort documentation in QCH format.
102
103 %description doc-qch -l pl.UTF-8
104 Dokumentacja do biblioteki Qt5 SerialPort w formacie QCH.
105
106 %package examples
107 Summary:        Qt5 SerialPort examples
108 Summary(pl.UTF-8):      Przykłady do biblioteki Qt5 SerialPort
109 Group:          Development/Libraries
110 BuildArch:      noarch
111
112 %description examples
113 Qt5 SerialPort examples.
114
115 %description examples -l pl.UTF-8
116 Przykłady do biblioteki Qt5 SerialPort.
117
118 %prep
119 %setup -q -n %{orgname}-everywhere-src-%{version}
120
121 %build
122 qmake-qt5
123 %{__make}
124 %{?with_doc:%{__make} docs}
125
126 %install
127 rm -rf $RPM_BUILD_ROOT
128
129 %{__make} install \
130         INSTALL_ROOT=$RPM_BUILD_ROOT
131
132 %if %{with doc}
133 %{__make} install_docs \
134         INSTALL_ROOT=$RPM_BUILD_ROOT
135 %endif
136
137 # useless symlinks
138 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libQt5*.so.5.??
139 # actually drop *.la, follow policy of not packaging them when *.pc exist
140 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libQt5*.la
141
142 # Prepare some files list
143 ifecho() {
144         r="$RPM_BUILD_ROOT$2"
145         if [ -d "$r" ]; then
146                 echo "%%dir $2" >> $1.files
147         elif [ -x "$r" ] ; then
148                 echo "%%attr(755,root,root) $2" >> $1.files
149         elif [ -f "$r" ]; then
150                 echo "$2" >> $1.files
151         else
152                 echo "Error generation $1 files list!"
153                 echo "$r: no such file or directory!"
154                 return 1
155         fi
156 }
157 ifecho_tree() {
158         ifecho $1 $2
159         for f in `find $RPM_BUILD_ROOT$2 -printf "%%P "`; do
160                 ifecho $1 $2/$f
161         done
162 }
163
164 echo "%defattr(644,root,root,755)" > examples.files
165 ifecho_tree examples %{_examplesdir}/qt5/serialport
166
167 %clean
168 rm -rf $RPM_BUILD_ROOT
169
170 %post   -n Qt5SerialPort -p /sbin/ldconfig
171 %postun -n Qt5SerialPort -p /sbin/ldconfig
172
173 %files -n Qt5SerialPort
174 %defattr(644,root,root,755)
175 %doc LICENSE.GPL3-EXCEPT dist/changes-*
176 %attr(755,root,root) %{_libdir}/libQt5SerialPort.so.*.*.*
177 %attr(755,root,root) %ghost %{_libdir}/libQt5SerialPort.so.5
178
179 %files -n Qt5SerialPort-devel
180 %defattr(644,root,root,755)
181 %attr(755,root,root) %{_libdir}/libQt5SerialPort.so
182 %{_libdir}/libQt5SerialPort.prl
183 %{_includedir}/qt5/QtSerialPort
184 %{_pkgconfigdir}/Qt5SerialPort.pc
185 %{_libdir}/cmake/Qt5SerialPort
186 %{qt5dir}/mkspecs/modules/qt_lib_serialport.pri
187 %{qt5dir}/mkspecs/modules/qt_lib_serialport_private.pri
188
189 %if %{with doc}
190 %files doc
191 %defattr(644,root,root,755)
192 %{_docdir}/qt5-doc/qtserialport
193
194 %files doc-qch
195 %defattr(644,root,root,755)
196 %{_docdir}/qt5-doc/qtserialport.qch
197 %endif
198
199 %files examples -f examples.files
200 %defattr(644,root,root,755)
201 # XXX: dir shared with qt5-qtbase-examples
202 %dir %{_examplesdir}/qt5
This page took 0.162722 seconds and 3 git commands to generate.