diff options
author | Jeroen Roovers <jer@gentoo.org> | 2009-05-26 08:48:31 +0000 |
---|---|---|
committer | Jeroen Roovers <jer@gentoo.org> | 2009-05-26 08:48:31 +0000 |
commit | 6cf140d9cec381cc6b2ba10a58aa3e8fc5936e23 (patch) | |
tree | d2d0909bac654349dc1cb27736af087f4b5d1632 /net-libs/libpcap | |
parent | Respect LDFLAGS (bug #262960). Thanks to Davide Pesavento for reporting. (diff) | |
download | gentoo-2-6cf140d9cec381cc6b2ba10a58aa3e8fc5936e23.tar.gz gentoo-2-6cf140d9cec381cc6b2ba10a58aa3e8fc5936e23.tar.bz2 gentoo-2-6cf140d9cec381cc6b2ba10a58aa3e8fc5936e23.zip |
Build -fPIC on FreeBSD too (thanks to Timothy Redaelli, bug #262060).
(Portage version: 2.2_rc33/cvs/Linux i686)
Diffstat (limited to 'net-libs/libpcap')
-rw-r--r-- | net-libs/libpcap/ChangeLog | 8 | ||||
-rw-r--r-- | net-libs/libpcap/files/libpcap-1.0.0-freebsd-pic.patch | 13 | ||||
-rw-r--r-- | net-libs/libpcap/libpcap-1.0.0-r2.ebuild | 55 |
3 files changed, 75 insertions, 1 deletions
diff --git a/net-libs/libpcap/ChangeLog b/net-libs/libpcap/ChangeLog index 076bfaee763d..6e68c47cf749 100644 --- a/net-libs/libpcap/ChangeLog +++ b/net-libs/libpcap/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for net-libs/libpcap # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-libs/libpcap/ChangeLog,v 1.118 2009/05/12 10:09:41 loki_val Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-libs/libpcap/ChangeLog,v 1.119 2009/05/26 08:48:31 jer Exp $ + +*libpcap-1.0.0-r2 (26 May 2009) + + 26 May 2009; Jeroen Roovers <jer@gentoo.org> +libpcap-1.0.0-r2.ebuild, + +files/libpcap-1.0.0-freebsd-pic.patch: + Build -fPIC on FreeBSD too (thanks to Timothy Redaelli, bug #262060). 12 May 2009; Peter Alfredsen <loki_val@gentoo.org> libpcap-1.0.0-r1.ebuild: diff --git a/net-libs/libpcap/files/libpcap-1.0.0-freebsd-pic.patch b/net-libs/libpcap/files/libpcap-1.0.0-freebsd-pic.patch new file mode 100644 index 000000000000..93b633df6d56 --- /dev/null +++ b/net-libs/libpcap/files/libpcap-1.0.0-freebsd-pic.patch @@ -0,0 +1,13 @@ +Compile with -fPIC also on FreeBSD (it's needed for amd64-fbsd) + +--- configure.in.orig ++++ configure.in +@@ -959,7 +959,7 @@ + MAN_MISC_INFO=5 + ;; + +-linux*) ++linux*|freebsd*) + V_CCOPT="$V_CCOPT -fPIC" + ;; + diff --git a/net-libs/libpcap/libpcap-1.0.0-r2.ebuild b/net-libs/libpcap/libpcap-1.0.0-r2.ebuild new file mode 100644 index 000000000000..46096a881863 --- /dev/null +++ b/net-libs/libpcap/libpcap-1.0.0-r2.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-libs/libpcap/libpcap-1.0.0-r2.ebuild,v 1.1 2009/05/26 08:48:31 jer Exp $ + +inherit autotools eutils multilib toolchain-funcs + +DESCRIPTION="A system-independent library for user-level network packet capture" +HOMEPAGE="http://www.tcpdump.org/" +SRC_URI="http://www.tcpdump.org/release/${P}.tar.gz + http://www.jp.tcpdump.org/release/${P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd" +IUSE="ipv6 bluetooth" + +RDEPEND="!virtual/libpcap + bluetooth? ( || ( net-wireless/bluez net-wireless/bluez-libs ) )" +DEPEND="${RDEPEND} + sys-devel/flex" +PROVIDE="virtual/libpcap" + +src_unpack() { + unpack ${A} + cd "${S}" + epatch "${FILESDIR}/${P}-cross-linux.patch" + epatch "${FILESDIR}/${P}-install-bindir.patch" + epatch "${FILESDIR}/${P}-install-headers.patch" + epatch "${FILESDIR}/${P}-optional-bluetooth.patch" + epatch "${FILESDIR}/${P}-LDFLAGS.patch" + epatch "${FILESDIR}/${P}-freebsd-pic.patch" + eautoreconf +} + +src_compile() { + econf $(use_enable ipv6) \ + $(use_enable bluetooth) + emake all shared || die "compile problem" +} + +src_install() { + emake DESTDIR="${D}" install install-shared || die "emake install failed" + + dosym libpcap.so.${PV:0:5} /usr/$(get_libdir)/libpcap.so.1 + dosym libpcap.so.${PV:0:5} /usr/$(get_libdir)/libpcap.so + + # We need this to build pppd on G/FBSD systems + if [[ "${USERLAND}" == "BSD" ]]; then + insinto /usr/include + doins pcap-int.h || die "failed to install pcap-int.h" + fi + + # We are not installing README.{Win32,aix,hpux,tru64} (bug 183057) + dodoc CREDITS CHANGES VERSION TODO README{,.dag,.linux,.macosx,.septel} +} |