commit:     0ac994b1059a9b51f957965175bb05528fc36163
Author:     Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
AuthorDate: Tue Jun  6 09:23:19 2017 +0000
Commit:     Mikhail Pukhlikov <cynede <AT> gentoo <DOT> org>
CommitDate: Tue Jun  6 09:26:18 2017 +0000
URL:        https://gitweb.gentoo.org/proj/dotnet.git/commit/?id=0ac994b1

dev-lang/mono: forward-port mono-4.8.0.371-x86_32.patch

Bug: https://github.com/gentoo/dotnet/issues/300
Package-Manager: Portage-2.3.6, Repoman-2.3.2
Manifest-Sign-Key: 0x71A1EE76611FF3AA

 dev-lang/mono/files/mono-5.0.1.1-x86_32.patch | 21 +++++++++++++++++++++
 dev-lang/mono/mono-5.0.1.1.ebuild             |  8 +++-----
 2 files changed, 24 insertions(+), 5 deletions(-)

diff --git a/dev-lang/mono/files/mono-5.0.1.1-x86_32.patch 
b/dev-lang/mono/files/mono-5.0.1.1-x86_32.patch
new file mode 100644
index 0000000..08d443a
--- /dev/null
+++ b/dev-lang/mono/files/mono-5.0.1.1-x86_32.patch
@@ -0,0 +1,21 @@
+Native toolchain can default to different ABI (amd64 in bug case).
+Set target to i386.
+https://bugs.gentoo.org/600664
+diff --git a/mono/mini/aot-compiler.c b/mono/mini/aot-compiler.c
+index 0656a57..690c96b 100644
+--- a/mono/mini/aot-compiler.c
++++ b/mono/mini/aot-compiler.c
+@@ -9926,4 +9926,6 @@ compile_asm (MonoAotCompile *acfg)
+ #ifdef TARGET_WIN32_MSVC
+ #define AS_OPTIONS "-c -x assembler"
++#elif defined(TARGET_X86) && !defined(TARGET_MACH)
++#define AS_OPTIONS "--32"
+ #elif defined(TARGET_AMD64) && !defined(TARGET_MACH)
+ #define AS_OPTIONS "--64"
+@@ -9981,4 +9983,6 @@ compile_asm (MonoAotCompile *acfg)
+ #elif defined(TARGET_POWERPC64)
+ #define LD_OPTIONS "-m elf64ppc"
++#elif defined(TARGET_X86)
++#define LD_OPTIONS "-m elf_i386"
+ #endif
+ 

diff --git a/dev-lang/mono/mono-5.0.1.1.ebuild 
b/dev-lang/mono/mono-5.0.1.1.ebuild
index 14e9ef4..2640c83 100644
--- a/dev-lang/mono/mono-5.0.1.1.ebuild
+++ b/dev-lang/mono/mono-5.0.1.1.ebuild
@@ -12,7 +12,6 @@ 
SRC_URI="http://download.mono-project.com/sources/${PN}/${P}.tar.bz2";
 LICENSE="MIT LGPL-2.1 GPL-2 BSD-4 NPL-1.1 Ms-PL GPL-2-with-linking-exception 
IDPL"
 SLOT="0"
 
-#TODO: update patch: 
https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7a0e31adf6af28adf3c8709e542ecf7039cb5942
 KEYWORDS="~amd64 ~ppc ~ppc64 ~x86 ~amd64-linux"
 
 IUSE="nls minimal pax_kernel xen doc"
@@ -33,10 +32,9 @@ DEPEND="${COMMONDEPEND}
        !dev-lang/mono-basic
 "
 
-#PATCHES=(
-#      "${FILESDIR}"/${PN}-4.8.0.371-makedev.patch
-#      "${FILESDIR}"/${PN}-4.8.0.371-x86_32.patch
-#)
+PATCHES=(
+       "${FILESDIR}"/${PN}-5.0.1.1-x86_32.patch
+)
 
 #S="${WORKDIR}/${PN}-$(get_version_component_range 1-3)"
 

Reply via email to