| [c8b93bd] | 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.
|
|---|
| [475ad56] | 6 |
|
|---|
| 7 | include $(TOPDIR)/rules.mk
|
|---|
| 8 |
|
|---|
| [c8b93bd] | 9 | PKG_NAME:= tinyproxy
|
|---|
| 10 | PKG_VERSION:= 1.6.3
|
|---|
| 11 | PKG_RELEASE:= 1
|
|---|
| 12 | PKG_MD5SUM:= bd14d029b12621bcfd7ee71b2f4893da
|
|---|
| 13 | PKG_INIT:= 70
|
|---|
| [475ad56] | 14 |
|
|---|
| [c8b93bd] | 15 | PKG_SOURCE_URL:= @SF/tinyproxy
|
|---|
| 16 | PKG_SOURCE:= $(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|---|
| [475ad56] | 17 |
|
|---|
| [c8b93bd] | 18 | include $(TOPDIR)/mk/package.mk
|
|---|
| [475ad56] | 19 |
|
|---|
| 20 | $(eval $(call PKG_template,TINYPROXY,tinyproxy,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
|
|---|
| 21 |
|
|---|
| [c04ece1] | 22 | ifeq ($(FWRT_COMPILE_TINYPROXY_WITH_TRANSPARENT_PROXY),y)
|
|---|
| [475ad56] | 23 | ENABLE_TRANSPARENT:=--enable-transparent-proxy
|
|---|
| 24 | endif
|
|---|
| [c04ece1] | 25 | ifneq ($(FWRT_COMPILE_TINYPROXY_WITH_UPSTREAM),y)
|
|---|
| [475ad56] | 26 | DISABLE_UPSTREAM:=--disable-upstream
|
|---|
| 27 | endif
|
|---|
| [c04ece1] | 28 | ifneq ($(FWRT_COMPILE_TINYPROXY_WITH_FILTER),y)
|
|---|
| [475ad56] | 29 | DISABLE_FILTER:=--disable-filter
|
|---|
| 30 | endif
|
|---|
| 31 |
|
|---|
| [d419478] | 32 | $(WRKBUILD)/.configured:
|
|---|
| 33 | (cd $(WRKBUILD); rm -rf config.{cache,status} ; \
|
|---|
| [475ad56] | 34 | $(TARGET_CONFIGURE_OPTS) \
|
|---|
| 35 | CFLAGS="$(strip $(TARGET_CFLAGS))" \
|
|---|
| 36 | CPPFLAGS="-I$(STAGING_DIR)/usr/include" \
|
|---|
| 37 | LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
|
|---|
| 38 | ./configure \
|
|---|
| 39 | --target=$(GNU_TARGET_NAME) \
|
|---|
| 40 | --host=$(GNU_TARGET_NAME) \
|
|---|
| 41 | --build=$(GNU_HOST_NAME) \
|
|---|
| 42 | --program-prefix="" \
|
|---|
| 43 | --program-suffix="" \
|
|---|
| 44 | --prefix=/usr \
|
|---|
| 45 | --exec-prefix=/usr \
|
|---|
| 46 | --bindir=/usr/bin \
|
|---|
| 47 | --datadir=/usr/share \
|
|---|
| 48 | --includedir=/usr/include \
|
|---|
| 49 | --infodir=/usr/share/info \
|
|---|
| 50 | --libdir=/usr/lib \
|
|---|
| 51 | --libexecdir=/usr/lib \
|
|---|
| 52 | --localstatedir=/var \
|
|---|
| 53 | --mandir=/usr/share/man \
|
|---|
| 54 | --sbindir=/usr/sbin \
|
|---|
| 55 | --sysconfdir=/etc \
|
|---|
| [c57fbc9] | 56 | --disable-nls \
|
|---|
| [475ad56] | 57 | --disable-static \
|
|---|
| 58 | $(ENABLE_TRANSPARENT) \
|
|---|
| 59 | $(DISABLE_UPSTREAM) \
|
|---|
| 60 | $(DISABLE_FILTER) \
|
|---|
| 61 | );
|
|---|
| [d419478] | 62 | touch $(WRKBUILD)/.configured
|
|---|
| [475ad56] | 63 |
|
|---|
| [d419478] | 64 | $(WRKBUILD)/.built:
|
|---|
| 65 | $(MAKE) -C $(WRKBUILD)
|
|---|
| 66 | mkdir -p $(WRKINST)
|
|---|
| 67 | $(MAKE) -C $(WRKBUILD) \
|
|---|
| 68 | DESTDIR="$(WRKINST)" \
|
|---|
| [475ad56] | 69 | install
|
|---|
| [d419478] | 70 | find $(WRKINST) -name '*dist' | xargs rm -f
|
|---|
| 71 | touch $(WRKBUILD)/.built
|
|---|
| [475ad56] | 72 |
|
|---|
| 73 | $(IPKG_TINYPROXY):
|
|---|
| 74 | install -d -m0755 $(IDIR_TINYPROXY)/usr/sbin \
|
|---|
| 75 | $(IDIR_TINYPROXY)/etc/tinyproxy \
|
|---|
| 76 | $(IDIR_TINYPROXY)/etc/init.d \
|
|---|
| 77 | $(IDIR_TINYPROXY)/var/log \
|
|---|
| 78 | $(IDIR_TINYPROXY)/usr/share
|
|---|
| [d419478] | 79 | $(CP) $(WRKINST)/usr/sbin/tinyproxy $(IDIR_TINYPROXY)/usr/sbin/
|
|---|
| 80 | $(CP) $(WRKINST)/usr/share/tinyproxy $(IDIR_TINYPROXY)/usr/share/
|
|---|
| 81 | $(CP) $(WRKINST)/etc/tinyproxy $(IDIR_TINYPROXY)/etc/
|
|---|
| [c8b93bd] | 82 | $(CP) files/$(PKG_NAME).init $(IDIR_TINYPROXY)/etc/init.d/S$(PKG_INIT)$(PKG_NAME)
|
|---|
| [475ad56] | 83 | $(RSTRIP) $(IDIR_TINYPROXY)
|
|---|
| 84 | $(IPKG_BUILD) $(IDIR_TINYPROXY) $(PACKAGE_DIR)
|
|---|