Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 10 Nov 2009 02:20:02 GMT
From:      Romain =?iso-8859-1?Q?Tarti=E8re?= <mono@FreeBSD.org>
To:        mono@FreeBSD.org
Subject:   Re: ports/140362: lang/mono: Patches for PowerPC support in mono
Message-ID:  <200911100220.nAA2K2cb069822@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR ports/140362; it has been noted by GNATS.

From: Romain =?iso-8859-1?Q?Tarti=E8re?= <mono@FreeBSD.org>
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 <romain@blogreen.org>        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 <ucontext.h>
 ++	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--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200911100220.nAA2K2cb069822>