]> git.pld-linux.org Git - packages/openjdk9.git/commitdiff
Restore x32.patch
authorJacek Konieczny <j.konieczny@eggsoft.pl>
Fri, 29 Jul 2016 08:02:57 +0000 (10:02 +0200)
committerJacek Konieczny <j.konieczny@eggsoft.pl>
Fri, 29 Jul 2016 08:02:57 +0000 (10:02 +0200)
Only part of it has been obsoleted.

openjdk8.spec
x32.patch [new file with mode: 0644]

index ca0b95267b8ed4e3806ed59486a51160f35aec5e..54bafbd46f6be429fd9c3a3ad5239ba81b8af79f 100644 (file)
@@ -56,6 +56,7 @@ Patch4:               system-libjpeg.patch
 Patch5:                system-libpng.patch
 Patch6:                system-lcms.patch
 Patch7:                system-pcsclite.patch
+Patch8:                x32.patch
 URL:           http://openjdk.java.net/
 BuildRequires: /usr/bin/jar
 BuildRequires: alsa-lib-devel
@@ -421,6 +422,7 @@ done
 %patch5 -p1
 %patch6 -p1
 %patch7 -p1
+%patch8 -p1
 
 %build
 # Make sure we have /proc mounted - otherwise idlc will fail later.
diff --git a/x32.patch b/x32.patch
new file mode 100644 (file)
index 0000000..072ca15
--- /dev/null
+++ b/x32.patch
@@ -0,0 +1,108 @@
+diff -durN jdk8u-jdk8u66-b02.orig/common/autoconf/platform.m4 jdk8u-jdk8u66-b02/common/autoconf/platform.m4
+--- jdk8u-jdk8u66-b02.orig/common/autoconf/platform.m4 2015-07-17 09:35:23.000000000 +0200
++++ jdk8u-jdk8u66-b02/common/autoconf/platform.m4      2015-09-21 13:18:18.439165925 +0200
+@@ -31,10 +31,20 @@
+   # First argument is the cpu name from the trip/quad
+   case "$1" in
+     x86_64)
+-      VAR_CPU=x86_64
+-      VAR_CPU_ARCH=x86
+-      VAR_CPU_BITS=64
+-      VAR_CPU_ENDIAN=little
++      case "$target_os" in
++        *x32)
++          VAR_CPU=x32
++          VAR_CPU_ARCH=x86
++          VAR_CPU_BITS=32
++          VAR_CPU_ENDIAN=little
++          ;;
++        *)
++          VAR_CPU=x86_64
++          VAR_CPU_ARCH=x86
++          VAR_CPU_BITS=64
++          VAR_CPU_ENDIAN=little
++          ;;
++      esac
+       ;;
+     i?86)
+       VAR_CPU=x86
+@@ -375,7 +385,16 @@
+     ppc64)   ZERO_ARCHDEF=PPC64 ;;
+     s390*)   ZERO_ARCHDEF=S390  ;;
+     sparc*)  ZERO_ARCHDEF=SPARC ;;
+-    x86_64*) ZERO_ARCHDEF=AMD64 ;;
++    x86_64*)
++      case "$target_os" in
++        *x32)
++          ZERO_ARCHDEF=X32
++          ;;
++        *)
++          ZERO_ARCHDEF=AMD64
++          ;;
++      esac
++      ;;
+     x86)     ZERO_ARCHDEF=IA32  ;;
+     *)      ZERO_ARCHDEF=$(echo "${OPENJDK_TARGET_CPU_LEGACY_LIB}" | tr a-z A-Z)
+   esac
+diff -durN jdk8u-jdk8u66-b02.orig/hotspot/src/os/linux/vm/os_linux.cpp jdk8u-jdk8u66-b02/hotspot/src/os/linux/vm/os_linux.cpp
+--- jdk8u-jdk8u66-b02.orig/hotspot/src/os/linux/vm/os_linux.cpp        2015-09-21 13:05:51.883678088 +0200
++++ jdk8u-jdk8u66-b02/hotspot/src/os/linux/vm/os_linux.cpp     2015-09-21 13:12:58.665870862 +0200
+@@ -1902,7 +1902,7 @@
+   #if  (defined IA32)
+     static  Elf32_Half running_arch_code=EM_386;
+-  #elif   (defined AMD64)
++  #elif  (defined AMD64) || (defined X32)
+     static  Elf32_Half running_arch_code=EM_X86_64;
+   #elif  (defined IA64)
+     static  Elf32_Half running_arch_code=EM_IA_64;
+diff -durN jdk8u-jdk8u66-b02.orig/jdk/make/gensrc/GensrcX11Wrappers.gmk jdk8u-jdk8u66-b02/jdk/make/gensrc/GensrcX11Wrappers.gmk
+--- jdk8u-jdk8u66-b02.orig/jdk/make/gensrc/GensrcX11Wrappers.gmk       2015-07-23 16:17:35.000000000 +0200
++++ jdk8u-jdk8u66-b02/jdk/make/gensrc/GensrcX11Wrappers.gmk    2015-09-21 13:13:00.339291213 +0200
+@@ -87,9 +87,11 @@
+       $(TOOL_WRAPPERGENERATOR) $(@D) $(GENSRC_SIZER_DIR)/xlibtypes.txt "sizer" $*
+   # use -m32/-m64 only if the compiler supports it
++  ifneq ($(OPENJDK_TARGET_CPU),x32)
+   ifeq ($(COMPILER_SUPPORTS_TARGET_BITS_FLAG), true)
+     MEMORY_MODEL_FLAG="$(COMPILER_TARGET_BITS_FLAG)$*"
+   endif
++  endif
+   # Compile the C code into an executable.
+   $(GENSRC_X11WRAPPERS_TMP)/sizer.%.exe: $(GENSRC_X11WRAPPERS_TMP)/sizer.%.c
+diff -durN jdk8u-jdk8u66-b02.orig/jdk/src/solaris/native/java/net/PlainDatagramSocketImpl.c jdk8u-jdk8u66-b02/jdk/src/solaris/native/java/net/PlainDatagramSocketImpl.c
+--- jdk8u-jdk8u66-b02.orig/jdk/src/solaris/native/java/net/PlainDatagramSocketImpl.c   2015-07-23 16:17:35.000000000 +0200
++++ jdk8u-jdk8u66-b02/jdk/src/solaris/native/java/net/PlainDatagramSocketImpl.c        2015-09-21 13:13:00.335957707 +0200
+@@ -35,7 +35,6 @@
+ #endif
+ #ifdef __linux__
+ #include <unistd.h>
+-#include <sys/sysctl.h>
+ #include <sys/utsname.h>
+ #include <netinet/ip.h>
+diff -durN jdk8u-jdk8u66-b02.orig/jdk/src/solaris/native/java/net/PlainSocketImpl.c jdk8u-jdk8u66-b02/jdk/src/solaris/native/java/net/PlainSocketImpl.c
+--- jdk8u-jdk8u66-b02.orig/jdk/src/solaris/native/java/net/PlainSocketImpl.c   2015-07-23 16:17:35.000000000 +0200
++++ jdk8u-jdk8u66-b02/jdk/src/solaris/native/java/net/PlainSocketImpl.c        2015-09-21 13:13:00.335957707 +0200
+@@ -43,7 +43,6 @@
+ #endif
+ #ifdef __linux__
+ #include <unistd.h>
+-#include <sys/sysctl.h>
+ #endif
+ #include "jvm.h"
+--- jdk8u-jdk8u66-b02.orig/common/autoconf/toolchain.m4        2015-07-17 09:35:23.000000000 +0200
++++ jdk8u-jdk8u66-b02/common/autoconf/toolchain.m4     2015-09-21 16:00:30.328673989 +0200
+@@ -361,6 +361,7 @@
+   # Option used to tell the compiler whether to create 32- or 64-bit executables
+   # Notice that CC contains the full compiler path at this point.
+   case $CC in
++    *x32-*) COMPILER_TARGET_BITS_FLAG="-mx";;
+     *xlc_r) COMPILER_TARGET_BITS_FLAG="-q";;
+     *)      COMPILER_TARGET_BITS_FLAG="-m";;
+   esac
+
+
This page took 0.154669 seconds and 4 git commands to generate.