diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 13:49:04 -0700 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 17:38:18 -0700 |
commit | 56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch) | |
tree | 3f91093cdb475e565ae857f1c5a7fd339e2d781e /net-analyzer/ngrep | |
download | gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2 gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip |
proj/gentoo: Initial commit
This commit represents a new era for Gentoo:
Storing the gentoo-x86 tree in Git, as converted from CVS.
This commit is the start of the NEW history.
Any historical data is intended to be grafted onto this point.
Creation process:
1. Take final CVS checkout snapshot
2. Remove ALL ChangeLog* files
3. Transform all Manifests to thin
4. Remove empty Manifests
5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$
5.1. Do not touch files with -kb/-ko keyword flags.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests
X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project
X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration
X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn
X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts
X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration
X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging
X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'net-analyzer/ngrep')
-rw-r--r-- | net-analyzer/ngrep/Manifest | 1 | ||||
-rw-r--r-- | net-analyzer/ngrep/files/ngrep-1.45-build-fixes.patch | 186 | ||||
-rw-r--r-- | net-analyzer/ngrep/files/ngrep-1.45-prefix.patch | 17 | ||||
-rw-r--r-- | net-analyzer/ngrep/files/ngrep-1.45-setlocale.patch | 23 | ||||
-rw-r--r-- | net-analyzer/ngrep/metadata.xml | 14 | ||||
-rw-r--r-- | net-analyzer/ngrep/ngrep-1.45-r3.ebuild | 55 |
6 files changed, 296 insertions, 0 deletions
diff --git a/net-analyzer/ngrep/Manifest b/net-analyzer/ngrep/Manifest new file mode 100644 index 000000000000..4cf97543cb5b --- /dev/null +++ b/net-analyzer/ngrep/Manifest @@ -0,0 +1 @@ +DIST ngrep-1.45.tar.bz2 463361 SHA256 aea6dd337da8781847c75b3b5b876e4de9c58520e0d77310679a979fc6402fa7 SHA512 0feb4080f834449d57ae99897c573d2b8148711cfb550fa4ff415169dedb1f0d23f4b03f625660162ca72f8ad06e19874c1af46da6afd8f8fe8dd553558c14f7 WHIRLPOOL 5560c8b341ec9c1b322f0b0838470dfa8cf0b86fe44cb7619d5ed162753bab0f08bcea4ba17af96b01ab1a56311eb964dc87fa8c202a160d9ab1d578af6df924 diff --git a/net-analyzer/ngrep/files/ngrep-1.45-build-fixes.patch b/net-analyzer/ngrep/files/ngrep-1.45-build-fixes.patch new file mode 100644 index 000000000000..9cde0f81926d --- /dev/null +++ b/net-analyzer/ngrep/files/ngrep-1.45-build-fixes.patch @@ -0,0 +1,186 @@ +This patch fixes a number of problems with have with build: + + * more clean cut off pcre library; we'll never use bundled pcre library, so + some autoconf added REGEX_LIBS to pass correct system libs and header change. + + * We use AC_CONFIG_SUBDIRS to pass make autoconf reconfigure gnuregex library + - this way ./configure will be called correctly and correct comipler will be + selected automatically. + + * With the previous change some modifications were required to make gnuregex + buildable: a) we should not overide CFLAGS in Makefile.in (as they together + with -DHAVE_CONFIG_H will be passed to gnuregex and it'll fail to build, + since no config.h exist) b) obvious way to remove warning "_GNU_SOURCE" + redefined + + * also we don't pass $(MAKEFLAGS) since it caused us problems in the past (bug + #178684) + +--- a/Makefile.in ++++ b/Makefile.in +@@ -7,7 +7,8 @@ + + CC=@CC@ + +-CFLAGS=@CFLAGS@ -D@OS@ @DEFS@ @EXTRA_DEFINES@ ++# Never redefine CFLAGS, as it pollutes env and gnuregex build failes ++EXTRA_CFLAGS=@CFLAGS@ -D@OS@ @DEFS@ @EXTRA_DEFINES@ + INCLUDES=-I@srcdir@ @PCAP_INCLUDE@ @EXTRA_INCLUDES@ + + LDFLAGS=@LDFLAGS@ @PCAP_LINK@ +@@ -34,25 +35,25 @@ + + REGEX_DIR=@REGEX_DIR@ + REGEX_OBJS=@REGEX_OBJS@ +- ++REGEX_LIBS=@REGEX_LIBS@ + + all: $(TARGET) + + $(TARGET): $(REGEX_OBJS) $(OBJS) +- $(CC) $(CFLAGS) $(LDFLAGS) $(STRIPFLAG) -o $(TARGET) $(OBJS) $(REGEX_OBJS) $(LIBS) ++ $(CC) $(EXTRA_CFLAGS) $(LDFLAGS) -o $(TARGET) $(OBJS) $(REGEX_OBJS) $(REGEX_LIBS) $(LIBS) + + debug: $(REGEX_OBJS) $(OBJS) +- $(CC) $(CFLAGS) $(LDFLAGS) -g -o $(TARGET) $(OBJS) $(REGEX_OBJS) $(LIBS) ++ $(CC) $(EXTRA_CFLAGS) $(LDFLAGS) -g -o $(TARGET) $(OBJS) $(REGEX_OBJS) $(REGEX_LIBS) $(LIBS) + + static: $(REGEX_OBJS) $(OBJS) +- $(CC) $(CFLAGS) $(LDFLAGS) $(STRIPFLAG) -o $(TARGET).static -static $(OBJS) $(REGEX_OBJS) $(LIBS) ++ $(CC) $(EXTRA_CFLAGS) $(LDFLAGS) -o $(TARGET).static -static $(OBJS) $(REGEX_OBJS) $(REGEX_LIBS) $(LIBS) + + install: $(TARGET) + $(INSTALL) -c -m 0755 $(TARGET) $(DESTDIR)/$(BINDIR_INSTALL)/$(TARGET) + $(INSTALL) -c -m 0644 $(MANPAGE) $(DESTDIR)/$(MANDIR_INSTALL)/$(MANPAGE) + + .c.o: +- $(CC) $(CFLAGS) $(INCLUDES) -g -c $< ++ $(CC) $(EXTRA_CFLAGS) $(INCLUDES) -g -c $< + + clean: + make -C $(REGEX_DIR) clean +@@ -63,7 +64,7 @@ + rm -f config.status config.cache config.log config.h Makefile + + $(REGEX_OBJS): $(REGEX_OBJS:.o=.c) $(REGEX_DIR)/*.h +- $(MAKE) $(MAKEFLAGS) -C $(REGEX_DIR) $(notdir $(REGEX_OBJS)) ++ $(MAKE) -C $(REGEX_DIR) $(notdir $(REGEX_OBJS)) + + $(OBJS): Makefile ngrep.c ngrep.h + + +--- a/configure.in ++++ b/configure.in +@@ -124,14 +124,16 @@ + use_pcre="no" + ]) + ++REGEX_DIR="" ++REGEX_OBJS="" ++REGEX_LIBS="" + if test $use_pcre = yes; then + + echo +- echo 'Configuring Perl-Compatible Regular Expression (PCRE) library ...' ++ echo 'Using System Perl-Compatible Regular Expression (PCRE) library ...' + echo + +- REGEX_DIR='pcre-5.0' +- REGEX_OBJS="$REGEX_DIR/pcre.o $REGEX_DIR/study.o" ++ REGEX_LIBS="`pcre-config --libs`" + USE_PCRE="1" + + else +@@ -144,12 +146,19 @@ + REGEX_OBJS="$REGEX_DIR/regex.o" + USE_PCRE="0" + ++ AC_CONFIG_SUBDIRS([regex-0.12]) ++ ++ echo ++ echo 'GNU Regular Expression library is configured...' ++ echo ++ + fi + +-( cd $REGEX_DIR && ./configure ) + + AC_SUBST(REGEX_DIR) + AC_SUBST(REGEX_OBJS) ++AC_SUBST(REGEX_LIBS) ++ + + + echo + +--- a/ngrep.c ++++ b/ngrep.c +@@ -92,7 +92,7 @@ + #endif + + #if USE_PCRE +-#include "pcre-5.0/pcre.h" ++#include <pcre.h> + #else + #include "regex-0.12/regex.h" + #endif + +--- a/regex-0.12/Makefile.in ++++ b/regex-0.12/Makefile.in +@@ -18,23 +18,6 @@ + + version = 0.12 + +-# You can define CPPFLAGS on the command line. Aside from system-specific +-# flags, you can define: +-# -DREGEX_MALLOC to use malloc/realloc/free instead of alloca. +-# -DDEBUG to enable the compiled pattern disassembler and execution +-# tracing; code runs substantially slower. +-# -DEXTRACT_MACROS to use the macros EXTRACT_* (as opposed to +-# the corresponding C procedures). If not -DDEBUG, the macros +-# are used. +-CPPFLAGS = +- +-# Likewise, you can override CFLAGS to optimize, use -Wall, etc. +-CFLAGS = -g +- +-# Ditto for LDFLAGS and LOADLIBES. +-LDFLAGS = +-LOADLIBES = +- + srcdir = @srcdir@ + VPATH = @srcdir@ + +@@ -43,7 +26,7 @@ + + SHELL = /bin/sh + +-subdirs = doc test ++subdirs = + + default all:: regex.o + .PHONY: default all + +--- a/regex-0.12/configure.in ++++ b/regex-0.12/configure.in +@@ -34,4 +34,4 @@ + + esac + +-AC_OUTPUT(Makefile doc/Makefile test/Makefile) ++AC_OUTPUT(Makefile) + +=== modified file 'regex-0.12/regex.c' +--- a/regex-0.12/regex.c ++++ b/regex-0.12/regex.c +@@ -34,7 +34,9 @@ + #pragma alloca + #endif + ++#ifndef _GNU_SOURCE + #define _GNU_SOURCE ++#endif + + /* We need this for `regex.h', and perhaps for the Emacs include files. */ + #include <sys/types.h> + diff --git a/net-analyzer/ngrep/files/ngrep-1.45-prefix.patch b/net-analyzer/ngrep/files/ngrep-1.45-prefix.patch new file mode 100644 index 000000000000..8618f5daae31 --- /dev/null +++ b/net-analyzer/ngrep/files/ngrep-1.45-prefix.patch @@ -0,0 +1,17 @@ +* refrain from doing an absolutely insane check (to see if pcap is + installed in more than one place) + +--- a/configure.in ++++ b/configure.in +@@ -268,10 +268,7 @@ + + AC_MSG_CHECKING(for a complete set of pcap headers) + +-possible_dirs="`eval echo -n ${includedir}` \ +- /usr/include /usr/include/pcap \ +- /usr/local/include /usr/local/include/pcap \ +- /usr/share/include /usr/share/include/pcap" ++possible_dirs="`eval echo -n ${includedir}`" + + AC_ARG_WITH(pcap-includes, + [ --with-pcap-includes specify the pcap include directory], diff --git a/net-analyzer/ngrep/files/ngrep-1.45-setlocale.patch b/net-analyzer/ngrep/files/ngrep-1.45-setlocale.patch new file mode 100644 index 000000000000..8789e5b8c76b --- /dev/null +++ b/net-analyzer/ngrep/files/ngrep-1.45-setlocale.patch @@ -0,0 +1,23 @@ +Call setlocale to make isprint() decide what's printable depending +on the current locale. See bugs.debian.org/307496 . + +--- a/ngrep.c ++++ b/ngrep.c +@@ -97,6 +97,8 @@ + #include "regex-0.12/regex.h" + #endif + ++#include <locale.h> ++ + #include "ngrep.h" + + +@@ -195,6 +197,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': { diff --git a/net-analyzer/ngrep/metadata.xml b/net-analyzer/ngrep/metadata.xml new file mode 100644 index 000000000000..1c87217ecd40 --- /dev/null +++ b/net-analyzer/ngrep/metadata.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>netmon</herd> + <herd>proxy-maintainers</herd> + <maintainer> + <email>jpr5+gentoo@darkridge.com</email> + <name>Jordan Ritter</name> + <description>Program author who would like to be notified of bugs</description> + </maintainer> + <upstream> + <remote-id type="sourceforge">ngrep</remote-id> + </upstream> +</pkgmetadata> diff --git a/net-analyzer/ngrep/ngrep-1.45-r3.ebuild b/net-analyzer/ngrep/ngrep-1.45-r3.ebuild new file mode 100644 index 000000000000..c8b8271d7ed5 --- /dev/null +++ b/net-analyzer/ngrep/ngrep-1.45-r3.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 + +inherit autotools eutils user + +DESCRIPTION="A grep for network layers" +HOMEPAGE="http://ngrep.sourceforge.net/" +SRC_URI="mirror://sourceforge/ngrep/${P}.tar.bz2" + +LICENSE="ngrep" +SLOT="0" +KEYWORDS="alpha amd64 arm hppa ia64 ppc ppc64 s390 sh sparc x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos" +IUSE="ipv6" + +DEPEND=" + dev-libs/libpcre + net-libs/libpcap +" +RDEPEND="${DEPEND}" + +DOCS=( + doc/CHANGES.txt + doc/CREDITS.txt + doc/README.txt + doc/REGEX.txt +) + +src_prepare() { + # Remove bundled libpcre to avoid occasional linking with them + rm -r pcre-5.0 || die + + epatch \ + "${FILESDIR}"/${P}-build-fixes.patch \ + "${FILESDIR}"/${P}-setlocale.patch \ + "${FILESDIR}"/${P}-prefix.patch + + eautoreconf +} + +src_configure() { + econf \ + $(use_enable ipv6) \ + --disable-pcap-restart \ + --enable-pcre \ + --with-dropprivs-user=ngrep \ + --with-pcap-includes="${EPREFIX}"/usr/include/pcap +} + +pkg_preinst() { + enewgroup ngrep + enewuser ngrep -1 -1 -1 ngrep +} |