From owner-freebsd-gecko@FreeBSD.ORG Sat Oct 3 19:06:59 2009 Return-Path: Delivered-To: freebsd-gecko@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4CA06106568B for ; Sat, 3 Oct 2009 19:06:59 +0000 (UTC) (envelope-from svn-freebsd-gecko@chruetertee.ch) Received: from trillian.chruetertee.ch (trillian.chruetertee.ch [217.150.245.56]) by mx1.freebsd.org (Postfix) with ESMTP id E5C038FC13 for ; Sat, 3 Oct 2009 19:06:58 +0000 (UTC) Received: from trillian.chruetertee.ch (trillian [217.150.245.56]) by trillian.chruetertee.ch (8.14.3/8.14.3) with ESMTP id n93J6vTS031998 for ; Sat, 3 Oct 2009 19:06:57 GMT (envelope-from svn-freebsd-gecko@chruetertee.ch) Received: (from www@localhost) by trillian.chruetertee.ch (8.14.3/8.14.3/Submit) id n93J6qul031255 for freebsd-gecko@freebsd.org; Sat, 3 Oct 2009 19:06:52 GMT (envelope-from svn-freebsd-gecko@chruetertee.ch) Date: Sat, 3 Oct 2009 19:06:52 GMT Message-Id: <200910031906.n93J6qul031255@trillian.chruetertee.ch> X-Authentication-Warning: trillian.chruetertee.ch: www set sender to svn-freebsd-gecko@chruetertee.ch using -f From: svn-freebsd-gecko@chruetertee.ch To: freebsd-gecko@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [SVN-Commit] r127 - branches/experimental/www/libxul/files X-BeenThere: freebsd-gecko@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-gecko@freebsd.org List-Id: Gecko Rendering Engine issues List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 03 Oct 2009 19:06:59 -0000 Author: andreast Date: Sat Oct 3 19:06:51 2009 New Revision: 127 Log: Fix amd64 support for libxul. Modified: branches/experimental/www/libxul/files/patch-xpcom_reflect_xptcall_src_md_unix_Makefile.in branches/experimental/www/libxul/files/patch-xptcall-amd64 Modified: branches/experimental/www/libxul/files/patch-xpcom_reflect_xptcall_src_md_unix_Makefile.in ============================================================================== --- branches/experimental/www/libxul/files/patch-xpcom_reflect_xptcall_src_md_unix_Makefile.in Fri Oct 2 20:35:57 2009 (r126) +++ branches/experimental/www/libxul/files/patch-xpcom_reflect_xptcall_src_md_unix_Makefile.in Sat Oct 3 19:06:51 2009 (r127) @@ -1,5 +1,5 @@ --- xpcom/reflect/xptcall/src/md/unix/Makefile.in.orig 2009-08-24 17:53:28.000000000 +0200 -+++ xpcom/reflect/xptcall/src/md/unix/Makefile.in 2009-09-27 21:15:47.000000000 +0200 ++++ xpcom/reflect/xptcall/src/md/unix/Makefile.in 2009-10-02 22:34:36.000000000 +0200 @@ -70,6 +70,9 @@ ifeq (Darwin,$(OS_ARCH)) DEFINES += -DKEEP_STACK_16_BYTE_ALIGNED @@ -10,7 +10,7 @@ endif endif # -@@ -87,7 +90,7 @@ +@@ -87,12 +90,20 @@ endif endif # IA64 Linux @@ -19,7 +19,20 @@ ifneq (,$(findstring ia64,$(OS_TEST))) CPPSRCS := xptcinvoke_ipf64.cpp xptcstubs_ipf64.cpp ASFILES := xptcstubs_asm_ipf64.s xptcinvoke_asm_ipf64.s -@@ -150,9 +153,15 @@ + endif + endif ++ ++# ++# FreeBSD/amd64 ++# ++ifeq ($(OS_ARCH)$(OS_TEST),FreeBSDamd64) ++CPPSRCS := xptcinvoke_amd64_freebsd.cpp xptcstubs_amd64_freebsd.cpp ++endif ++ + # + # OpenBSD/amd64 + # +@@ -150,9 +161,15 @@ ASFILES := xptcinvoke_asm_osf1_alpha.s xptcstubs_asm_osf1_alpha.s endif # @@ -36,7 +49,7 @@ CPPSRCS := xptcinvoke_linux_alpha.cpp xptcstubs_linux_alpha.cpp endif # -@@ -304,6 +313,14 @@ +@@ -304,6 +321,14 @@ CXXFLAGS := $(filter-out $(MOZ_OPTIMIZE_FLAGS), $(CXXFLAGS)) endif @@ -51,7 +64,7 @@ # # Linux/PPC # -@@ -385,6 +402,15 @@ +@@ -385,6 +410,15 @@ ASFILES := xptcinvoke_asm_sparc_netbsd.s xptcstubs_asm_sparc_netbsd.s endif # Modified: branches/experimental/www/libxul/files/patch-xptcall-amd64 ============================================================================== --- branches/experimental/www/libxul/files/patch-xptcall-amd64 Fri Oct 2 20:35:57 2009 (r126) +++ branches/experimental/www/libxul/files/patch-xptcall-amd64 Sat Oct 3 19:06:51 2009 (r127) @@ -1,5 +1,5 @@ ---- /dev/null Wed Dec 31 16:00:00 1969 -+++ xpcom/reflect/xptcall/src/md/unix/xptcinvoke_amd64_freebsd.cpp Thu Oct 16 22:59:43 2003 +--- xpcom/reflect/xptcall/src/md/unix/xptcinvoke_amd64_freebsd.cpp.orig 2009-10-02 22:13:13.000000000 +0200 ++++ xpcom/reflect/xptcall/src/md/unix/xptcinvoke_amd64_freebsd.cpp 2009-10-02 22:41:36.000000000 +0200 @@ -0,0 +1,174 @@ +/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +// Platform specific code to invoke XPCOM methods on native objects @@ -98,8 +98,8 @@ +} + +extern "C" -+XPTC_PUBLIC_API(nsresult) -+XPTC_InvokeByIndex(nsISupports * that, PRUint32 methodIndex, ++EXPORT_XPCOM_API(nsresult) ++NS_InvokeByIndex_P(nsISupports * that, PRUint32 methodIndex, + PRUint32 paramCount, nsXPTCVariant * params) +{ + PRUint32 nr_gpr, nr_fpr, nr_stack; @@ -175,14 +175,15 @@ + PRUint32 result = ((Method)methodAddress)(a0, a1, a2, a3, a4, a5); + return result; +} ---- /dev/null Wed Dec 31 16:00:00 1969 -+++ xpcom/reflect/xptcall/src/md/unix/xptcstubs_amd64_freebsd.cpp Thu Oct 16 23:01:08 2003 -@@ -0,0 +1,206 @@ +--- xpcom/reflect/xptcall/src/md/unix/xptcstubs_amd64_freebsd.cpp.orig 2009-10-02 22:13:13.000000000 +0200 ++++ xpcom/reflect/xptcall/src/md/unix/xptcstubs_amd64_freebsd.cpp 2009-10-02 22:39:37.000000000 +0200 +@@ -0,0 +1,200 @@ +/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ + +// Implement shared vtbl methods. + +#include "xptcprivate.h" ++#include "xptiprivate.h" + +// The Linux/x86-64 ABI passes the first 6 integral parameters and the +// first 8 floating point parameters in registers (rdi, rsi, rdx, rcx, @@ -209,7 +210,6 @@ +{ + nsXPTCMiniVariant paramBuffer[PARAM_BUFFER_COUNT]; + nsXPTCMiniVariant* dispatchParams = NULL; -+ nsIInterfaceInfo* iface_info = NULL; + const nsXPTMethodInfo* info; + PRUint32 paramCount; + PRUint32 i; @@ -217,12 +217,7 @@ + + NS_ASSERTION(self,"no self"); + -+ self->GetInterfaceInfo(&iface_info); -+ NS_ASSERTION(iface_info,"no interface info"); -+ if (! iface_info) -+ return NS_ERROR_UNEXPECTED; -+ -+ iface_info->GetMethodInfo(PRUint16(methodIndex), &info); ++ self->mEntry->GetMethodInfo(PRUint16(methodIndex), &info); + NS_ASSERTION(info,"no method info"); + if (! info) + return NS_ERROR_UNEXPECTED; @@ -297,9 +292,8 @@ + } + } + -+ result = self->CallMethod((PRUint16) methodIndex, info, dispatchParams); -+ -+ NS_RELEASE(iface_info); ++ result = self->mOuter->CallMethod((PRUint16)methodIndex, info, ++ dispatchParams); + + if (dispatchParams != paramBuffer) + delete [] dispatchParams;