[Libreoffice-commits] core.git: bridges/source configure.ac desktop/source jvmfwk/plugins
Caolán McNamara
caolanm at redhat.com
Thu Aug 21 00:54:48 PDT 2014
bridges/source/cpp_uno/gcc3_linux_powerpc64/cpp2uno.cxx | 17 ++++++++++------
configure.ac | 7 ++++++
desktop/source/deployment/misc/dp_platform.cxx | 3 ++
jvmfwk/plugins/sunmajor/pluginlib/vendorbase.hxx | 6 ++++-
4 files changed, 26 insertions(+), 7 deletions(-)
New commits:
commit 170109708e6a082252efba3d2f1726bbd82b6452
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Aug 21 08:52:16 2014 +0100
Related: rhbz#1125588 first steps for ppc64le
almost certainly won't get us too far, but a start
Change-Id: Ic20b97a97b6d506c32322173bd8332d15c3a4555
diff --git a/bridges/source/cpp_uno/gcc3_linux_powerpc64/cpp2uno.cxx b/bridges/source/cpp_uno/gcc3_linux_powerpc64/cpp2uno.cxx
index a4a08c5..1190507 100644
--- a/bridges/source/cpp_uno/gcc3_linux_powerpc64/cpp2uno.cxx
+++ b/bridges/source/cpp_uno/gcc3_linux_powerpc64/cpp2uno.cxx
@@ -31,6 +31,11 @@
#include <stdio.h>
#include <string.h>
+#ifdef OSL_BIGENDIAN
+#define IS_BIG_ENDIAN 1
+#else
+#define IS_BIG_ENDIAN 0
+#endif
using namespace ::com::sun::star::uno;
@@ -139,13 +144,13 @@ static typelib_TypeClass cpp2uno_call(
case typelib_TypeClass_BOOLEAN:
if (ng < ppc64::MAX_GPR_REGS)
{
- pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)gpreg) + (sizeof(void*)-1));
+ pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)gpreg) + 7*IS_BIG_ENDIAN);
ng++;
gpreg++;
}
else
{
- pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)ovrflw) + (sizeof(void*)-1));
+ pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)ovrflw) + 7*IS_BIG_ENDIAN);
bOverflowUsed = true;
}
if (bOverflowUsed) ovrflw++;
@@ -155,13 +160,13 @@ static typelib_TypeClass cpp2uno_call(
case typelib_TypeClass_UNSIGNED_SHORT:
if (ng < ppc64::MAX_GPR_REGS)
{
- pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)gpreg) + (sizeof(void*)-2));
+ pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)gpreg) + 6*IS_BIG_ENDIAN);
ng++;
gpreg++;
}
else
{
- pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)ovrflw) + (sizeof(void*)-2));
+ pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)ovrflw) + 6*IS_BIG_ENDIAN);
bOverflowUsed = true;
}
if (bOverflowUsed) ovrflw++;
@@ -171,13 +176,13 @@ static typelib_TypeClass cpp2uno_call(
case typelib_TypeClass_UNSIGNED_LONG:
if (ng < ppc64::MAX_GPR_REGS)
{
- pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)gpreg) + (sizeof(void*)-4));
+ pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)gpreg) + 4*IS_BIG_ENDIAN);
ng++;
gpreg++;
}
else
{
- pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)ovrflw) + (sizeof(void*)-4));
+ pCppArgs[nPos] = pUnoArgs[nPos] = (((char *)ovrflw) + 4*IS_BIG_ENDIAN);
bOverflowUsed = true;
}
if (bOverflowUsed) ovrflw++;
diff --git a/configure.ac b/configure.ac
index bc823c7..ac3051d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4380,6 +4380,13 @@ linux-gnu*)
PLATFORMID=linux_powerpc64
OUTPATH=unxlngppc64
;;
+ powerpc64le)
+ CPUNAME=POWERPC64
+ RTL_ARCH=PowerPC_64_LE
+ LIB64="lib64"
+ PLATFORMID=linux_powerpc64le
+ OUTPATH=unxlngppc64
+ ;;
sparc)
CPUNAME=SPARC
RTL_ARCH=SPARC
diff --git a/desktop/source/deployment/misc/dp_platform.cxx b/desktop/source/deployment/misc/dp_platform.cxx
index 6b5215a..6e69359 100644
--- a/desktop/source/deployment/misc/dp_platform.cxx
+++ b/desktop/source/deployment/misc/dp_platform.cxx
@@ -35,6 +35,7 @@
#define PLATFORM_LINUX_SPARC "linux_sparc"
#define PLATFORM_LINUX_POWERPC "linux_powerpc"
#define PLATFORM_LINUX_POWERPC64 "linux_powerpc64"
+#define PLATFORM_LINUX_POWERPC64_LE "linux_powerpc64_le"
#define PLATFORM_LINUX_ARM_EABI "linux_arm_eabi"
#define PLATFORM_LINUX_ARM_OABI "linux_arm_oabi"
#define PLATFORM_LINUX_MIPS_EL "linux_mips_el"
@@ -129,6 +130,8 @@ namespace
ret = checkOSandCPU("Linux", "PowerPC");
else if (token == PLATFORM_LINUX_POWERPC64)
ret = checkOSandCPU("Linux", "PowerPC_64");
+ else if (token == PLATFORM_LINUX_POWERPC64_LE)
+ ret = checkOSandCPU("Linux", "PowerPC_64_LE");
else if (token == PLATFORM_LINUX_ARM_EABI)
ret = checkOSandCPU("Linux", "ARM_EABI");
else if (token == PLATFORM_LINUX_ARM_OABI)
diff --git a/jvmfwk/plugins/sunmajor/pluginlib/vendorbase.hxx b/jvmfwk/plugins/sunmajor/pluginlib/vendorbase.hxx
index 25baaee5..fee2430 100644
--- a/jvmfwk/plugins/sunmajor/pluginlib/vendorbase.hxx
+++ b/jvmfwk/plugins/sunmajor/pluginlib/vendorbase.hxx
@@ -40,7 +40,11 @@ namespace jfw_plugin
#elif defined INTEL
#define JFW_PLUGIN_ARCH "i386"
#elif defined POWERPC64
-#define JFW_PLUGIN_ARCH "ppc64"
+#ifdef OSL_BIGENDIAN
+# define JFW_PLUGIN_ARCH "ppc64"
+#else
+# define JFW_PLUGIN_ARCH "ppc64le"
+#endif
#elif defined POWERPC
#define JFW_PLUGIN_ARCH "ppc"
#elif defined MIPS
More information about the Libreoffice-commits
mailing list