2014-03-27 07:02:29 +00:00
|
|
|
#
|
2014-03-17 17:14:36 +00:00
|
|
|
# Copyright (C) 2008-2014 OpenWrt.org
|
2008-11-09 16:14:40 +00:00
|
|
|
#
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=gw6c
|
2011-07-10 23:12:35 +00:00
|
|
|
PKG_VERSION:=5.1
|
2014-03-17 17:14:36 +00:00
|
|
|
PKG_RELEASE:=5
|
2008-11-09 16:14:40 +00:00
|
|
|
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
2011-07-10 23:12:35 +00:00
|
|
|
PKG_SOURCE_URL:=http://openwrt.linux-appliance.net/sources
|
|
|
|
PKG_MD5SUM:=eeac7292a622681651ec3bd9b2e5b061
|
|
|
|
PKG_BUILD_DIR:=$(BUILD_DIR)/gw6-$(PKG_VERSION)
|
2008-11-09 16:14:40 +00:00
|
|
|
|
2012-08-04 17:02:18 +00:00
|
|
|
include $(INCLUDE_DIR)/uclibc++.mk
|
2008-11-09 16:14:40 +00:00
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
|
|
|
|
define Package/gw6c
|
2013-05-14 15:02:57 +00:00
|
|
|
SECTION:=net
|
|
|
|
CATEGORY:=Network
|
2012-08-04 17:02:18 +00:00
|
|
|
DEPENDS:=+libpthread +ip +kmod-tun +kmod-ipv6 $(CXX_DEPENDS) +radvd
|
2008-11-09 16:14:40 +00:00
|
|
|
TITLE:=IPv6 tunnel client software
|
|
|
|
URL:=http://www.go6.net
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/gw6c/description
|
|
|
|
Client to configure an IPv6 tunnel to
|
|
|
|
Hexago/freenet6/go6.net's migration broker.
|
|
|
|
endef
|
|
|
|
|
|
|
|
GW6C_OPTS:= \
|
|
|
|
C_COMPILER="$(TARGET_CC) -c -DNO_STDLIBCXX" \
|
2012-08-04 17:02:18 +00:00
|
|
|
COMPILER="$(TARGET_CXX) -c -DNO_STDLIBCXX" \
|
|
|
|
CPP_FLAGS="$(TARGET_CFLAGS) -I. -Wall -DNDEBUG $(TARGET_CPPFLAGS)" \
|
2014-03-17 17:14:36 +00:00
|
|
|
C_FLAGS="$(TARGET_CFLAGS) -I. -Wall -DNDEBUG $(TARGET_CPPFLAGS)" \
|
2008-11-09 16:14:40 +00:00
|
|
|
RANLIB="$(TARGET_CROSS)ranlib" \
|
|
|
|
ARCHIVER="$(TARGET_CROSS)ar" \
|
|
|
|
C_LINKER="$(TARGET_CC)" \
|
2012-08-04 17:02:18 +00:00
|
|
|
LINKER="$(TARGET_CXX)" \
|
2011-07-10 23:12:35 +00:00
|
|
|
exportdir=$(PKG_BUILD_DIR)/gw6c \
|
2008-11-09 16:14:40 +00:00
|
|
|
export
|
|
|
|
|
2011-07-10 23:12:35 +00:00
|
|
|
define Build/Configure
|
|
|
|
$(INSTALL_DIR) $(PKG_BUILD_DIR)/gw6c/include
|
|
|
|
$(INSTALL_DATA) $(PKG_BUILD_DIR)/gw6c-config/gw6cconfig/gw6c_c_wrapper.h \
|
|
|
|
$(PKG_BUILD_DIR)/gw6c/include
|
|
|
|
endef
|
|
|
|
|
2008-11-09 16:14:40 +00:00
|
|
|
define Build/Compile
|
2011-07-10 23:12:35 +00:00
|
|
|
$(MAKE) -C $(PKG_BUILD_DIR)/gw6c-config \
|
2008-11-09 16:14:40 +00:00
|
|
|
$(GW6C_OPTS)
|
2011-07-10 23:12:35 +00:00
|
|
|
$(MAKE) -C $(PKG_BUILD_DIR)/gw6c-messaging \
|
2008-11-09 16:14:40 +00:00
|
|
|
$(GW6C_OPTS)
|
2011-07-10 23:12:35 +00:00
|
|
|
$(MAKE) -C $(PKG_BUILD_DIR)/tspc-advanced \
|
2008-11-09 16:14:40 +00:00
|
|
|
CC="$(TARGET_CC)" \
|
2011-07-10 23:12:35 +00:00
|
|
|
CFLAGS="$(TARGET_CFLAGS) -fno-builtin -Wall -I$(PKG_BUILD_DIR)/tspc-advanced/include \
|
|
|
|
-I$(PKG_BUILD_DIR)/tspc-advanced/platform/openwrt -I$(PKG_BUILD_DIR)/tspc-advanced" \
|
|
|
|
LDFLAGS="-L$(PKG_BUILD_DIR)/tspc-advanced/gw6cconfig \
|
|
|
|
-L$(PKG_BUILD_DIR)/tspc-advanced/gw6cmessaging \
|
2012-08-06 15:39:51 +00:00
|
|
|
$(TARGET_LDFLAGS) $(LIBGCC_S)" \
|
2008-11-09 16:14:40 +00:00
|
|
|
target="openwrt" \
|
|
|
|
installdir="$(PKG_INSTALL_DIR)"
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/gw6c/install
|
|
|
|
$(INSTALL_DIR) $(1)/usr/sbin
|
2011-07-10 23:12:35 +00:00
|
|
|
$(INSTALL_BIN) $(PKG_BUILD_DIR)/tspc-advanced/bin/$(PKG_NAME) $(1)/usr/sbin
|
2008-11-09 16:14:40 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/share/gw6c/template
|
|
|
|
$(CP) ./files/openwrt.sh $(1)/usr/share/gw6c/template
|
|
|
|
$(INSTALL_DIR) $(1)/etc/init.d
|
|
|
|
$(INSTALL_BIN) ./files/gw6c.init $(1)/etc/init.d/gw6c
|
|
|
|
$(INSTALL_DIR) $(1)/etc/config
|
|
|
|
$(INSTALL_CONF) ./files/gw6c.config $(1)/etc/config/gw6c
|
|
|
|
endef
|
|
|
|
|
2011-11-16 20:02:41 +00:00
|
|
|
define Package/gw6c/conffiles
|
|
|
|
/etc/config/gw6c
|
|
|
|
endef
|
|
|
|
|
2008-11-09 16:14:40 +00:00
|
|
|
$(eval $(call BuildPackage,gw6c))
|