From owner-freebsd-mono@FreeBSD.ORG Tue Nov 10 02:20:03 2009 Return-Path: Delivered-To: mono@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 15913106568D for ; Tue, 10 Nov 2009 02:20:03 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 0439E8FC12 for ; Tue, 10 Nov 2009 02:20:03 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id nAA2K29U069823 for ; Tue, 10 Nov 2009 02:20:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id nAA2K2cb069822; Tue, 10 Nov 2009 02:20:02 GMT (envelope-from gnats) Date: Tue, 10 Nov 2009 02:20:02 GMT Message-Id: <200911100220.nAA2K2cb069822@freefall.freebsd.org> To: mono@FreeBSD.org From: Romain =?iso-8859-1?Q?Tarti=E8re?= Cc: Subject: Re: ports/140362: lang/mono: Patches for PowerPC support in mono X-BeenThere: freebsd-mono@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Romain =?iso-8859-1?Q?Tarti=E8re?= List-Id: Mono and C# applications on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 Nov 2009 02:20:03 -0000 The following reply was made to PR ports/140362; it has been noted by GNATS. From: Romain =?iso-8859-1?Q?Tarti=E8re?= To: bug-followup@FreeBSD.org, chmeeedalf@gmail.com Cc: Subject: Re: ports/140362: lang/mono: Patches for PowerPC support in mono Date: Tue, 10 Nov 2009 03:12:55 +0100 --ew6BAiZeqk4r7MaW Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit Fine, here is the final patch ready for being applied to the FreeBSD ports tree. Romain, on behalf of the BSD# Team. -- Romain Tartière http://romain.blogreen.org/ pgp: 8DAB A124 0DA4 7024 F82A E748 D8E9 A33F FF56 FF43 (ID: 0xFF56FF43) (plain text =non-HTML= PGP/GPG encrypted/signed e-mail much appreciated) --ew6BAiZeqk4r7MaW Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="mono.diff" diff -ruN /var/cache/portshaker/freebsd/lang/mono/Makefile /tmp/mono/Makefile --- /var/cache/portshaker/freebsd/lang/mono/Makefile 2009-08-23 17:26:14.000000000 +0200 +++ /tmp/mono/Makefile 2009-11-10 03:08:49.101964688 +0100 @@ -42,7 +42,7 @@ MAKE_ENV= MONO_SHARED_DIR="${MONO_SHARED_DIR}" \ LC_ALL=C -ONLY_FOR_ARCHS= i386 amd64 +ONLY_FOR_ARCHS= i386 amd64 powerpc MAN1= al.1 cert2spc.1 certmgr.1 chktrust.1 cilc.1 csharp.1 disco.1 \ dtd2xsd.1 gacutil.1 genxs.1 httpcfg.1 ilasm.1 jay.1 macpack.1 \ diff -ruN /var/cache/portshaker/freebsd/lang/mono/files/patch-configure /tmp/mono/files/patch-configure --- /var/cache/portshaker/freebsd/lang/mono/files/patch-configure 2009-07-17 14:33:54.000000000 +0200 +++ /tmp/mono/files/patch-configure 2009-11-10 03:08:48.997351873 +0100 @@ -22,7 +22,7 @@ ;; *-*-*openbsd*) platform_win32=no -@@ -39146,8 +39147,8 @@ +@@ -39414,8 +39415,8 @@ INTERP_SUPPORTED=no LIBC="libc.so.6" INTL="libc.so.6" @@ -32,4 +32,13 @@ +SQLITE3="libsqlite3.so.8" X11="libX11.so" - jit_wanted=false + sizeof_register="SIZEOF_VOID_P" +@@ -39675,7 +39676,7 @@ + jit_wanted=true + ;; + macppc-*-openbsd* | powerpc*-*-linux* | powerpc-*-openbsd* | \ +- powerpc-*-sysv* | powerpc-*-darwin* | powerpc-*-netbsd* ) ++ powerpc-*-sysv* | powerpc-*-darwin* | powerpc-*-netbsd* | powerpc-*-freebsd* ) + if test "x$ac_cv_sizeof_void_p" = "x8"; then + TARGET=POWERPC64; + CPPFLAGS="$CPPFLAGS -D__mono_ppc__ -D__mono_ppc64__" diff -ruN /var/cache/portshaker/freebsd/lang/mono/files/patch-mono_mini_mini-ppc.h /tmp/mono/files/patch-mono_mini_mini-ppc.h --- /var/cache/portshaker/freebsd/lang/mono/files/patch-mono_mini_mini-ppc.h 1970-01-01 01:00:00.000000000 +0100 +++ /tmp/mono/files/patch-mono_mini_mini-ppc.h 2009-11-09 21:30:44.773758000 +0100 @@ -0,0 +1,20 @@ + +$FreeBSD$ + +--- mono/mini/mini-ppc.h.orig ++++ mono/mini/mini-ppc.h +@@ -281,6 +281,14 @@ + #define UCONTEXT_REG_FPRn(ctx, n) ((ctx)->uc_mcontext.__fpregs.__fpu_regs [(n)]) + #define UCONTEXT_REG_NIP(ctx) _UC_MACHINE_PC(ctx) + #define UCONTEXT_REG_LNK(ctx) ((ctx)->uc_mcontext.__gregs [_REG_LR]) ++#elif defined(__FreeBSD__) ++#include ++ typedef ucontext_t os_ucontext; ++ ++ #define UCONTEXT_REG_Rn(ctx, n) ((ctx)->uc_mcontext.mc_gpr [(n)]) ++ #define UCONTEXT_REG_FPRn(ctx, n) ((ctx)->uc_mcontext.mc_fpreg [(n)]) ++ #define UCONTEXT_REG_NIP(ctx) ((ctx)->uc_mcontext.mc_srr0) ++ #define UCONTEXT_REG_LNK(ctx) ((ctx)->uc_mcontext.mc_lr) + #else + #error Unknown OS + #endif --ew6BAiZeqk4r7MaW--