1 |
ahmad |
24452 |
%define _hotplugdir %{_prefix}/lib/hotplug |
2 |
|
|
|
3 |
|
|
%define major 19 |
4 |
|
|
%define gpsd_major 0 |
5 |
|
|
%define libname %mklibname %{name} %{major} |
6 |
|
|
%define libqtname %mklibname Qgpsmm %{major} |
7 |
|
|
%define develname %mklibname %{name} -d |
8 |
|
|
%define staticname %mklibname %{name} -s -d |
9 |
|
|
|
10 |
|
|
Name: gpsd |
11 |
|
|
Summary: GPS data translator and GUI |
12 |
|
|
Version: 2.95 |
13 |
ahmad |
24617 |
Release: %mkrel 4 |
14 |
ahmad |
24452 |
Source0: http://prdownload.berlios.de/%{name}/%{name}-%{version}.tar.gz |
15 |
ahmad |
24617 |
#Patch1: gpsd-2.90-udev.patch |
16 |
ahmad |
24452 |
Patch2: gpsd-2.95-fix-link.patch |
17 |
ahmad |
24617 |
# (Fedora) make 'make' not ignore -w even when it's used |
18 |
|
|
Patch3: gpsd-2.95-silentmake.patch |
19 |
|
|
# (Fedora) add /usr/sbin/ to PATH in gpsd.hotplug.wrapper |
20 |
|
|
Patch4: gpsd-2.95-hotplugvars.patch |
21 |
|
|
# (Fedora) add patch to prevent a crash in gpscat when started without arguments; |
22 |
|
|
# and instead of crashing show the usage output |
23 |
|
|
Patch5: gpsd-2.95-gpscatnoarg.patch |
24 |
ahmad |
24452 |
URL: http://gpsd.berlios.de |
25 |
|
|
License: BSD |
26 |
|
|
Group: Sciences/Geosciences |
27 |
|
|
Provides: gps3d |
28 |
|
|
Obsoletes: gps3d |
29 |
|
|
BuildRequires: ncurses-devel |
30 |
|
|
BuildRequires: udev-tools |
31 |
|
|
BuildRequires: lesstif-devel |
32 |
|
|
BuildRequires: xmlto |
33 |
|
|
BuildRequires: dbus-devel |
34 |
|
|
BuildRequires: dbus-glib-devel |
35 |
|
|
BuildRequires: python |
36 |
|
|
BuildRequires: python-devel |
37 |
|
|
BuildRequires: bluez-devel |
38 |
|
|
BuildRequires: qt4-devel |
39 |
|
|
Requires: %{name}-python = %{version}-%{release} |
40 |
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot |
41 |
|
|
|
42 |
|
|
%description |
43 |
|
|
gpsd is a service daemon that mediates access to a GPS sensor |
44 |
|
|
connected to the host computer by serial or USB interface, making its |
45 |
|
|
data on the location/course/velocity of the sensor available to be |
46 |
|
|
queried on TCP port 2947 of the host computer. With gpsd, multiple |
47 |
|
|
GPS client applications (such as navigational and wardriving software) |
48 |
|
|
can share access to a GPS without contention or loss of data. Also, |
49 |
|
|
gpsd responds to queries with a format that is substantially easier to |
50 |
|
|
parse than NMEA 0183. A client library is provided for applications. |
51 |
|
|
|
52 |
|
|
After installing this RPM, gpsd will automatically connect to USB |
53 |
|
|
GPSes when they are plugged in and requires no configuration. For |
54 |
|
|
serial GPSes, you will need to start gpsd by hand. Once connected, |
55 |
|
|
the daemon automatically discovers the correct baudrate, stop bits, |
56 |
|
|
and protocol. The daemon will be quiescent when there are no |
57 |
|
|
clients asking for location information, and copes gracefully when the |
58 |
|
|
GPS is unplugged and replugged. |
59 |
|
|
|
60 |
|
|
%package -n %{libname} |
61 |
|
|
Summary: Libraries for gpsd |
62 |
|
|
Group: System/Libraries |
63 |
|
|
Obsoletes: %{mklibname gpsd 15} > 2.34 |
64 |
|
|
|
65 |
|
|
%description -n %{libname} |
66 |
|
|
gpsd is a service daemon that mediates access to a GPS sensor |
67 |
|
|
connected to the host computer by serial or USB interface, making its |
68 |
|
|
data on the location/course/velocity of the sensor available to be |
69 |
|
|
queried on TCP port 2947 of the host computer. With gpsd, multiple |
70 |
|
|
GPS client applications (such as navigational and wardriving software) |
71 |
|
|
can share access to a GPS without contention or loss of data. Also, |
72 |
|
|
gpsd responds to queries with a format that is substantially easier to |
73 |
|
|
parse than NMEA 0183. A client library is provided for applications. |
74 |
|
|
|
75 |
|
|
After installing this RPM, gpsd will automatically connect to USB |
76 |
|
|
GPSes when they are plugged in and requires no configuration. For |
77 |
|
|
serial GPSes, you will need to start gpsd by hand. Once connected, |
78 |
|
|
the daemon automatically discovers the correct baudrate, stop bits, |
79 |
|
|
and protocol. The daemon will be quiescent when there are no |
80 |
|
|
clients asking for location information, and copes gracefully when the |
81 |
|
|
GPS is unplugged and replugged. |
82 |
|
|
|
83 |
|
|
%package -n %{libqtname} |
84 |
|
|
Summary: Qt bindings for gpsd |
85 |
|
|
Group: System/Libraries |
86 |
|
|
|
87 |
|
|
%description -n %{libqtname} |
88 |
|
|
This package contains Qt bindings for gpsd. |
89 |
|
|
|
90 |
|
|
%package -n %{develname} |
91 |
|
|
Summary: Client libraries in C and Python for talking to a running gpsd or GPS |
92 |
|
|
Group: Development/C |
93 |
|
|
Provides: %{name}-devel = %{version}-%{release} |
94 |
|
|
Provides: lib%{name}-devel = %{version}-%{release} |
95 |
|
|
Requires: %{libname} = %{version} |
96 |
|
|
Requires: %{libqtname} = %{version} |
97 |
|
|
Obsoletes: %{mklibname gpsd 15 -d} |
98 |
|
|
|
99 |
|
|
%description -n %{develname} |
100 |
|
|
This package provides C header files for the gpsd shared libraries |
101 |
|
|
that manage access to a GPS for applications; also Python modules. |
102 |
|
|
You will need to have gpsd installed for it to work. |
103 |
|
|
|
104 |
|
|
%package -n %{staticname} |
105 |
|
|
Summary: Static libraries for gpsd |
106 |
|
|
Group: Development/C |
107 |
|
|
Provides: %{name}-static-devel = %{version}-%{release} |
108 |
|
|
Provides: lib%{name}-static-devel = %{version}-%{release} |
109 |
|
|
Requires: %{develname} = %{version} |
110 |
|
|
Obsoletes: %{mklibname gpsd 15 -s -d} |
111 |
|
|
|
112 |
|
|
%description -n %{staticname} |
113 |
|
|
This package provides C header files for the gpsd shared libraries |
114 |
|
|
that manage access to a GPS for applications; also Python modules. |
115 |
|
|
You will need to have gpsd installed for it to work. |
116 |
|
|
|
117 |
|
|
%package clients |
118 |
|
|
Summary: Clients for gpsd with an X interface |
119 |
|
|
Group: Sciences/Geosciences |
120 |
|
|
|
121 |
|
|
%description clients |
122 |
|
|
xgps is a simple test client for gpsd with an X interface. It displays |
123 |
|
|
current GPS position/time/velocity information and (for GPSes that |
124 |
|
|
support the feature) the locations of accessible satellites. |
125 |
|
|
|
126 |
|
|
xgpsspeed is a speedometer that uses position information from the GPS. |
127 |
|
|
It accepts an -h option and optional argument as for gps, or a -v option |
128 |
|
|
to dump the package version and exit. Additionally, it accepts -rv |
129 |
|
|
(reverse video) and -nc (needle color) options. |
130 |
|
|
|
131 |
|
|
%package python |
132 |
|
|
Summary: Python bindings for gpsd |
133 |
|
|
Group: Development/Python |
134 |
|
|
Requires: %{libname} = %{version} |
135 |
|
|
Requires: python |
136 |
|
|
|
137 |
|
|
%description python |
138 |
|
|
This package contains the Python bindings for gpsd. It will be needed |
139 |
|
|
for any applications that interface with gpsd via python. |
140 |
|
|
|
141 |
|
|
%prep |
142 |
|
|
%setup -q |
143 |
ahmad |
24617 |
#%patch1 -p1 -b .udev |
144 |
ahmad |
24452 |
%patch2 -p0 -b .link |
145 |
|
|
|
146 |
ahmad |
24617 |
%patch3 -p1 -b .silentmake |
147 |
|
|
%patch4 -p1 -b .hotplugvars |
148 |
|
|
%patch5 -p1 -b .gpscatnoargs |
149 |
|
|
|
150 |
ahmad |
24452 |
%build |
151 |
|
|
%configure2_5x --enable-dbus --enable-bluetooth |
152 |
|
|
|
153 |
|
|
%make |
154 |
|
|
|
155 |
|
|
%install |
156 |
|
|
rm -rf %{buildroot} |
157 |
|
|
|
158 |
ahmad |
24617 |
%makeinstall_std pythondir=%{py_platsitedir} |
159 |
ahmad |
24452 |
|
160 |
ahmad |
24617 |
# install udev rules |
161 |
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/udev/rules.d |
162 |
|
|
install -p -m 0644 gpsd.rules %{buildroot}%{_sysconfdir}/udev/rules.d/99-gpsd.rules |
163 |
ahmad |
24452 |
|
164 |
ahmad |
24617 |
install -d -m 0755 %{buildroot}%{_sysconfdir}/udev/agents.d/usb |
165 |
ahmad |
24452 |
install -m755 gpsd.hotplug %{buildroot}%{_sysconfdir}/udev/agents.d/usb/gpsd |
166 |
|
|
|
167 |
ahmad |
24617 |
# make gps.py executable |
168 |
|
|
chmod a+x %{buildroot}%{py_platsitedir}/gps/gps.py |
169 |
ahmad |
24452 |
|
170 |
ahmad |
24617 |
# install init scripts |
171 |
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/init.d |
172 |
|
|
install -p -m 0755 packaging/rpm/gpsd.init %{buildroot}%{_sysconfdir}/init.d/gpsd |
173 |
ahmad |
24452 |
|
174 |
ahmad |
24617 |
# install sysconfig file |
175 |
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/sysconfig |
176 |
|
|
install -p -m 0644 packaging/rpm/gpsd.sysconfig %{buildroot}%{_sysconfdir}/sysconfig/gpsd |
177 |
ahmad |
24452 |
|
178 |
ahmad |
24617 |
# install hotplug script |
179 |
|
|
install -d -m 0755 %{buildroot}/lib/udev |
180 |
|
|
install -p -m 0755 gpsd.hotplug gpsd.hotplug.wrapper %{buildroot}/lib/udev |
181 |
ahmad |
24452 |
|
182 |
ahmad |
24617 |
# install .desktop files |
183 |
|
|
install -d -m 0755 %{buildroot}%{_datadir}/applications/ |
184 |
|
|
install -m644 packaging/X11/xgps.desktop %{buildroot}%{_datadir}/applications/ |
185 |
|
|
install -m644 packaging/X11/xgpsspeed.desktop %{buildroot}%{_datadir}/applications/ |
186 |
ahmad |
24452 |
|
187 |
ahmad |
24617 |
# install logo for the .desktop file |
188 |
|
|
install -d -m 0755 %{buildroot}%{_datadir}/gpsd |
189 |
|
|
install -m644 packaging/X11/gpsd-logo.png %{buildroot}%{_datadir}/gpsd/gpsd-logo.png |
190 |
ahmad |
24452 |
|
191 |
|
|
rm -rf %{buildroot}%{_libdir}/*.la |
192 |
|
|
|
193 |
ahmad |
24617 |
%post |
194 |
|
|
%_post_service %{name} |
195 |
ahmad |
24452 |
|
196 |
ahmad |
24617 |
%preun |
197 |
|
|
%_preun_service %{name} |
198 |
ahmad |
24452 |
|
199 |
|
|
%clean |
200 |
|
|
rm -rf %{buildroot} |
201 |
|
|
|
202 |
|
|
%files |
203 |
|
|
%defattr(-,root,root,-) |
204 |
|
|
%doc README |
205 |
|
|
%{_sbindir}/gpsd |
206 |
|
|
%{_bindir}/gpscat |
207 |
|
|
%{_bindir}/gpsctl |
208 |
|
|
%{_bindir}/gpsprof |
209 |
|
|
%{_bindir}/gpsmon |
210 |
|
|
%{_bindir}/gpsdecode |
211 |
ahmad |
24617 |
/lib/udev/gpsd.hotplug |
212 |
|
|
/lib/udev/gpsd.hotplug.wrapper |
213 |
ahmad |
24452 |
%{_mandir}/man8/gpsd.8* |
214 |
|
|
%{_mandir}/man1/gpsprof.1* |
215 |
|
|
%{_mandir}/man1/gps.1* |
216 |
|
|
%{_mandir}/man1/gpscat.1* |
217 |
|
|
%{_mandir}/man1/gpsctl.1* |
218 |
|
|
%{_mandir}/man1/gpsmon.1* |
219 |
|
|
%{_mandir}/man1/gpsdecode.1* |
220 |
|
|
%{_mandir}/man5/rtcm*.5* |
221 |
|
|
%{_mandir}/man5/srec.5* |
222 |
|
|
%{_sysconfdir}/init.d/%{name} |
223 |
|
|
%config(noreplace) %{_sysconfdir}/sysconfig/%{name} |
224 |
|
|
%{_sysconfdir}/udev/agents.d/usb/gpsd |
225 |
ahmad |
24617 |
%{_sysconfdir}/udev/rules.d/99-gpsd.rules |
226 |
ahmad |
24452 |
|
227 |
|
|
%files -n %{libname} |
228 |
|
|
%defattr(-,root,root) |
229 |
|
|
%{_libdir}/libgps.so.%{major}* |
230 |
|
|
%{_libdir}/libgpsd.so.%{gpsd_major}* |
231 |
|
|
|
232 |
|
|
%files -n %{libqtname} |
233 |
|
|
%defattr(-,root,root) |
234 |
|
|
%{_libdir}/libQgpsmm.so.%{major}* |
235 |
|
|
|
236 |
|
|
%files -n %{develname} |
237 |
|
|
%defattr(-,root,root,-) |
238 |
|
|
%doc TODO |
239 |
|
|
%{_includedir}/gps.h |
240 |
|
|
%{_includedir}/libgpsmm.h |
241 |
|
|
%{_includedir}/gpsd.h |
242 |
|
|
%{_libdir}/libgps.so |
243 |
|
|
%{_libdir}/libgpsd.so |
244 |
|
|
%{_libdir}/libQgpsmm.so |
245 |
|
|
%{_libdir}/pkgconfig/*.pc |
246 |
|
|
%{_mandir}/man1/gpsfake.1* |
247 |
|
|
%{_mandir}/man3/libgps.3* |
248 |
|
|
%{_mandir}/man3/libgpsmm.3* |
249 |
|
|
%{_mandir}/man3/libgpsd.3* |
250 |
|
|
%{_bindir}/gpsfake |
251 |
|
|
|
252 |
|
|
%files -n %{staticname} |
253 |
|
|
%defattr(-,root,root) |
254 |
|
|
%{_libdir}/*.a |
255 |
|
|
|
256 |
|
|
%files clients |
257 |
|
|
%defattr(-,root,root,-) |
258 |
|
|
%{_bindir}/xgps |
259 |
|
|
%{_bindir}/cgps |
260 |
|
|
%{_bindir}/gpspipe |
261 |
|
|
%{_bindir}/xgpsspeed |
262 |
|
|
%{_bindir}/gpxlogger |
263 |
|
|
%{_bindir}/lcdgps |
264 |
|
|
%{_mandir}/man1/xgps.1* |
265 |
|
|
%{_mandir}/man1/cgps.1* |
266 |
|
|
%{_mandir}/man1/gpspipe.1* |
267 |
|
|
%{_mandir}/man1/lcdgps.1.* |
268 |
|
|
%{_mandir}/man1/xgpsspeed.1* |
269 |
ahmad |
24617 |
%{_datadir}/applications/xgps.desktop |
270 |
|
|
%{_datadir}/applications/xgpsspeed.desktop |
271 |
|
|
%{_datadir}/gpsd/gpsd-logo.png |
272 |
ahmad |
24452 |
|
273 |
|
|
%files python |
274 |
|
|
%defattr(-,root,root,-) |
275 |
|
|
%{py_platsitedir}/* |