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/, dev-dotnet/libgit2sharp/, dev-lang/mono/files/
Date: Fri, 02 Dec 2016 10:04:40
Message-Id: 1480578866.a4a5c7f6ab44426c4cd99c6cccd96e00690fe8c2.cynede@gentoo
1 commit: a4a5c7f6ab44426c4cd99c6cccd96e00690fe8c2
2 Author: ArsenShnurkov <Arsen.Shnurkov <AT> gmail <DOT> com>
3 AuthorDate: Thu Dec 1 07:54:26 2016 +0000
4 Commit: Mikhail Pukhlikov <cynede <AT> gentoo <DOT> org>
5 CommitDate: Thu Dec 1 07:54:26 2016 +0000
6 URL: https://gitweb.gentoo.org/proj/dotnet.git/commit/?id=a4a5c7f6
7
8 where is ?
9
10 .../libgit2sharp/libgit2sharp-0.22.0.431.ebuild | 18 ++--
11 dev-lang/mono/files/autofac.patch | 24 +++++
12 dev-lang/mono/mono-4.9.0.729-r2.ebuild | 102 +++++++++++++++++++++
13 3 files changed, 135 insertions(+), 9 deletions(-)
14
15 diff --git a/dev-dotnet/libgit2sharp/libgit2sharp-0.22.0.431.ebuild b/dev-dotnet/libgit2sharp/libgit2sharp-0.22.0.431.ebuild
16 index 95851c5..9f4b0df 100644
17 --- a/dev-dotnet/libgit2sharp/libgit2sharp-0.22.0.431.ebuild
18 +++ b/dev-dotnet/libgit2sharp/libgit2sharp-0.22.0.431.ebuild
19 @@ -5,27 +5,27 @@
20 EAPI=6
21
22 KEYWORDS="~x86 ~amd64"
23 +RESTRICT+=" mirror"
24
25 USE_DOTNET="net45"
26 +IUSE="+${USE_DOTNET}"
27 EBUILD_FRAMEWORK="4.5"
28 -IUSE="${USE_DOTNET} +gac +nupkg"
29
30 -inherit nupkg
31 +inherit gac nupkg
32
33 DESCRIPTION="A C# PInvoke wrapper library for LibGit2 C library"
34
35 -EGIT_COMMIT="8daef23223e1374141bf496e4b310ded9ae4639e"
36 -HOMEPAGE="https://github.com/libgit2/libgit2sharp"
37 -SRC_URI="${HOMEPAGE}/archive/${EGIT_COMMIT}.tar.gz -> ${P}.tar.gz
38 - mirror://gentoo/mono.snk.bz2"
39 -#RESTRICT="mirror"
40 -
41 +REPO_OWNER=libgit2
42 +NAME=libgit2sharp
43 +EGIT_COMMIT="38f046d83da3fb98b2d57fca1d428363dc31a960"
44 +HOMEPAGE="https://github.com/${REPO_OWNER}/${NAME}"
45 +SRC_URI="https://api.github.com/repos/${REPO_OWNER}/${NAME}/tarball/${EGIT_COMMIT} -> ${PN}-${PV}.tar.gz"
46 S="${WORKDIR}/${PN}-${EGIT_COMMIT}"
47
48 LICENSE="MIT"
49 SLOT="0"
50
51 -CDEPEND="
52 +CDEPEND=">=dev-lang/mono-mono-4.9.0.729-r2
53 dev-libs/libgit2
54 "
55
56
57 diff --git a/dev-lang/mono/files/autofac.patch b/dev-lang/mono/files/autofac.patch
58 new file mode 100644
59 index 0000000..1983c1d
60 --- /dev/null
61 +++ b/dev-lang/mono/files/autofac.patch
62 @@ -0,0 +1,24 @@
63 +--- a/mcs/class/System.Web/System.Web.Hosting/HostingEnvironment.cs
64 ++++ b/mcs/class/System.Web/System.Web.Hosting/HostingEnvironment.cs
65 +@@ -156,9 +156,18 @@
66 +
67 + HttpContext context = HttpContext.Current;
68 + HttpRequest req = context == null ? null : context.Request;
69 +- if (req == null)
70 +- return null;
71 +-
72 ++ if (req == null) // ADDED for Orchard
73 ++ {
74 ++ var pp = HostingEnvironment.ApplicationPhysicalPath;
75 ++ String vp=virtualPath;
76 ++ if (vp.IndexOf("~/") == 0)
77 ++ {
78 ++ vp = pp + virtualPath.Substring(2);
79 ++ }
80 ++ // TODO: if not "~/" ???? then what?
81 ++ return vp;
82 ++ } // END added for Orchard
83 ++ else
84 + return req.MapPath (virtualPath);
85 + }
86 +
87
88 diff --git a/dev-lang/mono/mono-4.9.0.729-r2.ebuild b/dev-lang/mono/mono-4.9.0.729-r2.ebuild
89 new file mode 100644
90 index 0000000..5875ed3
91 --- /dev/null
92 +++ b/dev-lang/mono/mono-4.9.0.729-r2.ebuild
93 @@ -0,0 +1,102 @@
94 +# Copyright 1999-2016 Gentoo Foundation
95 +# Distributed under the terms of the GNU General Public License v2
96 +# $Id$
97 +
98 +EAPI=6
99 +
100 +inherit eutils linux-info mono-env flag-o-matic pax-utils versionator multilib-minimal
101 +
102 +DESCRIPTION="Mono runtime and class libraries, a C# compiler/interpreter"
103 +HOMEPAGE="http://www.mono-project.com/Main_Page"
104 +SRC_URI="http://download.mono-project.com/sources/${PN}/nightly/${P}.tar.bz2"
105 +
106 +LICENSE="MIT LGPL-2.1 GPL-2 BSD-4 NPL-1.1 Ms-PL GPL-2-with-linking-exception IDPL"
107 +SLOT="0"
108 +
109 +KEYWORDS="~amd64 ~ppc ~ppc64 ~x86 ~amd64-linux"
110 +
111 +IUSE="nls minimal pax_kernel xen doc"
112 +
113 +COMMONDEPEND="
114 + !minimal? ( >=dev-dotnet/libgdiplus-2.10 )
115 + ia64? ( sys-libs/libunwind )
116 + nls? ( sys-devel/gettext )
117 +"
118 +RDEPEND="${COMMONDEPEND}
119 + || ( www-client/links www-client/lynx )
120 +"
121 +DEPEND="${COMMONDEPEND}
122 + sys-devel/bc
123 + virtual/yacc
124 + pax_kernel? ( sys-apps/elfix )
125 + !dev-lang/mono-basic
126 +"
127 +
128 +S="${WORKDIR}/${PN}-$(get_version_component_range 1-3)"
129 +
130 +pkg_pretend() {
131 + # https://github.com/gentoo/gentoo/blob/f200e625bda8de696a28338318c9005b69e34710/eclass/linux-info.eclass#L686
132 + # If CONFIG_SYSVIPC is not set in your kernel .config, mono will hang while compiling.
133 + # See http://bugs.gentoo.org/261869 for more info."
134 + CONFIG_CHECK="SYSVIPC"
135 + use kernel_linux && check_extra_config
136 +}
137 +
138 +pkg_preinst() {
139 + "${WORKDIR}/mono-4.9.0-abi_x86_32.x86/mono/mini/mono-sgen" "${WORKDIR}/mono-4.9.0-abi_x86_32.x86/mcs/tools/security/sn.exe" -i "${S}/mcs/class/mono.snk" "mono" || die
140 +}
141 +
142 +pkg_setup() {
143 + linux-info_pkg_setup
144 + mono-env_pkg_setup
145 +}
146 +
147 +src_prepare() {
148 + # we need to sed in the paxctl-ng -mr in the runtime/mono-wrapper.in so it don't
149 + # get killed in the build proces when MPROTECT is enable. #286280
150 + # RANDMMAP kill the build proces to #347365
151 + # use paxmark.sh to get PT/XT logic #532244
152 + if use pax_kernel ; then
153 + ewarn "We are disabling MPROTECT on the mono binary."
154 +
155 + # issue 9 : https://github.com/Heather/gentoo-dotnet/issues/9
156 + sed '/exec "/ i\paxmark.sh -mr "$r/@mono_runtime@"' -i "${S}"/runtime/mono-wrapper.in || die "Failed to sed mono-wrapper.in"
157 + fi
158 +
159 + # mono build system can fail otherwise
160 + strip-flags
161 +
162 + eapply "${FILESDIR}/autofac.patch"
163 +
164 + default
165 + #eapply_user
166 + multilib_copy_sources
167 +}
168 +
169 +multilib_src_configure() {
170 + local myeconfargs=(
171 + --disable-silent-rules
172 + $(use_with xen xen_opt)
173 + --without-ikvm-native
174 + --disable-dtrace
175 + $(use_with doc mcs-docs)
176 + $(use_enable nls)
177 + )
178 +
179 + econf "${myeconfargs[@]}"
180 +}
181 +
182 +multilib_src_test() {
183 + cd mcs/tests || die
184 + emake check
185 +}
186 +
187 +multilib_src_install() {
188 + default_src_install
189 +
190 + # Remove files not respecting LDFLAGS and that we are not supposed to provide, see Fedora
191 + # mono.spec and http://www.mail-archive.com/mono-devel-list@××××××××××××.com/msg24870.html
192 + # for reference.
193 + rm -f "${ED}"/usr/lib/mono/{2.0,4.5}/mscorlib.dll.so || die
194 + rm -f "${ED}"/usr/lib/mono/{2.0,4.5}/mcs.exe.so || die
195 +}