[packages] ptpd: fix initscript file name, fix description, add copyright header...
[openwrt/svn-archive/archive.git] / net / gpsd / Makefile
1 #
2 # Copyright (C) 2006,2009 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=gpsd
11 PKG_VERSION:=2.90
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://download.berlios.de/gpsd/
16 PKG_MD5SUM:=a23c728b8734c542d559c485857238d2
17
18 PKG_FIXUP:=libtool-ucxx
19 PKG_INSTALL:=1
20
21 PKG_BUILD_DEPENDS:=libncurses
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/gpsd
26 SECTION:=net
27 CATEGORY:=Network
28 DEPENDS:=+libpthread +uclibcxx
29 TITLE:=An interface daemon for GPS receivers
30 URL:=http://gpsd.berlios.de/
31 endef
32
33 CONFIGURE_ARGS += \
34 --disable-dbus \
35 --disable-tsip \
36 --disable-fv18 \
37 --disable-tripmate \
38 --disable-earthmate \
39 --disable-itrax \
40 --disable-navcom \
41 --disable-ubx \
42 --disable-evermore \
43 --disable-ntrip \
44 --without-x \
45
46 CONFIGURE_VARS += \
47 CXXFLAGS="$$$$CXXFLAGS -fno-builtin -fno-rtti -nostdinc++" \
48 CPPFLAGS="$$$$CPPFLAGS -I$(STAGING_DIR)/usr/include/uClibc++ -I$(LINUX_DIR)/include" \
49 LDFLAGS="$$$$LDFLAGS -L$(STAGING_DIR)/usr/lib" \
50 LIBS="-nodefaultlibs -luClibc++ -lm -lgcc" \
51 CC="$(TARGET_CC)" CXX="$(TARGET_CXX)" \
52
53 define Build/InstallDev
54 $(INSTALL_DIR) $(1)/usr/include
55 $(CP) $(PKG_INSTALL_DIR)/usr/include/gps.h $(1)/usr/include/
56 $(INSTALL_DIR) $(1)/usr/lib
57 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgps.{a,so*} $(1)/usr/lib/
58 endef
59
60 define Package/gpsd/install
61 $(INSTALL_DIR) $(1)/usr/lib
62 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgps.so.* $(1)/usr/lib/
63 $(INSTALL_DIR) $(1)/usr/sbin
64 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/gpsd $(1)/usr/sbin/
65 endef
66
67 $(eval $(call BuildPackage,gpsd))