/[gentoo-x86]/net-misc/openswan/openswan-2.4.4.ebuild
Gentoo

Contents of /net-misc/openswan/openswan-2.4.4.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.5 - (show annotations) (download)
Sun Mar 18 08:42:13 2007 UTC (12 years, 7 months ago) by mrness
Branch: MAIN
CVS Tags: HEAD
Changes since 1.4: +1 -1 lines
FILE REMOVED
Remove obsolete version.
(Portage version: 2.1.2.2)

1 # Copyright 1999-2006 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-misc/openswan/openswan-2.4.4.ebuild,v 1.4 2006/11/22 19:09:55 masterdriverz Exp $
4
5 inherit eutils linux-info
6
7 MY_P=${P/_p/_kb}
8 S=${WORKDIR}/${MY_P}
9 DESCRIPTION="Open Source implementation of IPsec for the Linux operating system (was SuperFreeS/WAN)."
10 HOMEPAGE="http://www.openswan.org/"
11 SRC_URI="http://www.openswan.org/download/${MY_P}.tar.gz
12 mirror://gentoo/${MY_P}.tar.gz"
13
14 LICENSE="GPL-2"
15 SLOT="0"
16 KEYWORDS="-* x86 amd64 ~ppc"
17 IUSE=""
18
19 DEPEND="!net-misc/strongswan
20 virtual/libc
21 virtual/linux-sources
22 >=dev-libs/gmp-3.1.1
23 net-dns/host
24 sys-apps/iproute2"
25 RDEPEND=""
26
27 pkg_setup() {
28 linux-info_pkg_setup
29
30 if kernel_is 2 6; then
31 einfo "This ebuild will set ${P} to use 2.6 native IPsec (KAME)."
32 einfo "KLIPS will not be compiled/installed."
33 export MYMAKE="programs"
34
35 elif kernel_is 2 4; then
36 if ! [ -d /usr/src/linux/net/ipsec ]; then
37 eerror "You need to have an IPsec enabled 2.4.x kernel."
38 eerror "Ensure you have one running and make a symlink to it in /usr/src/linux"
39 die
40 fi
41
42 einfo "Using patched-in IPsec code for kernel 2.4"
43 einfo "Your kernel only supports KLIPS for kernel level IPsec."
44 export MYMAKE="confcheck programs"
45
46 else
47 die "Unrecognised kernel version"
48 fi
49 }
50
51 src_unpack() {
52 unpack ${A}
53
54 cd ${S}
55 epatch ${FILESDIR}/${P}-gentoo.patch
56
57 # GCC4 compile fix
58 sed -i -e '/LIST_INSERT_HEAD/a ;' programs/pluto/server.c
59 }
60
61 src_compile() {
62 make \
63 DESTDIR=${D} \
64 USERCOMPILE="${CFLAGS}" \
65 FINALCONFDIR=/etc/ipsec \
66 INC_RCDEFAULT=/etc/init.d \
67 INC_USRLOCAL=/usr \
68 INC_MANDIR=share/man \
69 ${MYMAKE} || die
70 }
71
72 src_install() {
73 make \
74 DESTDIR=${D} \
75 USERCOMPILE="${CFLAGS}" \
76 FINALCONFDIR=/etc/ipsec \
77 INC_RCDEFAULT=/etc/init.d \
78 INC_USRLOCAL=/usr \
79 INC_MANDIR=share/man \
80 install || die
81
82 dosym /etc/ipsec/ipsec.d /etc/ipsec.d
83
84 doinitd ${FILESDIR}/ipsec
85 }

  ViewVC Help
Powered by ViewVC 1.1.20