Gentoo Archives: gentoo-commits

From: Mikhail Pukhlikov <cynede@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/dotnet:master commit in: dev-lang/mono/
Date: Fri, 02 Jun 2017 08:20:05
Message-Id: 1496341143.d57b00b6fa3f605d759f3bf3a2d0fbeedcb28760.cynede@gentoo
1 commit: d57b00b6fa3f605d759f3bf3a2d0fbeedcb28760
2 Author: Ben Sagal <bsagal <AT> gmail <DOT> com>
3 AuthorDate: Thu Jun 1 18:15:03 2017 +0000
4 Commit: Mikhail Pukhlikov <cynede <AT> gentoo <DOT> org>
5 CommitDate: Thu Jun 1 18:19:03 2017 +0000
6 URL: https://gitweb.gentoo.org/proj/dotnet.git/commit/?id=d57b00b6
7
8 Add mono-5.0.1
9
10 dev-lang/mono/mono-5.0.1.1.ebuild | 111 ++++++++++++++++++++++++++++++++++++++
11 1 file changed, 111 insertions(+)
12
13 diff --git a/dev-lang/mono/mono-5.0.1.1.ebuild b/dev-lang/mono/mono-5.0.1.1.ebuild
14 new file mode 100644
15 index 0000000..bc84c27
16 --- /dev/null
17 +++ b/dev-lang/mono/mono-5.0.1.1.ebuild
18 @@ -0,0 +1,111 @@
19 +# Copyright 1999-2017 Gentoo Foundation
20 +# Distributed under the terms of the GNU General Public License v2
21 +
22 +EAPI=6
23 +
24 +inherit autotools eutils linux-info mono-env flag-o-matic pax-utils versionator multilib-minimal
25 +
26 +DESCRIPTION="Mono runtime and class libraries, a C# compiler/interpreter"
27 +HOMEPAGE="http://www.mono-project.com/Main_Page"
28 +SRC_URI="http://download.mono-project.com/sources/${PN}/${P}.tar.bz2"
29 +
30 +LICENSE="MIT LGPL-2.1 GPL-2 BSD-4 NPL-1.1 Ms-PL GPL-2-with-linking-exception IDPL"
31 +SLOT="0"
32 +
33 +KEYWORDS="~amd64 ~ppc ~ppc64 ~x86 ~amd64-linux"
34 +
35 +IUSE="nls minimal pax_kernel xen doc"
36 +
37 +COMMONDEPEND="
38 + !minimal? ( >=dev-dotnet/libgdiplus-2.10 )
39 + ia64? ( sys-libs/libunwind )
40 + nls? ( sys-devel/gettext )
41 +"
42 +RDEPEND="${COMMONDEPEND}
43 + || ( www-client/links www-client/lynx )
44 +"
45 +DEPEND="${COMMONDEPEND}
46 + sys-devel/bc
47 + virtual/yacc
48 + pax_kernel? ( sys-apps/elfix )
49 + dev-util/cmake
50 + !dev-lang/mono-basic
51 +"
52 +
53 +#PATCHES=(
54 +# "${FILESDIR}"/${PN}-4.8.0.371-makedev.patch
55 +# "${FILESDIR}"/${PN}-4.8.0.371-x86_32.patch
56 +#)
57 +
58 +#S="${WORKDIR}/${PN}-$(get_version_component_range 1-3)"
59 +
60 +pkg_pretend() {
61 + linux-info_pkg_setup
62 + if use kernel_linux; then
63 + if linux_config_exists; then
64 + linux_chkconfig_builtin SYSVIPC || die "SYSVIPC not enabled in the kernel"
65 + else
66 + # https://github.com/gentoo/gentoo/blob/f200e625bda8de696a28338318c9005b69e34710/eclass/linux-info.eclass#L686
67 + ewarn "kernel config not found"
68 + ewarn "If CONFIG_SYSVIPC is not set in your kernel .config, mono will hang while compiling."
69 + ewarn "See http://bugs.gentoo.org/261869 for more info."
70 + fi
71 + fi
72 +}
73 +
74 +pkg_setup() {
75 + mono-env_pkg_setup
76 +}
77 +
78 +src_prepare() {
79 + # we need to sed in the paxctl-ng -mr in the runtime/mono-wrapper.in so it don't
80 + # get killed in the build proces when MPROTECT is enable. #286280
81 + # RANDMMAP kill the build proces to #347365
82 + # use paxmark.sh to get PT/XT logic #532244
83 + if use pax_kernel ; then
84 + ewarn "We are disabling MPROTECT on the mono binary."
85 +
86 + # issue 9 : https://github.com/Heather/gentoo-dotnet/issues/9
87 + sed '/exec "/ i\paxmark.sh -mr "$r/@mono_runtime@"' -i "${S}"/runtime/mono-wrapper.in || die "Failed to sed mono-wrapper.in"
88 + fi
89 +
90 + # mono build system can fail otherwise
91 + strip-flags
92 +
93 + #TODO: resolve problem with newer binutils
94 + #bug: https://bugs.gentoo.org/show_bug.cgi?id=600664
95 + #append-flags -fPIC
96 +
97 + default
98 + # PATCHES contains configure.ac patch
99 + eautoreconf
100 + multilib_copy_sources
101 +}
102 +
103 +multilib_src_configure() {
104 + local myeconfargs=(
105 + --disable-silent-rules
106 + $(use_with xen xen_opt)
107 + --without-ikvm-native
108 + --disable-dtrace
109 + $(use_with doc mcs-docs)
110 + $(use_enable nls)
111 + )
112 +
113 + econf "${myeconfargs[@]}"
114 +}
115 +
116 +multilib_src_test() {
117 + cd mcs/tests || die
118 + emake check
119 +}
120 +
121 +multilib_src_install() {
122 + default_src_install
123 +
124 + # Remove files not respecting LDFLAGS and that we are not supposed to provide, see Fedora
125 + # mono.spec and http://www.mail-archive.com/mono-devel-list@××××××××××××.com/msg24870.html
126 + # for reference.
127 + rm -f "${ED}"/usr/lib/mono/{2.0,4.5}/mscorlib.dll.so || die
128 + rm -f "${ED}"/usr/lib/mono/{2.0,4.5}/mcs.exe.so || die
129 +}