blob: 3c2760726d20b4ce1fc491bba1fd90f386294085 (
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
|
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-dotnet/nant/nant-0.86_beta1.ebuild,v 1.5 2009/09/27 17:08:01 nixnut Exp $
EAPI=2
inherit mono multilib eutils
DESCRIPTION=".NET build tool"
HOMEPAGE="http://nant.sourceforge.net/"
SRC_URI="mirror://sourceforge/nant/${P/_/-}-src.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 ppc x86"
IUSE="+bootstrap"
RDEPEND="
bootstrap? (
>=dev-lang/mono-2.0
)
!bootstrap? (
>=dev-dotnet/ndoc-1.3.1-r3
>=dev-lang/mono-2.4
)
"
DEPEND="${RDEPEND}
dev-util/pkgconfig"
# This build is not parallel build friendly
MAKEOPTS="${MAKEOPTS} -j1"
S="${WORKDIR}/${P/_/-}"
pkg_setup() {
if use bootstrap && has_version '>=dev-dotnet/ndoc-1.3.1-r3' && has_version '>=dev-lang/mono-2.4'
then
elog "USE=bootstrap is set. Bootstrapping is required on first install of"
elog "${CATEGORY}/${PN} and is set to on by default to not break up"
elog "the dependency graph, since USE=-bootstrap requires:"
elog ">=dev-lang/mono-2.4"
elog ">=dev-dotnet/ndoc-1.3.1-r3"
elog "Which would cause a circular dependency between ${CATEGORY}/${PN} and"
elog "dev-dotnet/ndoc."
elog "You have both installed, so you can set USE=-bootstrap and re-emerge:"
elog "echo '${CATEGORY}/${PN} -bootstrap' >> /etc/portage/package.use"
elog "emerge -1 =${CATEGORY}/${PF}"
fi
}
src_prepare() {
if ! use bootstrap
then
edos2unix NAnt.build src/NAnt.NUnit/NAnt.NUnit.build
sed -e "s:@LIB@:$(get_libdir):" "${FILESDIR}/${P}-build.patch" \
> "${WORKDIR}/${P}-build.patch"
epatch "${WORKDIR}/${P}-build.patch"
epatch "${FILESDIR}/${P}-dropnunit1.patch"
epatch "${FILESDIR}/${P}-nunit-2.4.8.patch"
epatch "${FILESDIR}/${P}-refmono-nunit.patch"
rm -rf lib/common/neutral/NUnitCore.dll
for file in lib/mono/*/nunit*.dll
do
echo $file
mono_file=${file#lib/}
rm -f $file
ln -s "/usr/$(get_libdir)/${mono_file}" "$file" || die
done
for file in lib/mono/*/NDoc*.dll
do
echo $file
mono_file=${file#lib/mono/*/}
rm -f $file
ln -s "/usr/$(get_libdir)/mono/ndoc/${mono_file}" "$file" || die
done
fi
}
src_compile() {
emake || die
}
src_install() {
make prefix="${D}/usr" install || die "install failed"
# Fix ${D} showing up in the nant wrapper script, as well as silencing
# warnings related to the log4net library
sed -i \
-e "s:${D}::" \
-e "2iexport MONO_SILENT_WARNING=1" \
"${D}"/usr/bin/nant || die "Sed nant failed"
dodoc README.txt
if ! use bootstrap
then
rm -rf "${D}"/usr/$(get_libdir)/NAnt/bin/lib/{mono,net}
fi
}
|