| 1 | # $FreeWRT$
|
|---|
| 2 | #-
|
|---|
| 3 | # This file is part of the FreeWRT project. FreeWRT is copyrighted
|
|---|
| 4 | # material, please see the LICENCE file in the top-level directory
|
|---|
| 5 | # or at http://www.freewrt.org/licence for details.
|
|---|
| 6 |
|
|---|
| 7 | include $(TOPDIR)/rules.mk
|
|---|
| 8 |
|
|---|
| 9 | PKG_NAME:= tinc
|
|---|
| 10 | PKG_VERSION:= 1.0.4
|
|---|
| 11 | PKG_RELEASE:= 1
|
|---|
| 12 | PKG_MD5SUM:= 63887373dd763f8d90cecc5a3616c363
|
|---|
| 13 |
|
|---|
| 14 | PKG_SOURCE_URL:= http://www.tinc-vpn.org/packages \
|
|---|
| 15 | http://ftp.yi.se/pub/tinc/ \
|
|---|
| 16 | http://www.mirrors.wiretapped.net/security/network-security/tinc/
|
|---|
| 17 | PKG_SOURCE:= $(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|---|
| 18 |
|
|---|
| 19 | include $(TOPDIR)/mk/package.mk
|
|---|
| 20 |
|
|---|
| 21 | $(eval $(call PKG_template,TINC,tinc,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
|
|---|
| 22 |
|
|---|
| 23 | $(WRKBUILD)/.configured:
|
|---|
| 24 | (cd $(WRKBUILD); rm -rf config.{cache,status} ; \
|
|---|
| 25 | $(TARGET_CONFIGURE_OPTS) \
|
|---|
| 26 | CFLAGS="$(TARGET_CFLAGS)" \
|
|---|
| 27 | CPPFLAGS="-I$(STAGING_DIR)/usr/include" \
|
|---|
| 28 | LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
|
|---|
| 29 | ./configure \
|
|---|
| 30 | --target=$(GNU_TARGET_NAME) \
|
|---|
| 31 | --host=$(GNU_TARGET_NAME) \
|
|---|
| 32 | --build=$(GNU_HOST_NAME) \
|
|---|
| 33 | --program-prefix="" \
|
|---|
| 34 | --program-suffix="" \
|
|---|
| 35 | --prefix=/usr \
|
|---|
| 36 | --exec-prefix=/usr \
|
|---|
| 37 | --bindir=/usr/bin \
|
|---|
| 38 | --datadir=/usr/share \
|
|---|
| 39 | --includedir=/usr/include \
|
|---|
| 40 | --infodir=/usr/share/info \
|
|---|
| 41 | --libdir=/usr/lib \
|
|---|
| 42 | --libexecdir=/usr/lib \
|
|---|
| 43 | --localstatedir=/var \
|
|---|
| 44 | --mandir=/usr/share/man \
|
|---|
| 45 | --sbindir=/usr/sbin \
|
|---|
| 46 | --sysconfdir=/etc \
|
|---|
| 47 | --disable-nls \
|
|---|
| 48 | --enable-largefile \
|
|---|
| 49 | --with-kernel=$(LINUX_DIR) \
|
|---|
| 50 | --with-zlib=$(STAGING_DIR)/usr/ \
|
|---|
| 51 | );
|
|---|
| 52 | touch $@
|
|---|
| 53 |
|
|---|
| 54 | $(WRKBUILD)/.built:
|
|---|
| 55 | rm -rf $(WRKINST)
|
|---|
| 56 | mkdir -p $(WRKINST)
|
|---|
| 57 | $(MAKE) -C $(WRKBUILD) \
|
|---|
| 58 | CC=$(TARGET_CC) \
|
|---|
| 59 | CFLAGS="$(TARGET_CFLAGS)" \
|
|---|
| 60 | DESTDIR="$(WRKINST)" \
|
|---|
| 61 | all install
|
|---|
| 62 | touch $@
|
|---|
| 63 |
|
|---|
| 64 | $(IPKG_TINC):
|
|---|
| 65 | install -m0755 -d $(IDIR_TINC)/usr/sbin
|
|---|
| 66 | $(CP) $(WRKINST)/usr/sbin/tincd $(IDIR_TINC)/usr/sbin/
|
|---|
| 67 | $(RSTRIP) $(IDIR_TINC)
|
|---|
| 68 | $(IPKG_BUILD) $(IDIR_TINC) $(PACKAGE_DIR)
|
|---|
| 69 |
|
|---|