blob: 051d2cca315bb47a8cddd5a7f2bf62a9290cd3d3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
|
# Copyright 2000-2002 Achim Gottinger
# Distributed under the GPL by Gentoo Technologies, Inc.
# $Header: /var/cvsroot/gentoo-x86/net-analyzer/nessus/nessus-1.2.2-r1.ebuild,v 1.3 2002/08/14 12:12:16 murphy Exp $
S=${WORKDIR}
DESCRIPTION="A remote security scanner for Linux"
HOMEPAGE="http://www.nessus.org/"
SRC_URI="ftp://ftp.nessus.org/pub/${PN}/${P}/src/${PN}-libraries-${PV}.tar.gz
ftp://ftp.nessus.org/pub/${PN}/${P}/src/${PN}-core-${PV}.tar.gz
ftp://ftp.nessus.org/pub/${PN}/${P}/src/${PN}-plugins-${PV}.tar.gz
ftp://ftp.nessus.org/pub/${PN}/${P}/src/libnasl-${PV}.tar.gz"
DEPEND="virtual/x11
sys-devel/m4
>=dev-libs/gmp-3.1.1
>=sys-libs/zlib-1.1.4
=x11-libs/gtk+-1.2*"
SLOT="0"
LICENSE="GPL-2"
KEYWORDS="x86 ppc sparc sparc64"
src_compile() {
export PATH=${D}/usr/bin:$PATH
export LD_LIBRARY_PATH=${D}/usr/lib:$LD_LIBRARY_PATH
echo "Compiling libraries..."
cd ${S}/nessus-libraries
./configure \
--prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var/state \
--mandir=/usr/share/man \
--enable-pthread || die "Configure failed"
make || die "Compile failed nessus-libraries."
cd ${D}/usr/bin
cp nessus-config nessus-config.orig
sed -e "s:^PREFIX=:PREFIX=${D}:" \
-e "s:-I/usr:-I${D}/usr: " \
nessus-config.orig > nessus-config
echo "Compiling libnasl..."
cd ${S}/libnasl
./configure \
--host=${CHOST} \
--prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var/state \
--mandir=/usr/share/man || die "Configure failed libnasl"
make || die "Compile failed libnasl. (Try unmerging nessus-1.0.* if installed.)"
cd ${D}/usr/bin
cp nasl-config nasl-config.orig
sed -e "s:^PREFIX=:PREFIX=${D}:" nasl-config.orig > nasl-config
echo "Compiling core..."
cd ${S}/nessus-core
./configure \
--host=${CHOST} \
--prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var/state \
--mandir=/usr/share/man || die "Configure failed nessus-core"
make || die "Compile failed nessus-core"
echo "Compiling plugins..."
cd ${S}/nessus-plugins
./configure \
--host=${CHOST} \
--prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var/state \
--mandir=/usr/share/man || die "Configure failed nessus-plugins"
make || die "Compile failed nessus-pluggins"
}
src_install() {
cd ${S}/nessus-libraries
make \
prefix=${D}/usr \
sysconfdir=${D}/etc \
localstatedir=${D}/var/state \
mandir=${D}/usr/share/man \
install || die "Install failed nessus-libraries."
cd ${S}/libnasl
make \
prefix=${D}/usr \
sysconfdir=${D}/etc \
localstatedir=${D}/var/state \
mandir=${D}/usr/share/man \
install || die "Install failed libnasl"
cd ${S}/nessus-core
make \
prefix=${D}/usr \
sysconfdir=${D}/etc \
localstatedir=${D}/var/state \
mandir=${D}/usr/share/man \
install || die "Install failed nessus-core"
cp ${ROOT}/config/nessusd.conf ${D}/etc/nessus/
cd ${S}/nessus-plugins
make \
prefix=${D}/usr \
sysconfdir=${D}/etc \
localstatedir=${D}/var/state \
mandir=${D}/usr/share/man \
install || die "Install failed nessus-pluggins"
cd ${S}/nessus-libraries
docinto nessus-libraries
dodoc README*
cd ${S}/libnasl
docinto libnasl
dodoc COPYING TODO
cd ${S}/nessus-core
docinto nessus-core
dodoc README* UPGRADE_README CHANGES
dodoc doc/*.txt doc/ntp/*
cd ${S}/nessus-plugins
docinto nessus-plugins
dodoc docs/*.txt plugins/accounts/accounts.txt
insinto /etc/init.d
insopts -m 755
newins ${FILESDIR}/nessusd-r6 nessusd
}
|