gpsd-vl.spec 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305
  1. %{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
  2. %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")
  3. Summary: Service daemon for mediating access to a GPS
  4. Summary(ja): GPS にアクセスするためのサービスデーモン
  5. Name: gpsd
  6. Version: 2.95
  7. Release: 2%{?_dist_release}
  8. Group: System Environment/Daemons
  9. License: BSD
  10. URL: http://developer.berlios.de/projects/gpsd/
  11. Source0: http://download.berlios.de/gpsd/%{name}-%{version}.tar.gz
  12. Source10: gpsd.init
  13. Source11: gpsd.sysconfig
  14. Patch0: gpsd-2.95-silentmake.patch
  15. Patch1: gpsd-2.95-hotplugvars.patch
  16. BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
  17. BuildRequires: dbus-devel dbus-glib-devel ncurses-devel xmlto python-devel
  18. BuildRequires: libusb1-devel desktop-file-utils
  19. BuildRequires: libudev-devel
  20. Requires: udev
  21. Requires(post): /sbin/ldconfig
  22. Requires(post): /sbin/chkconfig
  23. Requires(preun): initscripts
  24. Requires(preun): /sbin/chkconfig
  25. Requires(postun): /sbin/ldconfig
  26. %description
  27. gpsd is a service daemon that mediates access to a GPS sensor
  28. connected to the host computer by serial or USB interface, making its
  29. data on the location/course/velocity of the sensor available to be
  30. queried on TCP port 2947 of the host computer. With gpsd, multiple
  31. GPS client applications (such as navigational and wardriving software)
  32. can share access to a GPS without contention or loss of data. Also,
  33. gpsd responds to queries with a format that is substantially easier to
  34. parse than NMEA 0183.
  35. %package devel
  36. Summary: Client libraries in C and Python for talking to a running gpsd or GPS
  37. Group: Development/Libraries
  38. Requires: %{name} = %{version}-%{release}
  39. Requires: pkgconfig
  40. %description devel
  41. This package provides C header files and python modules for the gpsd shared
  42. libraries that manage access to a GPS for applications
  43. %package clients
  44. Summary: Clients for gpsd
  45. Summary(ja): gpsd 用クライアント
  46. Group: Applications/System
  47. %description clients
  48. xgps is a simple test client for gpsd with an X interface. It displays
  49. current GPS position/time/velocity information and (for GPSes that
  50. support the feature) the locations of accessible satellites.
  51. xgpsspeed is a speedometer that uses position information from the GPS.
  52. It accepts an -h option and optional argument as for gps, or a -v option
  53. to dump the package version and exit. Additionally, it accepts -rv
  54. (reverse video) and -nc (needle color) options.
  55. cgps resembles xgps, but without the pictorial satellite display. It
  56. can run on a serial terminal or terminal emulator.
  57. %prep
  58. %setup -q
  59. %patch0 -p1 -b .silentmake
  60. %patch1 -p1 -b .hotplugvars
  61. %build
  62. %configure --enable-dbus --disable-static --disable-libQgpsmm
  63. sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
  64. sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
  65. make %{?_smp_mflags}
  66. %install
  67. rm -rf %{buildroot}
  68. make DESTDIR=%{buildroot} install
  69. # init scripts
  70. %{__install} -d -m 0755 %{buildroot}%{_sysconfdir}/init.d
  71. %{__install} -p -m 0755 %{SOURCE10} \
  72. %{buildroot}%{_sysconfdir}/init.d/gpsd
  73. %{__install} -d -m 0755 %{buildroot}%{_sysconfdir}/sysconfig
  74. %{__install} -p -m 0644 %{SOURCE11} \
  75. %{buildroot}%{_sysconfdir}/sysconfig/gpsd
  76. # udev rules
  77. %{__install} -d -m 0755 %{buildroot}%{_sysconfdir}/udev/rules.d
  78. %{__install} -p -m 0644 gpsd.rules \
  79. %{buildroot}%{_sysconfdir}/udev/rules.d/99-gpsd.rules
  80. # hotplug script
  81. %{__install} -d -m 0755 %{buildroot}/lib/udev
  82. %{__install} -p -m 0755 gpsd.hotplug gpsd.hotplug.wrapper %{buildroot}/lib/udev
  83. # remove .la files
  84. find %{buildroot} -name '*.la' -exec rm -f {} ';'
  85. # fix non-executable python script
  86. %{__chmod} +x %{buildroot}%{python_sitearch}/gps/gps.py
  87. # Install the .desktop files
  88. desktop-file-install --vendor fedora \
  89. --dir %{buildroot}%{_datadir}/applications \
  90. --add-category X-Fedora \
  91. packaging/X11/xgps.desktop
  92. desktop-file-install --vendor fedora \
  93. --dir %{buildroot}%{_datadir}/applications \
  94. --add-category X-Fedora \
  95. packaging/X11/xgpsspeed.desktop
  96. # Install logo icon for .desktop files
  97. %{__install} -d -m 0755 %{buildroot}%{_datadir}/gpsd
  98. %{__install} -p -m 0644 packaging/X11/gpsd-logo.png %{buildroot}%{_datadir}/gpsd/gpsd-logo.png
  99. %clean
  100. rm -rf %{buildroot}
  101. %post
  102. /sbin/ldconfig
  103. /sbin/chkconfig --add %{name}
  104. %preun
  105. if [ $1 = 0 ]; then
  106. /sbin/service %{name} stop > /dev/null 2>&1 || true
  107. /sbin/chkconfig --del %{name}
  108. fi
  109. %postun -p /sbin/ldconfig
  110. %files
  111. %defattr(-,root,root,-)
  112. %doc README INSTALL COPYING
  113. %config(noreplace) %{_sysconfdir}/init.d/%{name}
  114. %config(noreplace) %{_sysconfdir}/sysconfig/%{name}
  115. %config(noreplace) %{_sysconfdir}/udev/rules.d/*
  116. %{_sbindir}/gpsd
  117. %{_bindir}/gpsprof
  118. %{_bindir}/gpsmon
  119. %{_bindir}/gpsctl
  120. %{_libdir}/libgps*.so.*
  121. /lib/udev/gpsd*
  122. %{python_sitearch}/gps*
  123. %exclude %{python_sitearch}/gps/fake*
  124. %ifarch x86_64
  125. %{python_sitelib}/gps*
  126. %endif
  127. %{_mandir}/man8/gpsd.8*
  128. %{_mandir}/man1/gpsprof.1*
  129. %{_mandir}/man1/gpsmon.1*
  130. %{_mandir}/man1/gpsctl.1*
  131. %files devel
  132. %defattr(-,root,root,-)
  133. %doc TODO
  134. %{_bindir}/gpsfake
  135. %{_libdir}/libgps*.so
  136. %{_libdir}/pkgconfig/*.pc
  137. %{python_sitearch}/gps/fake*
  138. %{_includedir}/gps.h
  139. %{_includedir}/libgpsmm.h
  140. %{_includedir}/gpsd.h
  141. %{_mandir}/man1/gpsfake.1*
  142. %{_mandir}/man3/libgps.3*
  143. %{_mandir}/man3/libgpsmm.3*
  144. %{_mandir}/man3/libgpsd.3*
  145. %{_mandir}/man5/rtcm-104.5*
  146. %{_mandir}/man5/srec.5*
  147. %files clients
  148. %defattr(-,root,root,-)
  149. %{_bindir}/cgps
  150. %{_bindir}/gpscat
  151. %{_bindir}/gpsdecode
  152. %{_bindir}/gpspipe
  153. %{_bindir}/gpxlogger
  154. %{_bindir}/lcdgps
  155. %{_bindir}/xgps
  156. %{_bindir}/xgpsspeed
  157. %{_mandir}/man1/gps.1*
  158. %{_mandir}/man1/gpsdecode.1*
  159. %{_mandir}/man1/gpspipe.1*
  160. %{_mandir}/man1/lcdgps.1*
  161. %{_mandir}/man1/xgps.1*
  162. %{_mandir}/man1/xgpsspeed.1*
  163. %{_mandir}/man1/cgps.1*
  164. %{_mandir}/man1/gpscat.1*
  165. %{_datadir}/applications/*.desktop
  166. %dir %{_datadir}/gpsd
  167. %{_datadir}/gpsd/gpsd-logo.png
  168. %changelog
  169. * Tue Sep 28 2010 Shu KONNO <owa@bg.wakwak.com> 2.95-2
  170. - rebuilt with rpm-4.8.1 for pkg-config
  171. * Sun Aug 01 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.95-1
  172. - new upstream release
  173. - merge spec, patch, source from fedora
  174. * Mon Feb 08 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.37-3
  175. - add BuildRequires: libXp-devel
  176. * Wed Feb 03 2010 Shu KONNO <owa@bg.wakwak.com> 2.37-2
  177. - rebuilt with python-2.6.4
  178. * Mon Feb 02 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.37-1
  179. - initial build for Vine Linux
  180. * Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 2.37-3
  181. - Rebuild for Python 2.6
  182. * Wed Mar 19 2008 Douglas E. Warner <silfreed@silfreed.net> - 2.37-2
  183. - moving gpspacket.so python lib to main package
  184. - adding zero.patch to make ZEROIZE error go away on fedora 7
  185. * Wed Feb 27 2008 Douglas E. Warner <silfreed@silfreed.net> - 2.37-1
  186. - update to 2.37
  187. - removed install-gpsd_config.h.patch
  188. - installed pkgconfig files in devel package
  189. - added patch to install python modules in sitearch
  190. - removing rpath from inclucded libtool
  191. - moving X11 app-defaults to datadir
  192. - using macros for commands in install; using install instead of cp and mkdir
  193. - cleaning up spaces/tabs for rpmlint
  194. * Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 2.34-9
  195. - Autorebuild for GCC 4.3
  196. * Sun Aug 19 2007 Matthew Truch <matt at truch.net> - 2.34-8
  197. - Patch Makefile to also install gpsd_config.h as needed by
  198. libgpsmm.h. Redhat BZ 253433.
  199. * Sat Jun 30 2007 Matthew Truch <matt at truch.net> - 2.34-7
  200. - Make sure the logo is actually included (via the spec file).
  201. I need to wake up before I try even trivial updates.
  202. * Sat Jun 30 2007 Matthew Truch <matt at truch.net> - 2.34-6
  203. - Learn how to use search and replace (aka fix all instances of
  204. gpsd-logo.png spelled incorrectly as gspd-logo.png).
  205. * Sat Jun 30 2007 Matthew Truch <matt at truch.net> - 2.34-5
  206. - Fix desktop file and logo file name.
  207. * Sat Jun 30 2007 Matthew Truch <matt at truch.net> - 2.34-4
  208. - Include icon for .desktop files per BZ 241428
  209. * Tue Mar 20 2007 Michael Schwendt <mschwendt[AT]users.sf.net> - 2.34-3
  210. - Bump release for FE5 -> Fedora 7 upgrade path.
  211. * Tue Feb 27 2007 Matthew Truch <matt at truch.net> - 2.34-2
  212. - BR python-devel instead of python to make it build.
  213. * Tue Feb 27 2007 Matthew Truch <matt at truch.net> - 2.34-1
  214. - Upgrade to 2.34.
  215. - Get rid of %%makeinstall (which was never needed).
  216. - Possibly fix hotplug issuses (BZ 219750).
  217. - Use %%python_sitelib for python site-files stuff.
  218. * Sat Dec 9 2006 Matthew Truch <matt at truch.net> - 2.33-6
  219. - Rebuild to pull in new version of python.
  220. * Tue Sep 26 2006 Matthew Truch <matt at truch.net> - 2.33-5
  221. - Remove openmotif requirment, and switch to lesstif.
  222. * Mon Aug 28 2006 Matthew Truch <matt at truch.net> - 2.33-4
  223. - Bump release for rebuild in prep. for FC6.
  224. * Thu Jul 20 2006 Matthew Truch <matt at truch.net> - 2.33-3
  225. - Actually, was a missing BR glib-dbus-devel. Ooops.
  226. * Thu Jul 20 2006 Matthew Truch <matt at truch.net> - 2.33-2
  227. - Missing BR glib-devel
  228. * Thu Jul 20 2006 Matthew Truch <matt at truch.net> - 2.33-1
  229. - Update to version 2.33
  230. * Wed Apr 19 2006 Matthew Truch <matt at truch.net> - 2.32-5
  231. - Don't --enable-tnt in build as it causes some gpses to not work
  232. properly with sattelite view mode. See bugzilla bug 189220.
  233. * Thu Apr 13 2006 Matthew Truch <matt at truch.net> - 2.32-4
  234. - Add dbus-glib to BuildRequires as needed for build.
  235. * Sun Apr 9 2006 Matthew Truch <matt at truch.net> - 2.32-3
  236. - Include xmlto and python in buildrequires so things build right.
  237. - Don't package static library file.
  238. * Wed Apr 5 2006 Matthew Truch <matt at truch.net> - 2.32-2
  239. - Use ye olde %%{?dist} tag.
  240. * Wed Apr 5 2006 Matthew Truch <matt at truch.net> - 2.32-1
  241. - Initial Fedora Extras specfile