--- ngrep-1.44.orig/config.guess +++ ngrep-1.44/config.guess @@ -1,9 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. +# 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, +# Inc. -timestamp='2005-06-30' +timestamp='2006-07-02' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -106,7 +107,7 @@ trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; : ${TMPDIR=/tmp} ; - { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || + { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; @@ -125,7 +126,7 @@ ;; ,,*) CC_FOR_BUILD=$CC ;; ,*,*) CC_FOR_BUILD=$HOST_CC ;; -esac ;' +esac ; set_cc_for_build= ;' # This is needed to find uname on a Pyramid OSx when run in the BSD universe. # (ghazi@noc.rutgers.edu 1994-08-24) @@ -206,8 +207,11 @@ *:ekkoBSD:*:*) echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} exit ;; + *:SolidBSD:*:*) + echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} + exit ;; macppc:MirBSD:*:*) - echo powerppc-unknown-mirbsd${UNAME_RELEASE} + echo powerpc-unknown-mirbsd${UNAME_RELEASE} exit ;; *:MirBSD:*:*) echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} @@ -623,8 +627,7 @@ esac if [ ${HP_ARCH} = "hppa2.0w" ] then - # avoid double evaluation of $set_cc_for_build - test -n "$CC_FOR_BUILD" || eval $set_cc_for_build + eval $set_cc_for_build # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler @@ -765,7 +768,14 @@ echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit ;; *:FreeBSD:*:*) - echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` + case ${UNAME_MACHINE} in + pc98) + echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + amd64) + echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + *) + echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + esac exit ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin @@ -780,8 +790,11 @@ i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit ;; - x86:Interix*:[34]*) - echo i586-pc-interix${UNAME_RELEASE}|sed -e 's/\..*//' + x86:Interix*:[3456]*) + echo i586-pc-interix${UNAME_RELEASE} + exit ;; + EM64T:Interix*:[3456]*) + echo x86_64-unknown-interix${UNAME_RELEASE} exit ;; [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) echo i${UNAME_MACHINE}-pc-mks @@ -795,7 +808,7 @@ i*:UWIN*:*) echo ${UNAME_MACHINE}-pc-uwin exit ;; - amd64:CYGWIN*:*:*) + amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit ;; p*:CYGWIN*:*) @@ -818,6 +831,9 @@ arm*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; + avr32*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; cris:Linux:*:*) echo cris-axis-linux-gnu exit ;; @@ -852,7 +868,11 @@ #endif #endif EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=` + eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' + /^CPU/{ + s: ::g + p + }'`" test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; mips64:Linux:*:*) @@ -871,9 +891,16 @@ #endif #endif EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=` + eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' + /^CPU/{ + s: ::g + p + }'`" test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; + or32:Linux:*:*) + echo or32-unknown-linux-gnu + exit ;; ppc:Linux:*:*) echo powerpc-unknown-linux-gnu exit ;; @@ -917,6 +944,9 @@ sparc:Linux:*:* | sparc64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; + vax:Linux:*:*) + echo ${UNAME_MACHINE}-dec-linux-gnu + exit ;; x86_64:Linux:*:*) echo x86_64-unknown-linux-gnu exit ;; @@ -962,7 +992,7 @@ LIBC=gnulibc1 # endif #else - #ifdef __INTEL_COMPILER + #if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC) LIBC=gnu #else LIBC=gnuaout @@ -972,7 +1002,11 @@ LIBC=dietlibc #endif EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=` + eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' + /^LIBC/{ + s: ::g + p + }'`" test x"${LIBC}" != x && { echo "${UNAME_MACHINE}-pc-linux-${LIBC}" exit @@ -1183,7 +1217,6 @@ *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown case $UNAME_PROCESSOR in - *86) UNAME_PROCESSOR=i686 ;; unknown) UNAME_PROCESSOR=powerpc ;; esac echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} @@ -1262,6 +1295,9 @@ i*86:skyos:*:*) echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' exit ;; + i*86:rdos:*:*) + echo ${UNAME_MACHINE}-pc-rdos + exit ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 --- ngrep-1.44.orig/config.sub +++ ngrep-1.44/config.sub @@ -1,9 +1,10 @@ #! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. +# 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, +# Inc. -timestamp='2005-06-30' +timestamp='2006-09-20' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software @@ -119,8 +120,9 @@ # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in - nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \ - kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) + nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \ + uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \ + storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; @@ -171,6 +173,10 @@ -hiux*) os=-hiuxwe2 ;; + -sco6) + os=-sco5v6 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; -sco5) os=-sco3.2v5 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` @@ -187,6 +193,10 @@ # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; + -sco5v6*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; -sco*) os=-sco3.2v2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` @@ -231,7 +241,7 @@ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | am33_2.0 \ - | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \ + | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ | bfin \ | c4x | clipper \ | d10v | d30v | dlx | dsp16xx \ @@ -239,7 +249,8 @@ | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ | i370 | i860 | i960 | ia64 \ | ip2k | iq2000 \ - | m32r | m32rle | m68000 | m68k | m88k | maxq | mcore \ + | m32c | m32r | m32rle | m68000 | m68k | m88k \ + | maxq | mb | microblaze | mcore \ | mips | mipsbe | mipseb | mipsel | mipsle \ | mips16 \ | mips64 | mips64el \ @@ -257,28 +268,27 @@ | mipsisa64sr71k | mipsisa64sr71kel \ | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ - | ms1 \ + | mt \ | msp430 \ + | nios | nios2 \ | ns16k | ns32k \ - | openrisc | or32 \ + | or32 \ | pdp10 | pdp11 | pj | pjl \ | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ | pyramid \ - | sh | sh[1234] | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \ + | score \ + | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ | sh64 | sh64le \ - | sparc | sparc64 | sparc64b | sparc86x | sparclet | sparclite \ - | sparcv8 | sparcv9 | sparcv9b \ - | strongarm \ + | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ + | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ + | spu | strongarm \ | tahoe | thumb | tic4x | tic80 | tron \ | v850 | v850e \ | we32k \ - | x86 | xscale | xscalee[bl] | xstormy16 | xtensa \ + | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \ | z8k) basic_machine=$basic_machine-unknown ;; - m32c) - basic_machine=$basic_machine-unknown - ;; m6811 | m68hc11 | m6812 | m68hc12) # Motorola 68HC11/12. basic_machine=$basic_machine-unknown @@ -286,6 +296,9 @@ ;; m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) ;; + ms1) + basic_machine=mt-unknown + ;; # We use `pc' rather than `unknown' # because (1) that's what they normally are, and @@ -305,7 +318,7 @@ | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ - | avr-* \ + | avr-* | avr32-* \ | bfin-* | bs2000-* \ | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \ | clipper-* | craynv-* | cydra-* \ @@ -316,7 +329,7 @@ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | i*86-* | i860-* | i960-* | ia64-* \ | ip2k-* | iq2000-* \ - | m32r-* | m32rle-* \ + | m32c-* | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ | m88110-* | m88k-* | maxq-* | mcore-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ @@ -336,31 +349,30 @@ | mipsisa64sr71k-* | mipsisa64sr71kel-* \ | mipstx39-* | mipstx39el-* \ | mmix-* \ - | ms1-* \ + | mt-* \ | msp430-* \ + | nios-* | nios2-* \ | none-* | np1-* | ns16k-* | ns32k-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ | pyramid-* \ | romp-* | rs6000-* \ - | sh-* | sh[1234]-* | sh[23]e-* | sh[34]eb-* | shbe-* \ + | sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ - | sparc-* | sparc64-* | sparc64b-* | sparc86x-* | sparclet-* \ + | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ | sparclite-* \ - | sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \ + | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \ | tahoe-* | thumb-* \ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ | tron-* \ | v850-* | v850e-* | vax-* \ | we32k-* \ - | x86-* | x86_64-* | xps100-* | xscale-* | xscalee[bl]-* \ + | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \ | xstormy16-* | xtensa-* \ | ymp-* \ | z8k-*) ;; - m32c-*) - ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 386bsd) @@ -696,6 +708,9 @@ basic_machine=i386-pc os=-msdos ;; + ms1-*) + basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` + ;; mvs) basic_machine=i370-ibm os=-mvs @@ -771,9 +786,8 @@ basic_machine=hppa1.1-oki os=-proelf ;; - or32 | or32-*) + openrisc | openrisc-*) basic_machine=or32-unknown - os=-coff ;; os400) basic_machine=powerpc-ibm @@ -804,6 +818,12 @@ pc532 | pc532-*) basic_machine=ns32k-pc532 ;; + pc98) + basic_machine=i386-pc + ;; + pc98-*) + basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; pentium | p5 | k5 | k6 | nexgen | viac3) basic_machine=i586-pc ;; @@ -860,6 +880,10 @@ basic_machine=i586-unknown os=-pw32 ;; + rdos) + basic_machine=i386-pc + os=-rdos + ;; rom68k) basic_machine=m68k-rom68k os=-coff @@ -886,6 +910,10 @@ sb1el) basic_machine=mipsisa64sb1el-unknown ;; + sde) + basic_machine=mipsisa32-sde + os=-elf + ;; sei) basic_machine=mips-sei os=-seiux @@ -1099,10 +1127,10 @@ we32k) basic_machine=we32k-att ;; - sh3 | sh4 | sh[34]eb | sh[1234]le | sh[23]ele) + sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; - sparc | sparcv8 | sparcv9 | sparcv9b) + sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) basic_machine=sparc-sun ;; cydra) @@ -1175,20 +1203,23 @@ | -aos* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ - | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \ + | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ + | -openbsd* | -solidbsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -chorusos* | -chorusrdb* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ - | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \ + | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \ + | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ - | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* | -skyos*) + | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ + | -skyos* | -haiku* | -rdos* | -toppers*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) @@ -1206,7 +1237,7 @@ os=`echo $os | sed -e 's|nto|nto-qnx|'` ;; -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ - | -windows* | -osx | -abug | -netware* | -os9* | -beos* \ + | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) ;; -mac*) @@ -1340,6 +1371,12 @@ # system, and we'll never get to this point. case $basic_machine in + score-*) + os=-elf + ;; + spu-*) + os=-elf + ;; *-acorn) os=-riscix1.2 ;; @@ -1349,9 +1386,9 @@ arm*-semi) os=-aout ;; - c4x-* | tic4x-*) - os=-coff - ;; + c4x-* | tic4x-*) + os=-coff + ;; # This must come before the *-dec entry. pdp10-*) os=-tops20 @@ -1395,6 +1432,9 @@ *-be) os=-beos ;; + *-haiku) + os=-haiku + ;; *-ibm) os=-aix ;; --- ngrep-1.44.orig/configure +++ ngrep-1.44/configure @@ -2894,11 +2894,11 @@ if test $use_pcre = yes; then - echo - echo 'Configuring Perl-Compatible Regular Expression (PCRE) library ...' - echo +# echo +# echo 'Configuring Perl-Compatible Regular Expression (PCRE) library ...' +# echo - ( cd pcre-5.0; ./configure && make libtool chartables.c ) +# ( cd pcre-5.0; ./configure && make libtool chartables.c ) REGEX_TARGET='pcre' REGEX_OBJS='pcre.o study.o' --- ngrep-1.44.orig/debian/dirs +++ ngrep-1.44/debian/dirs @@ -0,0 +1,3 @@ +usr/bin +usr/share/man/man8 +usr/share/doc --- ngrep-1.44.orig/debian/README.Debian +++ ngrep-1.44/debian/README.Debian @@ -0,0 +1,20 @@ +ngrep for Debian +---------------- + +ngrep is now compiled against the Perl-Compatible Regular Expressions library +instead of the GNU regex library. According to the FSF's website +(http://www.gnu.org/), the original BSD license which included the advertising +clause is not compatible with the GPL. As ngrep's license is modeled after +the original BSD license and includes the advertising clause, I have decided +to compile against PCRE, which is under a less restrictive license. + + Regular expression support is provided by the PCRE library package, + which is open source software, written by Philip Hazel, and copyright + by the University of Cambridge, England. + +Also as required by the ngrep license, this statement declares that the +original source distribution has been modified for Debian. I have made +changes to ensure that the package builds and installs in accordance with +Debian policy. + + -- Nathan Sandver , Sat, 07 Aug 2004 11:18:00 -0800 --- ngrep-1.44.orig/debian/docs +++ ngrep-1.44/debian/docs @@ -0,0 +1,3 @@ +doc/README.txt +doc/CREDITS.txt +doc/REGEX.txt --- ngrep-1.44.orig/debian/copyright +++ ngrep-1.44/debian/copyright @@ -0,0 +1,47 @@ +This package was debianized by Nathan Sandver on +Sat, 26 May 2001 12:42:54 -0700. + +It was downloaded from: http://ngrep.sourceforge.net + +Upstream Author: Jordan Ritter + +Copyright: + +Copyright (c) 2004 Jordan Ritter. All rights reserved. + +Permission is granted to anyone to use this software for any purpose on +any computer system, and to alter it and redistribute it, subject +to the following restrictions: + +1. The origin of this software must not be misrepresented, either by + explicit claim or by omission. + +2. Altered versions must be plainly marked as such, and must not be + misrepresented as being the original software. Any altered version + must clearly and properly represent the origin of this software in + any accompanying documentation. + +3. All advertising materials which relate specifically to derivate + works of this software must display the following acknowledgement: + This product includes software developed by Jordan Ritter. + +4. The name of the Author may not be used to endorse or promote + products derived from this software without specific prior written + permission. + +5. This notice, and any references to this notice, in any original or + derived source distribution of or documentation for this software, + may not be removed or altered. + + +THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS +BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR +BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE +OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN +IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. --- ngrep-1.44.orig/debian/control +++ ngrep-1.44/debian/control @@ -0,0 +1,19 @@ +Source: ngrep +Section: net +Priority: optional +Maintainer: Romain Francoise +Build-Depends: debhelper (>> 5.0.0), libpcap0.8-dev, libpcre3-dev, autotools-dev +Standards-Version: 3.7.2 + +Package: ngrep +Architecture: any +Depends: ${shlibs:Depends} +Description: grep for network traffic + ngrep strives to provide most of GNU grep's common features, + applying them to the network layer. ngrep is a pcap-aware tool that + will allow you to specify extended regular expressions to match + against data payloads of packets. It currently recognizes TCP, UDP + and ICMP across Ethernet, PPP, SLIP and null interfaces, and + understands bpf filter logic in the same fashion as more common + packet sniffing tools, such as tcpdump and snoop. + --- ngrep-1.44.orig/debian/rules +++ ngrep-1.44/debian/rules @@ -0,0 +1,86 @@ +#!/usr/bin/make -f +# GNU copyright 1997 to 1999 by Joey Hess. +# Modified for ngrep by Nathan Sandver, Steve Kemp and Romain Francoise. + +# Uncomment this to turn on verbose mode. +# export DH_VERBOSE=1 + +configure: configure-stamp +configure-stamp: + dh_testdir + + ./configure --prefix=/usr --bindir=/usr/bin --mandir=/usr/share/man \ + --infodir=/usr/share/info --enable-pcre --enable-ipv6 + + touch configure-stamp + +build: configure-stamp build-stamp +build-stamp: + dh_testdir + + + $(MAKE) +# /usr/bin/docbook-to-man debian/ngrep.sgml > ngrep.1 + + touch build-stamp + +clean: + dh_testdir + dh_testroot + rm -f build-stamp configure-stamp + + -test -r /usr/share/misc/config.sub && \ + cp -f /usr/share/misc/config.sub config.sub + -test -r /usr/share/misc/config.guess && \ + cp -f /usr/share/misc/config.guess config.guess + + -$(MAKE) distclean + + dh_clean + +install: build + dh_testdir + dh_testroot + dh_clean -k + dh_installdirs + + $(MAKE) install prefix=$(CURDIR)/debian/ngrep + mv $(CURDIR)/debian/ngrep/share/man/man8/*.8 \ + $(CURDIR)/debian/ngrep/usr/share/man/man8 + mv $(CURDIR)/debian/ngrep/bin/ngrep $(CURDIR)/debian/ngrep/usr/bin + rm -rf $(CURDIR)/debian/ngrep/share $(CURDIR)/debian/ngrep/bin + +binary-indep: build install +# We have nothing to do by default. + +binary-arch: build install + dh_testdir + dh_testroot +# dh_installdebconf + dh_installdocs + dh_installexamples + dh_installmenu +# dh_installlogrotate +# dh_installemacsen +# dh_installpam +# dh_installmime +# dh_installinit + dh_installcron + dh_installman + dh_installinfo +# dh_undocumented + dh_installchangelogs -v doc/CHANGES.txt + dh_link + dh_strip + dh_compress + dh_fixperms +# dh_makeshlibs + dh_installdeb +# dh_perl + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +binary: binary-indep binary-arch +.PHONY: build clean binary-indep binary-arch binary install configure --- ngrep-1.44.orig/debian/compat +++ ngrep-1.44/debian/compat @@ -0,0 +1 @@ +5 --- ngrep-1.44.orig/debian/changelog +++ ngrep-1.44/debian/changelog @@ -0,0 +1,170 @@ +ngrep (1.44-3) unstable; urgency=low + + * Backport patch from upstream CVS making the `clean_exit' signal + handler safer (closes: #395248). + + -- Romain Francoise Sat, 4 Nov 2006 15:54:58 +0100 + +ngrep (1.44-2) unstable; urgency=low + + * debian/control: + + Set myself as maintainer, not just uploader. + + Bump Standards-Version to 3.7.2, no changed needed. + + Build-Depend on debhelper (>> 5.0.0). + * debian/compat: New file. + * debian/rules: Don't set DH_COMPAT. + + -- Romain Francoise Wed, 27 Sep 2006 12:20:20 +0200 + +ngrep (1.44-1) unstable; urgency=low + + * New upstream release, with support for IPv6 (closes: #282362). + * debian/rules: Add --enable-ipv6 to configure flags. + + * Apply patch from Max Kosmach adding a call to + setlocale(), which makes isprint() decide what's printable depending + on the current locale (closes: #307496). + + * debian/control: Bump Standards-Version to 3.6.2.1, no changed needed. + + -- Romain Francoise Tue, 5 Jul 2005 20:24:07 +0200 + +ngrep (1.43-3) unstable; urgency=medium + + * Further cleanup the build process to get rid of the shipped pcre + library: + + Patch ngrep.c to use instead of the header in pcre-5.0. + + Patch configure to skip the pcre configure stage. + + Patch Makefile.in to not try to clean the pcre-5.0 directory. + * debian/rules: Cleanups. + + Remove obsolete deletion command from clean target (useless since + 1.43-1). + + Remove dh-make comments, cut lines to fit in 80 columns, credit + Nathan, Steve and myself. + * debian/control: Cosmetic change. + + -- Romain Francoise Fri, 25 Mar 2005 16:39:16 +0100 + +ngrep (1.43-2) unstable; urgency=low + + * Patch Makefile.in to not build (and link) the package's pcre since we + want to use the system's version (it will still be configured but at + least the binary will remain untouched). + * debian/control: Remove obsolete local variables. + + -- Romain Francoise Tue, 22 Mar 2005 20:27:31 +0100 + +ngrep (1.43-1) unstable; urgency=medium + + * Hijacked package, new maintainer: + http://lists.debian.org/debian-qa/2005/03/msg00059.html + * Added Romain Francoise as a co-maintainer. + * Build depend upon autotools-dev, so that we can copy in the most + recent config.{sub guess} files. + (Closes: #135337, #168649) + * Rebuilt against libpcap, which closes the bug fixed in the + old NMU (Now using libpcap0.8 instead of 0.7) (Closes: #156178) + * Use the system's installed copy of PCRE instead of the bundled + copy. (Closes: #166783) + * Removed the duplicate '-F' option from the manpage. + (Closes: #293728) + * New upstream version + Some previously broken code is now removed from the upstream + version so some older bugs no longer exist. + They will be closed individually as part of a bug triage. + + -- Steve Kemp Mon, 14 Mar 2005 16:15:39 +0000 + +ngrep (1.42-1) unstable; urgency=low + + * New Upstream Version (closes: #243613) + * Changed manpage to use minus signs (\-) instead of hyphens (-) + (closes: #207279) + * Updated libtool script (closes: #201948) + + -- Nathan Sandver Sat, 07 Aug 2004 12:54:33 -0700 + +ngrep (1.40.1-3) unstable; urgency=low + + * Maintainer upload to resolve some outstanding issues with the package. + Thanks to Samuele, Robert, Torsten, and Randolph for working on the + package when I was inactive. + * Updated config.guess, config.sub (closes: Bug#168649) + * Links dynamically against Debian's libpcre (closes: Bug#166783) + + -- Nathan E. Sandver Sat, 30 Nov 2002 01:23:43 -0800 + +ngrep (1.40.1-2.4) unstable; urgency=low + + * NMU + * recompiled against libpcap0.7 (closes: Bug#156178) + + -- Samuele Giovanni Tonon Wed, 6 Nov 2002 23:31:47 +0100 + +ngrep (1.40.1-2.3) unstable; urgency=low + + * NMU + * ngrep is not supposed to be a debian-native package - redownloaded + pristine upstream source and fixed that + * Applied patch to copy libpcap packet buffers to aligned positions to + avoid segfaults on architectures where that matters (like Sparc) + closes: #138847 + * Clean up stray pcre-3.4/dftables executable in clean target to allow + for repeated package building + + -- Robert Woodcock Sun, 27 Oct 2002 15:49:33 -0800 + +ngrep (1.40.1-2.2) unstable; urgency=low + + * Non maintainer upload + * Rebuilt with new libpcap to remove dependency on libpcap0, which I + got removed from unstable by accident. Sorry about this... + + -- Torsten Landschoff Sat, 10 Aug 2002 11:37:22 +0200 + +ngrep (1.40.1-2.1) unstable; urgency=low + + * NMU + * Update config.guess/sub. (closes: Bug#135337) + + -- Randolph Chung Tue, 12 Mar 2002 22:55:28 -0800 + +ngrep (1.40.1-2) unstable; urgency=low + + * Bitten by outdated config.sub & config.guess in included pcre source + again. Updated both files. (closes: Bug#133308) + + -- Nathan Sandver Mon, 18 Feb 2002 14:12:53 -0800 + +ngrep (1.40.1-1) unstable; urgency=low + + * New upstream version. + + -- Nathan Sandver Sat, 9 Feb 2002 18:42:30 -0800 + +ngrep (1.40-1) unstable; urgency=low + + * New upstream release + * Updated config.sub & config.guess. (Closes #111406) + + -- Nathan Sandver Thu, 25 Oct 2001 21:54:41 -0700 + +ngrep (1.39.2-2) unstable; urgency=low + + * Added Build-depends: libpcap-dev + + -- Nathan Sandver Thu, 5 Jul 2001 17:01:55 -0700 + +ngrep (1.39.2-1) unstable; urgency=low + + * New upstream version + * Using PCRE for regular expressions support + + -- Nathan Sandver Sat, 26 May 2001 13:12:54 -0700 + +ngrep (1.35-1) unstable; urgency=low + + * Initial Release. + + -- Nathan E. Sandver Thu, 28 Oct 1999 18:39:00 -0700 + --- ngrep-1.44.orig/Makefile.in +++ ngrep-1.44/Makefile.in @@ -11,7 +11,7 @@ INCLUDES=-I@srcdir@ @PCAP_INCLUDE@ @EXTRA_INCLUDES@ LDFLAGS=@LDFLAGS@ @PCAP_LINK@ -LIBS=-lpcap @EXTRA_LIBS@ +LIBS=-lpcap -lpcre @EXTRA_LIBS@ STRIPFLAG=@STRIPFLAG@ @@ -38,8 +38,8 @@ all: $(TARGET) -$(TARGET): $(REGEX_TARGET) $(OBJS) - $(CC) $(CFLAGS) $(LDFLAGS) $(STRIPFLAG) -o $(TARGET) $(OBJS) $(REGEX_OBJS) $(LIBS) +$(TARGET): $(OBJS) + $(CC) $(CFLAGS) $(LDFLAGS) $(STRIPFLAG) -o $(TARGET) $(OBJS) $(LIBS) debug: $(REGEX_TARGET) $(OBJS) $(CC) $(CFLAGS) $(LDFLAGS) -g -o $(TARGET) $(OBJS) $(REGEX_OBJS) $(LIBS) @@ -52,7 +52,7 @@ $(INSTALL) -c -m 0644 $(MANPAGE) $(DESTDIR)/$(MANDIR_INSTALL)/$(MANPAGE) clean: - rm -f *~ $(OBJS) $(REGEX_OBJS) $(TARGET) $(TARGET).static + rm -f *~ $(OBJS) $(TARGET) $(TARGET).static tardist: @( VERSION=`perl -ne '/VERSION\s+"(.*)"/ && print "$$1\n"' ngrep.h` ; \ @@ -74,7 +74,7 @@ ) -distclean: clean clean-$(REGEX_TARGET) +distclean: clean rm -f config.status config.cache config.log config.h Makefile $(OBJS): Makefile --- ngrep-1.44.orig/ngrep.c +++ ngrep-1.44/ngrep.c @@ -90,11 +90,13 @@ #endif #if USE_PCRE -#include "pcre-5.0/pcre.h" +#include #else #include "regex-0.12/regex.h" #endif +#include + #include "ngrep.h" @@ -191,6 +193,8 @@ signal(SIGWINCH, update_windowsize); #endif + setlocale(LC_ALL, ""); + while ((c = getopt(argc, argv, "LNhXViwqpevxlDtTRMs:n:c:d:A:I:O:S:P:F:W:")) != EOF) { switch (c) { case 'W': { @@ -1265,6 +1269,14 @@ void clean_exit(int32_t sig) { struct pcap_stat s; + signal(SIGINT, SIG_IGN); + signal(SIGABRT, SIG_IGN); +#if !defined(_WIN32) + signal(SIGQUIT, SIG_IGN); + signal(SIGPIPE, SIG_IGN); + signal(SIGWINCH, SIG_IGN); +#endif + if (quiet < 1 && sig >= 0) printf("exit\n");