You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

143 lines
3.6 KiB

  1. #
  2. # Copyright (C) 2006-2015 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=gpsd
  9. PKG_VERSION:=3.17
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=@SAVANNAH/$(PKG_NAME)
  13. PKG_HASH:=68e0dbecfb5831997f8b3d6ba48aed812eb465d8c0089420ab68f9ce4d85e77a
  14. PKG_MAINTAINER:=Pushpal Sidhu <psidhu.devel@gmail.com>
  15. PKG_LICENSE:=BSD-3-Clause
  16. PKG_LICENSE_FILES:=COPYING
  17. include $(INCLUDE_DIR)/package.mk
  18. include $(INCLUDE_DIR)/scons.mk
  19. define Package/gpsd/Default
  20. DEPENDS+= +libusb-1.0
  21. URL:=http://catb.org/gpsd/
  22. endef
  23. define Package/gpsd/Default/description
  24. gpsd is a userland daemon acting as a translator between GPS and AIS receivers
  25. and their clients. gpsd listens on port 2947 for clients requesting
  26. position/time/velocity information. The receivers are expected to generate
  27. position information in a well-known format -- as NMEA-0183 sentences, SiRF
  28. binary, Rockwell binary, Garmin binary format, or other vendor binary
  29. protocols. gpsd takes this information from the GPS and translates it into
  30. something uniform and easier to understand for clients.
  31. endef
  32. define Package/gpsd
  33. $(call Package/gpsd/Default)
  34. SECTION:=utils
  35. CATEGORY:=Utilities
  36. TITLE:=An interface daemon for GPS receivers
  37. endef
  38. define Package/gpsd/conffiles
  39. /etc/config/gpsd
  40. endef
  41. define Package/gpsd/description
  42. $(call Package/gpsd/Default/description)
  43. This package contains the GPS daemon.
  44. endef
  45. define Package/gpsd-clients
  46. $(call Package/gpsd/Default)
  47. SECTION:=utils
  48. CATEGORY:=Utilities
  49. DEPENDS+= +libncurses
  50. TITLE:=GPS tools and clients
  51. endef
  52. define Package/gpsd-clients/description
  53. $(call Package/gpsd/Default/description)
  54. This package contains auxiliary tools and example clients for monitoring and
  55. testing the GPS daemon.
  56. endef
  57. define Package/libgps
  58. $(call Package/gpsd/Default)
  59. SECTION:=libs
  60. CATEGORY:=Libraries
  61. TITLE:=C service library for communicating with the GPS daemon
  62. endef
  63. define Package/libgps/description
  64. $(call Package/gpsd/Default/description)
  65. This package contains the libgps library.
  66. endef
  67. SCONS_VARS += \
  68. LINKFLAGS="$(TARGET_LDFLAGS)"
  69. SCONS_OPTIONS += \
  70. dbus_export=no \
  71. tsip=no \
  72. fv18=no \
  73. tripmate=no \
  74. earthmate=no \
  75. itrax=no \
  76. navcom=no \
  77. ubx=no \
  78. evermore=no \
  79. ntrip=no \
  80. libgpsmm=no \
  81. libQgpsmm=no \
  82. bluez=no \
  83. nostrip=yes \
  84. python=no \
  85. implicit_link=no \
  86. chrpath=no \
  87. manbuild=no \
  88. target="$(TARGET_CROSS:-=)"
  89. define Build/InstallDev
  90. $(INSTALL_DIR) $(1)/usr/include
  91. $(CP) $(PKG_INSTALL_DIR)/usr/include/gps.h $(1)/usr/include/
  92. $(INSTALL_DIR) $(1)/usr/lib
  93. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgps*.so* $(1)/usr/lib/
  94. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  95. $(CP) \
  96. $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libgps*.pc \
  97. $(1)/usr/lib/pkgconfig/
  98. endef
  99. define Package/gpsd/install
  100. $(INSTALL_DIR) $(1)/etc/config
  101. $(INSTALL_CONF) ./files/gpsd.config $(1)/etc/config/gpsd
  102. $(INSTALL_DIR) $(1)/etc/init.d
  103. $(INSTALL_BIN) ./files/gpsd.init $(1)/etc/init.d/gpsd
  104. $(INSTALL_DIR) $(1)/usr/sbin
  105. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/gpsd $(1)/usr/sbin/
  106. endef
  107. define Package/gpsd-clients/install
  108. $(INSTALL_DIR) $(1)/usr/bin
  109. $(INSTALL_BIN) \
  110. $(PKG_INSTALL_DIR)/usr/bin/cgps \
  111. $(PKG_INSTALL_DIR)/usr/bin/gps{ctl,decode,mon,pipe} \
  112. $(PKG_INSTALL_DIR)/usr/bin/gpxlogger \
  113. $(PKG_INSTALL_DIR)/usr/bin/lcdgps \
  114. $(1)/usr/bin/
  115. endef
  116. define Package/libgps/install
  117. $(INSTALL_DIR) $(1)/usr/lib
  118. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgps.so.* $(1)/usr/lib/
  119. endef
  120. $(eval $(call BuildPackage,gpsd))
  121. $(eval $(call BuildPackage,gpsd-clients))
  122. $(eval $(call BuildPackage,libgps))