/[gentoo-x86]/eclass/go-mono.eclass
Gentoo

Contents of /eclass/go-mono.eclass

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.5 - (show annotations) (download)
Thu Jan 29 16:26:48 2009 UTC (5 years, 10 months ago) by loki_val
Branch: MAIN
Changes since 1.4: +1 -2 lines
Gluezilla is no longer a runtime dependency of mono, so to maintain the binding to a certain mono version, we have to make it the other way around.

1 # Copyright 1999-2008 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/eclass/go-mono.eclass,v 1.4 2009/01/27 01:36:09 loki_val Exp $
4
5 # @ECLASS: go-mono.eclass
6 # @MAINTAINER:
7 # dotnet@gentoo.org
8 # @BLURB: Common functionality for go-mono.org apps
9 # @DESCRIPTION:
10 # Common functionality needed by all go-mono.org apps.
11
12
13 inherit base versionator mono
14
15
16 NO_MONO_DEPEND=(
17 "dev-lang/mono"
18 "dev-dotnet/libgdiplus"
19 )
20
21 GO_MONO_REL_PV="$(get_version_component_range 1-2)"
22
23 if ! has "${CATEGORY}/${PN}" "${NO_MONO_DEPEND[@]}"
24 then
25 RDEPEND="=dev-lang/mono-${GO_MONO_REL_PV}*"
26 DEPEND="${RDEPEND}"
27 fi
28
29 # @ECLASS-VARIABLE: PRE_URI
30 # @DESCRIPTION: If installing a preview, set this variable to the base
31 # path on ximians's servers from which to install.
32
33 DEPEND="${DEPEND}
34 >=dev-util/pkgconfig-0.23
35 userland_GNU? ( >=sys-apps/findutils-4.4.0 )"
36
37 if [[ "${GO_MONO_REL_PV}" = "2.4" ]]
38 then
39 PRE_URI="http://mono.ximian.com/monobuild/preview/sources"
40 fi
41
42 if [[ "${PV%_rc*}" != "${PV}" ]]
43 then
44 GO_MONO_P="${P%_rc*}"
45 SRC_URI="${PRE_URI}/${PN}/${GO_MONO_P}.tar.bz2 -> ${P}.tar.bz2"
46 S="${WORKDIR}/${GO_MONO_P}"
47 elif [[ "${PV%_pre*}" != "${PV}" ]]
48 then
49 GO_MONO_P="${P%_pre*}"
50 SRC_URI="${PRE_URI}/${PN}/${GO_MONO_P}.tar.bz2 -> ${P}.tar.bz2"
51 S="${WORKDIR}/${GO_MONO_P}"
52 else
53 GO_MONO_P=${P}
54 SRC_URI="http://ftp.novell.com/pub/mono/sources/${PN}/${P}.tar.bz2"
55 fi
56
57 # @FUNCTION: go-mono_src_unpack
58 # @DESCRIPTION: Runs default()
59 go-mono_src_unpack() {
60 default
61 }
62
63 # @FUNCTION: go-mono_src_prepare
64 # @DESCRIPTION: Runs autopatch from base.eclass, if PATCHES is set.
65 go-mono_src_prepare() {
66 base_src_util autopatch
67 }
68
69 # @FUNCTION: go-mono_src_configure
70 # @DESCRIPTION: Runs econf, disabling static libraries and dependency-tracking.
71 go-mono_src_configure() {
72 econf --disable-dependency-tracking \
73 --disable-static \
74 "$@"
75 }
76
77 # @FUNCTION: go-mono_src_configure
78 # @DESCRIPTION: Runs default()
79 go-mono_src_compile() {
80 default
81 }
82
83 # @ECLASS-VARIABLE: DOCS
84 # @DESCRIPTION: Insert path of docs you want installed. If more than one,
85 # consider using an array.
86
87 # @FUNCTION: go-mono_src_install
88 # @DESCRIPTION: Rune emake, installs common doc files, if DOCS is
89 # set, installs those. Gets rid of .la files.
90 go-mono_src_install () {
91 emake -j1 DESTDIR="${D}" install || die "install failed"
92 mono_multilib_comply
93 local commondoc=( AUTHORS ChangeLog README TODO )
94 for docfile in "${commondoc[@]}"
95 do
96 [[ -e "${docfile}" ]] && dodoc "${docfile}"
97 done
98 if [[ "${DOCS[@]}" ]]
99 then
100 dodoc "${DOCS[@]}" || die "dodoc DOCS failed"
101 fi
102 find "${D}" -name '*.la' -exec rm -rf '{}' '+' || die "la removal failed"
103 }
104
105 EXPORT_FUNCTIONS src_unpack src_prepare src_configure src_compile src_install

  ViewVC Help
Powered by ViewVC 1.1.20