OpenWrt Forum Archive

Topic: libpcap package update: need to clean before build ... how?

The content of this topic has been archived on 17 Mar 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hey all,

I've got an updated  libpcap  setup to take it from 0.9.4 to 0.9.8  but I've got a small problem.
The libpcap tarfile available from  tcpdump.org  has a  "gencode.c.rej" file in it.
If I remove it manually  prior to patching,  it works ...

trick is  how can I get the libpcap package Makefile to cause the   gencode.c.rej file to be removed prior to patching. ?

If the file is not removed, the patching routine breaks  due to the a file with extension  .rej being present.

GPW

Hey  gpw;

What about something like:

define Build/Prepare
        gunzip $(TOPDIR)/dl/$(PKG_SOURCE)
#Remoove the dam .rej file if it's there otherwise carry on
        tar --delete --file=$(TOPDIR)/dl/$(PKG_NAME)-$(PKG_VERSION).tar "libpcap-0.9.8/./gencode.c.rej" || true
        gzip $(TOPDIR)/dl/$(PKG_NAME)-$(PKG_VERSION).tar
        $(call Build/Prepare/Default)
endef

D. Lissimore

The discussion might have continued from here.