]>
Commit | Line | Data |
---|---|---|
4a2c2802 | 1 | # |
90c8b3d7 | 2 | # Conditional build: |
3c22fb66 | 3 | %bcond_without dbus # build without dbus support |
396eb448 | 4 | %bcond_without bluez # build without Bluetooth support |
d96c1154 | 5 | # |
90c8b3d7 | 6 | Summary: Service daemon for mediating access to a GPS |
7704e599 | 7 | Summary(pl.UTF-8): Oprogramowanie komunikujące się z GPS-em |
90c8b3d7 | 8 | Name: gpsd |
b7bddaef | 9 | Version: 3.10 |
ddd4352d | 10 | Release: 4 |
90c8b3d7 | 11 | License: BSD |
12 | Group: Daemons | |
4cf54e14 | 13 | Source0: http://download-mirror.savannah.gnu.org/releases/gpsd/%{name}-%{version}.tar.gz |
b7bddaef | 14 | # Source0-md5: fc5b03aae38b9b5b6880b31924d0ace3 |
b88610fc | 15 | Patch0: %{name}-link.patch |
52d28086 | 16 | Patch1: %{name}-qt.patch |
cb2fcfac | 17 | Patch2: %{name}-desktop.patch |
b7bddaef | 18 | Patch3: %{name}-destdir.patch |
4cf54e14 | 19 | URL: http://www.catb.org/gpsd/ |
396eb448 | 20 | BuildRequires: QtNetwork-devel >= 4.4 |
df34cb17 | 21 | %if %{with dbus} |
90c8b3d7 | 22 | BuildRequires: dbus-devel |
23 | BuildRequires: dbus-glib-devel | |
24 | %endif | |
396eb448 | 25 | %{?with_bluez:BuildRequires: bluez-libs-devel} |
76626dbc | 26 | BuildRequires: docbook-dtd412-xml |
9f13a9eb | 27 | BuildRequires: docbook-style-xsl |
4cf54e14 | 28 | BuildRequires: libcap-devel |
76626dbc | 29 | BuildRequires: libstdc++-devel |
396eb448 | 30 | BuildRequires: libusb-devel >= 1.0.0 |
76626dbc | 31 | BuildRequires: libxslt-progs |
4d5d1f20 | 32 | BuildRequires: ncurses-devel |
76626dbc | 33 | BuildRequires: pkgconfig |
4cf54e14 | 34 | BuildRequires: python-devel >= 1:2.5 |
396eb448 | 35 | BuildRequires: qt4-qmake >= 4.4 |
4116cf5e | 36 | BuildRequires: rpm-pythonprov |
4cf54e14 ER |
37 | BuildRequires: scons >= 2.0.1 |
38 | BuildRequires: sed >= 4.0 | |
76626dbc | 39 | BuildRequires: xmlto |
4d5d1f20 | 40 | Requires: %{name}-libs = %{version}-%{release} |
90c8b3d7 | 41 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
42 | ||
52d28086 | 43 | # libgpsd expects gpsd_report() defined by user |
d96c1154 | 44 | %define skip_post_check_so libgpsd\.so.* |
90c8b3d7 | 45 | |
83e6c4a2 JR |
46 | # note: to avoid recompiling/relinking on scons install, whole environment |
47 | # needs to be the same in both build and install sections | |
48 | %define scons_env \ | |
49 | CC="%{__cc}" \\\ | |
50 | CXX="%{__cxx}" \\\ | |
51 | CFLAGS="%{rpmcflags}" \\\ | |
52 | CXXFLAGS="%{rpmcxxflags}" \\\ | |
53 | CPPFLAGS="%{rpmcppflags}" \\\ | |
54 | LDFLAGS="%{rpmldflags}" | |
55 | ||
90c8b3d7 | 56 | %description |
57 | gpsd is a service daemon that mediates access to a GPS sensor | |
58 | connected to the host computer by serial or USB interface, making its | |
59 | data on the location/course/velocity of the sensor available to be | |
60 | queried on TCP port 2947 of the host computer. With gpsd, multiple GPS | |
61 | client applications (such as navigational and wardriving software) can | |
62 | share access to a GPS without contention or loss of data. Also, gpsd | |
63 | responds to queries with a format that is substantially easier to | |
64 | parse than NMEA 0183. A client library is provided for applications. | |
65 | ||
66 | After installing this RPM, gpsd will automatically connect to USB | |
67 | GPSes when they are plugged in and requires no configuration. For | |
68 | serial GPSes, you will need to start gpsd by hand. Once connected, the | |
69 | daemon automatically discovers the correct baudrate, stop bits, and | |
70 | protocol. The daemon will be quiescent when there are no clients | |
71 | asking for location information, and copes gracefully when the GPS is | |
72 | unplugged and replugged. | |
73 | ||
21673dc2 JR |
74 | %description -l pl.UTF-8 |
75 | gpsd to demon usługi pośredniczącej w dostępie do sensora GPS | |
76 | połączonego z komputerem poprzez interfejs szeregowy lub USB, | |
77 | udostępniający dane o położeniu, kierunku ruchu i prędkości z sensora | |
78 | na porcie TCP 2947 komputera. Przy użyciu gpsd wiele aplikacji | |
79 | klienckich GPS (takich jak oprogramowanie nawigacyjne) może | |
80 | współdzielić dostęp do GPS-a bez utraty danych. Ponadto gpsd odpowiada | |
81 | na zapytania w formacie znacznie łatwiejszym do przetworzenia niż NMEA | |
4d5d1f20 JB |
82 | 0183. Dostarczona jest biblioteka kliencka dla aplikacji. |
83 | ||
21673dc2 JR |
84 | Po zainstalowaniu tego pakietu gpsd będzie się automatycznie łączył z |
85 | GPS-ami USB po podłączeniu ich. Dla GPS-ów szeregowych trzeba | |
86 | uruchomić gpsd ręcznie. Po poączeniu demon automatycznie wykrywa | |
87 | właściwą prędkość, liczbę bitów stopu i protokół. Demon oczekuje | |
88 | spokojnie kiedy nie ma klientów i radzi sobie dobrze z odłączaniem i | |
89 | ponownym podłączaniem GPS-a. | |
4d5d1f20 | 90 | |
fe2d2d8e JB |
91 | %package -n udev-gpsd |
92 | Summary: UDEV support for GPS hotplugging | |
93 | Summary(pl.UTF-8): Obsługa UDEV-a do podłączania urządzeń GPS | |
94 | Group: Applications/System | |
95 | Requires: %{name} = %{version}-%{release} | |
96 | Requires: udev-core >= 1:127 | |
97 | ||
98 | %description -n udev-gpsd | |
99 | UDEV support for GPS hotplugging. | |
100 | ||
101 | %description -n udev-gpsd -l pl.UTF-8 | |
102 | Obsługa UDEV-a do podłączania urządzeń GPS. | |
103 | ||
4d5d1f20 | 104 | %package libs |
dc7c690b | 105 | Summary: GPSd client library |
106 | Summary(pl.UTF-8): Biblioteka kliencka GPSd | |
4d5d1f20 JB |
107 | Group: Libraries |
108 | ||
109 | %description libs | |
dc7c690b | 110 | GPSd client library. |
4d5d1f20 | 111 | |
21673dc2 | 112 | %description libs -l pl.UTF-8 |
dc7c690b | 113 | Biblioteka kliencka GPSd. |
4d5d1f20 JB |
114 | |
115 | %package devel | |
90c8b3d7 | 116 | Summary: Client libraries in C and Python for talking to a running gpsd or GPS |
7704e599 | 117 | Summary(pl.UTF-8): Biblioteki klienckie dla C i Pythona do komunikacji z gpsd lub GPS-em |
90c8b3d7 | 118 | Group: Development/Libraries |
4d5d1f20 | 119 | Requires: %{name}-libs = %{version}-%{release} |
396eb448 | 120 | Requires: libstdc++-devel |
52d28086 | 121 | Obsoletes: gpsd-static |
90c8b3d7 | 122 | |
4d5d1f20 | 123 | %description devel |
90c8b3d7 | 124 | This package provides C header files for the gpsd shared libraries |
125 | that manage access to a GPS for applications; also Python modules. You | |
126 | will need to have gpsd installed for it to work. | |
127 | ||
21673dc2 JR |
128 | %description devel -l pl.UTF-8 |
129 | Ten pakiet zawiera pliki nagłówkowe C dla bibliotek współdzielonych | |
130 | gpsd zarządzających dostępem do GPS-a dla aplikacji, a także moduły | |
131 | Pythona. Do działania bibliotek potrzebny jest gpsd. | |
4d5d1f20 | 132 | |
396eb448 JB |
133 | %package qt-libs |
134 | Summary: GPS Qt4 integration library | |
135 | Summary(pl.UTF-8): Biblioteka integrująca GPS z Qt4 | |
136 | Group: X11/Libraries | |
137 | Requires: %{name}-libs = %{version}-%{release} | |
138 | Requires: QtNetwork >= 4.4 | |
139 | ||
140 | %description qt-libs | |
141 | GPS Qt4 integration library. | |
142 | ||
143 | %description qt-libs -l pl.UTF-8 | |
144 | Biblioteka integrująca GPS z Qt4. | |
145 | ||
146 | %package qt-devel | |
147 | Summary: Development files for GPS Qt4 integration library | |
148 | Summary(pl.UTF-8): Pliki programistyczne biblioteki integrującej GPS z Qt4 | |
149 | Group: X11/Development/Libraries | |
150 | Requires: %{name}-devel = %{version}-%{release} | |
151 | Requires: %{name}-qt-libs = %{version}-%{release} | |
152 | Requires: QtNetwork-devel >= 4.4 | |
153 | ||
154 | %description qt-devel | |
155 | Development files for GPS Qt4 integration library. | |
156 | ||
157 | %description qt-devel -l pl.UTF-8 | |
158 | Pliki programistyczne biblioteki integrującej GPS z Qt4. | |
159 | ||
4116cf5e JK |
160 | %package -n python-gps |
161 | Summary: Python GPSd client library | |
162 | Summary(pl.UTF-8): Biblioteka kliencka GPSd dla Pythona | |
163 | Group: Libraries/Python | |
164 | Requires: %{name}-libs = %{version}-%{release} | |
165 | ||
166 | %description -n python-gps | |
167 | GPSd client library for Python. | |
168 | ||
169 | %description -n python-gps -l pl.UTF-8 | |
170 | Biblioteka kliencka GPSd dla Pythona. | |
171 | ||
4d5d1f20 | 172 | %package clients |
2f6e6399 JB |
173 | Summary: Clients for gpsd |
174 | Summary(pl.UTF-8): Aplikacje klienckie dla gpsd | |
175 | Group: Applications/System | |
176 | Requires: %{name}-libs = %{version}-%{release} | |
177 | ||
178 | %description clients | |
179 | cgps is a simple test client for gpsd. It displays current GPS | |
180 | position/time/velocity information and (for GPSes that support the | |
181 | feature) the locations of accessible satellites. cgps resembles xgps, | |
182 | but without the pictorial satellite display. It can run on a serial | |
183 | terminal or terminal emulator. | |
184 | ||
185 | %description clients -l pl.UTF-8 | |
186 | cgps to prosty klient testowy dla gpsd. Wyświetla bieżące informacje | |
187 | GPS o położeniu, czasie i prędkości oraz (w przypadku GPS-ów | |
188 | obsługujących to) położenia dostępnych satelitów. Jest podobny do | |
189 | xgps, ale nie ma rysunkowego przedstawiania satelitów. Może działać na | |
190 | terminalu szeregowym lub emulatorze terminala. | |
191 | ||
192 | %package clients-gui | |
90c8b3d7 | 193 | Summary: Clients for gpsd with an X interface |
7704e599 | 194 | Summary(pl.UTF-8): Aplikacje klienckie z interfejsem X |
90c8b3d7 | 195 | Group: Applications/System |
4d5d1f20 | 196 | Requires: %{name}-libs = %{version}-%{release} |
396eb448 JB |
197 | Requires: python-gps = %{version}-%{release} |
198 | Requires: python-pygtk-gtk >= 2:2.0 | |
90c8b3d7 | 199 | |
2f6e6399 | 200 | %description clients-gui |
90c8b3d7 | 201 | xgps is a simple test client for gpsd with an X interface. It displays |
202 | current GPS position/time/velocity information and (for GPSes that | |
203 | support the feature) the locations of accessible satellites. | |
204 | ||
205 | xgpsspeed is a speedometer that uses position information from the | |
2f6e6399 | 206 | GPS. |
90c8b3d7 | 207 | |
2f6e6399 | 208 | %description clients-gui -l pl.UTF-8 |
21673dc2 JR |
209 | xgps to prosty klient testowy dla gpsd z interfejsem X. Wyświetla |
210 | bieżące informacje GPS o położeniu, czasie i prędkości oraz (w | |
211 | przypadku GPS-ów obsługujących to) położenia dostępnych satelitów. | |
4d5d1f20 | 212 | |
21673dc2 | 213 | xgpsspeed to prędkościomierz używający informacji o położeniu z GPS-a. |
4d5d1f20 | 214 | |
90c8b3d7 | 215 | %prep |
216 | %setup -q | |
d96c1154 | 217 | %patch0 -p1 |
52d28086 | 218 | %patch1 -p1 |
cb2fcfac | 219 | %patch2 -p1 |
b7bddaef | 220 | %patch3 -p1 |
90c8b3d7 | 221 | |
222 | %build | |
83e6c4a2 JR |
223 | %scons_env \ |
224 | %scons \ | |
225 | libdir=%{_lib} \ | |
4cf54e14 ER |
226 | chrpath=False \ |
227 | shared=True \ | |
228 | strip=False \ | |
229 | systemd=True \ | |
230 | ncurses=True \ | |
231 | usb=True \ | |
52d28086 JB |
232 | %{!?with_bluez:bluez=False} \ |
233 | %{?with_dbus:dbus_export=True} | |
90c8b3d7 | 234 | |
d96c1154 | 235 | |
90c8b3d7 | 236 | %install |
237 | rm -rf $RPM_BUILD_ROOT | |
d96c1154 JB |
238 | |
239 | %scons_env \ | |
240 | DESTDIR=$RPM_BUILD_ROOT \ | |
83e6c4a2 | 241 | %scons udev-install |
d96c1154 JB |
242 | |
243 | # fix buggy libdir, kill -L/usr/* from qt Libs | |
244 | %{__sed} -i -e 's,^libdir=.*,libdir=%{_libdir},' \ | |
245 | -e 's,-L/[^ ]* *,,' \ | |
246 | $RPM_BUILD_ROOT%{_pkgconfigdir}/*.pc | |
247 | ||
248 | # invoke python directly | |
249 | %{__sed} -i -e '1s,/usr/bin/env python,/usr/bin/python,' \ | |
250 | $RPM_BUILD_ROOT%{_bindir}/{gpscat,gpsfake,gpsprof,xgps,xgpsspeed,gegps} | |
251 | ||
252 | # omitted from make install | |
253 | install gpsinit $RPM_BUILD_ROOT%{_sbindir} | |
254 | install -Dp dgpsip-servers $RPM_BUILD_ROOT%{_datadir}/gpsd/dgpsip-servers | |
255 | cp -p gpsd.h $RPM_BUILD_ROOT%{_includedir} | |
256 | ||
52d28086 JB |
257 | #install packaging/rpm/gpsd.init $RPM_BUILD_ROOT/etc/rc.d/init.d/gpsd |
258 | #install packaging/rpm/gpsd.sysconfig $RPM_BUILD_ROOT/etc/sysconfig/gpsd | |
fe2d2d8e | 259 | install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}} |
4cf54e14 ER |
260 | cp -p packaging/X11/{xgps,xgpsspeed}.desktop $RPM_BUILD_ROOT%{_desktopdir} |
261 | cp -p packaging/X11/gpsd-logo.png $RPM_BUILD_ROOT%{_pixmapsdir} | |
fe2d2d8e | 262 | |
378fdacb | 263 | %py_comp $RPM_BUILD_ROOT%{py_sitedir} |
264 | %py_ocomp $RPM_BUILD_ROOT%{py_sitedir} | |
4116cf5e JK |
265 | %py_postclean |
266 | ||
d96c1154 JB |
267 | # symlinks not needed |
268 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/lib*.so.??.0 | |
269 | ||
90c8b3d7 | 270 | %clean |
271 | rm -rf $RPM_BUILD_ROOT | |
272 | ||
4d5d1f20 JB |
273 | %post libs -p /sbin/ldconfig |
274 | %postun libs -p /sbin/ldconfig | |
90c8b3d7 | 275 | |
396eb448 JB |
276 | %post qt-libs -p /sbin/ldconfig |
277 | %postun qt-libs -p /sbin/ldconfig | |
278 | ||
90c8b3d7 | 279 | %files |
280 | %defattr(644,root,root,755) | |
dc7c690b | 281 | %doc README INSTALL COPYING TODO AUTHORS |
810597c4 | 282 | %attr(755,root,root) %{_bindir}/gpsmon |
52d28086 JB |
283 | %attr(755,root,root) %{_sbindir}/gpsd |
284 | %attr(755,root,root) %{_sbindir}/gpsdctl | |
d96c1154 | 285 | %attr(755,root,root) %{_sbindir}/gpsinit |
810597c4 | 286 | %{_mandir}/man1/gpsmon.1* |
52d28086 JB |
287 | %{_mandir}/man8/gpsd.8* |
288 | %{_mandir}/man8/gpsdctl.8* | |
d96c1154 | 289 | %{_mandir}/man8/gpsinit.8* |
fe2d2d8e JB |
290 | %dir %{_datadir}/gpsd |
291 | %{_datadir}/gpsd/dgpsip-servers | |
292 | ||
293 | %files -n udev-gpsd | |
294 | %defattr(644,root,root,755) | |
52d28086 | 295 | %attr(755,root,root) /lib/udev/gpsd.hotplug |
4cf54e14 | 296 | /lib/udev/rules.d/25-gpsd.rules |
52d28086 | 297 | #%attr(754,root,root) /etc/rc.d/init.d/gpsd |
378fdacb | 298 | #%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/gpsd |
4a2c2802 | 299 | |
4d5d1f20 | 300 | %files libs |
90c8b3d7 | 301 | %defattr(644,root,root,755) |
83ef144b | 302 | %attr(755,root,root) %{_libdir}/libgpsd.so.*.*.* |
b7bddaef | 303 | %attr(755,root,root) %ghost %{_libdir}/libgpsd.so.22 |
4d5d1f20 | 304 | %attr(755,root,root) %{_libdir}/libgps.so.*.*.* |
b7bddaef | 305 | %attr(755,root,root) %ghost %{_libdir}/libgps.so.21 |
90c8b3d7 | 306 | |
4d5d1f20 | 307 | %files devel |
90c8b3d7 | 308 | %defattr(644,root,root,755) |
810597c4 | 309 | %attr(755,root,root) %{_bindir}/gpsdecode |
4d5d1f20 | 310 | %attr(755,root,root) %{_libdir}/libgps.so |
b88610fc | 311 | %attr(755,root,root) %{_libdir}/libgpsd.so |
90c8b3d7 | 312 | %{_includedir}/gps.h |
90c8b3d7 | 313 | %{_includedir}/gpsd.h |
2f6e6399 | 314 | %{_includedir}/libgpsmm.h |
2bfd87da JB |
315 | %{_pkgconfigdir}/libgps.pc |
316 | %{_pkgconfigdir}/libgpsd.pc | |
810597c4 | 317 | %{_mandir}/man1/gpsdecode.1* |
90c8b3d7 | 318 | %{_mandir}/man3/libgps.3* |
90c8b3d7 | 319 | %{_mandir}/man3/libgpsd.3* |
2f6e6399 | 320 | %{_mandir}/man3/libgpsmm.3* |
52d28086 | 321 | %{_mandir}/man5/gpsd_json.5* |
90c8b3d7 | 322 | %{_mandir}/man5/srec.5* |
4d5d1f20 | 323 | |
396eb448 JB |
324 | %files qt-libs |
325 | %defattr(644,root,root,755) | |
326 | %attr(755,root,root) %{_libdir}/libQgpsmm.so.*.*.* | |
b7bddaef | 327 | %attr(755,root,root) %ghost %{_libdir}/libQgpsmm.so.21 |
396eb448 JB |
328 | |
329 | %files qt-devel | |
330 | %defattr(644,root,root,755) | |
331 | %attr(755,root,root) %{_libdir}/libQgpsmm.so | |
52d28086 | 332 | %{_mandir}/man3/libQgpsmm.3* |
d96c1154 JB |
333 | %{_libdir}/libQgpsmm.prl |
334 | %{_pkgconfigdir}/Qgpsmm.pc | |
396eb448 | 335 | |
4116cf5e JK |
336 | %files -n python-gps |
337 | %defattr(644,root,root,755) | |
52d28086 | 338 | %attr(755,root,root) %{_bindir}/gegps |
2f6e6399 JB |
339 | %attr(755,root,root) %{_bindir}/gpscat |
340 | %attr(755,root,root) %{_bindir}/gpsfake | |
341 | %attr(755,root,root) %{_bindir}/gpsprof | |
378fdacb | 342 | %dir %{py_sitedir}/gps |
343 | %attr(755,root,root) %{py_sitedir}/gps/*.so | |
344 | %{py_sitedir}/gps/*.py[co] | |
52d28086 JB |
345 | %{py_sitedir}/gps-%{version}.egg-info |
346 | %{_mandir}/man1/gegps.1* | |
2f6e6399 JB |
347 | %{_mandir}/man1/gpscat.1* |
348 | %{_mandir}/man1/gpsfake.1* | |
349 | %{_mandir}/man1/gpsprof.1* | |
4116cf5e | 350 | |
4d5d1f20 JB |
351 | %files clients |
352 | %defattr(644,root,root,755) | |
b7bddaef | 353 | %attr(755,root,root) %{_bindir}/gps2udp |
dc7c690b | 354 | %attr(755,root,root) %{_bindir}/gpsctl |
4d5d1f20 JB |
355 | %attr(755,root,root) %{_bindir}/cgps |
356 | %attr(755,root,root) %{_bindir}/gpspipe | |
3c22fb66 | 357 | %{?with_dbus:%attr(755,root,root) %{_bindir}/gpxlogger} |
b7bddaef | 358 | %{_mandir}/man1/gps2udp.1* |
dc7c690b | 359 | %{_mandir}/man1/gpsctl.1* |
a7db052a | 360 | %{_mandir}/man1/cgps.1* |
a7db052a | 361 | %{_mandir}/man1/gps.1* |
4d5d1f20 | 362 | %{_mandir}/man1/gpspipe.1* |
2f6e6399 | 363 | |
2f6e6399 JB |
364 | %files clients-gui |
365 | %defattr(644,root,root,755) | |
810597c4 | 366 | %attr(755,root,root) %{_bindir}/lcdgps |
2f6e6399 JB |
367 | %attr(755,root,root) %{_bindir}/xgps |
368 | %attr(755,root,root) %{_bindir}/xgpsspeed | |
b88610fc | 369 | %{_mandir}/man1/lcdgps.1* |
2f6e6399 JB |
370 | %{_mandir}/man1/xgps.1* |
371 | %{_mandir}/man1/xgpsspeed.1* | |
fe2d2d8e JB |
372 | %{_desktopdir}/xgps.desktop |
373 | %{_desktopdir}/xgpsspeed.desktop | |
374 | %{_pixmapsdir}/gpsd-logo.png |