diff options
author | mbm <mbm@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2004-08-27 00:42:33 +0000 |
---|---|---|
committer | mbm <mbm@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2004-08-27 00:42:33 +0000 |
commit | f0c8400658ac5b039bb48dbb74b02f75d52b9723 (patch) | |
tree | 7ef2c062b8733bbd08473f6c2bed78c7ad9708d1 /obsolete-buildroot/make/tcpdump.mk | |
parent | aa210b58909434abaa63a7a6cd898a43ba61c3f3 (diff) |
various patches
nico:
buildroot-20040825-kmodules.patch.txt
buildroot-20040825-tcpdump.patch.txt
buildroot-20040825-libpcap.patch.txt
buildroot-20040825-libpthread.patch.txt
buildroot-20040825-fprobe.patch.txt
buildroot-20040825-pptp-client.patch.txt
twolife:
iproute2.patch.txt
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@149 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'obsolete-buildroot/make/tcpdump.mk')
-rw-r--r-- | obsolete-buildroot/make/tcpdump.mk | 108 |
1 files changed, 108 insertions, 0 deletions
diff --git a/obsolete-buildroot/make/tcpdump.mk b/obsolete-buildroot/make/tcpdump.mk new file mode 100644 index 000000000..f8d29e2da --- /dev/null +++ b/obsolete-buildroot/make/tcpdump.mk @@ -0,0 +1,108 @@ +## tcpdump + +TCPDUMP_VERSION:=3.8.3 +TCPDUMP_RELEASE:=1 + +TCPDUMP_SOURCE:=tcpdump-$(TCPDUMP_VERSION).tar.gz +TCPDUMP_SITE:=http://www.tcpdump.org/release/ +TCPDUMP_DIR:=$(BUILD_DIR)/tcpdump-$(TCPDUMP_VERSION) +TCPDUMP_CAT:=zcat + +TCPDUMP_PATCH_DIR := $(SOURCE_DIR)/openwrt/patches/tcpdump + +TCPDUMP_BUILD_DIR := $(BUILD_DIR)/tcpdump_$(TCPDUMP_VERSION)-$(TCPDUMP_RELEASE) +TCPDUMP_IPK_DIR := $(OPENWRT_IPK_DIR)/tcpdump +TCPDUMP_IPK := $(TCPDUMP_BUILD_DIR)_$(ARCH).ipk + + +$(DL_DIR)/$(TCPDUMP_SOURCE): + $(WGET) -P $(DL_DIR) $(TCPDUMP_SITE)/$(TCPDUMP_SOURCE) + + +$(TCPDUMP_DIR)/.stamp-unpacked: $(DL_DIR)/$(TCPDUMP_SOURCE) + $(TCPDUMP_CAT) $(DL_DIR)/$(TCPDUMP_SOURCE) | tar -C $(BUILD_DIR) -xvf - + + touch $(TCPDUMP_DIR)/.stamp-unpacked + + +$(TCPDUMP_DIR)/.stamp-patched: $(TCPDUMP_DIR)/.stamp-unpacked + $(SOURCE_DIR)/patch-kernel.sh $(TCPDUMP_DIR) $(TCPDUMP_PATCH_DIR) + $(SOURCE_DIR)/patch-kernel.sh $(TCPDUMP_DIR) $(TCPDUMP_DIR)/debian/patches *patch + + touch $(TCPDUMP_DIR)/.stamp-patched + + +$(TCPDUMP_DIR)/.stamp-configured: $(TCPDUMP_DIR)/.stamp-patched + cd $(TCPDUMP_DIR) ; \ + rm -rf config.cache ; \ + $(TARGET_CONFIGURE_OPTS) \ + CFLAGS="$(TARGET_CFLAGS)" \ + ac_cv_linux_vers="2" \ + ./configure \ + --target=$(GNU_TARGET_NAME) \ + --host=$(GNU_TARGET_NAME) \ + --build=$(GNU_HOST_NAME) \ + --prefix=/usr \ + --exec-prefix=/usr \ + --bindir=/usr/bin \ + --sbindir=/usr/sbin \ + --libexecdir=/usr/lib/locate \ + --sysconfdir=/etc \ + --datadir=/usr/share \ + --localstatedir=/var/lib \ + --mandir=/usr/share/man \ + --infodir=/usr/share/info \ + --includedir=/usr/include \ + --libdir=/usr/lib \ + $(DISABLE_NLS) \ + --enable-shared \ + --disable-static \ + + touch $(TCPDUMP_DIR)/.stamp-configured + + +$(TCPDUMP_DIR)/.stamp-built: $(TCPDUMP_DIR)/.stamp-configured + cd $(TCPDUMP_DIR) ; \ + $(MAKE) \ + CC=$(TARGET_CC) \ + CCOPT="$(TARGET_OPTIMIZATION)" \ + INCLS="-I. -I$(srcdir)/missing" \ + LDFLAGS="-lpcap" \ + LIBS="" \ + + touch $(TCPDUMP_DIR)/.stamp-built + + +$(TCPDUMP_DIR)/.stamp-installed: $(TCPDUMP_DIR)/.stamp-built + mkdir -p $(TCPDUMP_BUILD_DIR) + cd $(TCPDUMP_DIR) ; \ + $(MAKE) \ + DESTDIR="$(TCPDUMP_BUILD_DIR)" \ + install \ + + rm -rf $(TCPDUMP_BUILD_DIR)/usr/share + + $(STRIP) $(TCPDUMP_BUILD_DIR)/usr/sbin/* + + touch $(TCPDUMP_DIR)/.stamp-installed + + +$(TCPDUMP_IPK): $(TCPDUMP_DIR)/.stamp-installed + cp -a $(TCPDUMP_IPK_DIR)/CONTROL $(TCPDUMP_BUILD_DIR)/ + perl -pi -e "s/^Vers.*:.*$$/Version: $(TCPDUMP_VERSION)-$(TCPDUMP_RELEASE)/" $(TCPDUMP_BUILD_DIR)/CONTROL/control + perl -pi -e "s/^Arch.*:.*$$/Architecture: $(ARCH)/" $(TCPDUMP_BUILD_DIR)/CONTROL/control + cd $(BUILD_DIR); $(IPKG_BUILD) $(TCPDUMP_BUILD_DIR) + + +tcpdump-source: $(DL_DIR)/$(TCPDUMP_SOURCE) + +# libpcap-clean prevent configure to find a local libpcap library +tcpdump-ipk: ipkg-utils libpcap-ipk libpcap-clean $(TCPDUMP_IPK) + +tcpdump-clean: + $(MAKE) -C $(TCPDUMP_DIR) clean + +tcpdump-clean-all: + rm -rf $(TCPDUMP_DIR) + rm -rf $(TCPDUMP_BUILD_DIR) + rm -rf $(TCPDUMP_IPK) |