diff --git a/java/openjdk11/Makefile b/java/openjdk11/Makefile index a7fd3dd0536c..aab32398480a 100644 --- a/java/openjdk11/Makefile +++ b/java/openjdk11/Makefile @@ -89,10 +89,6 @@ JDK_BUILD_TYPE= release .include -.if ${ARCH} == i386 -CONFIGURE_ARGS+= --disable-dtrace -.endif - BOOTSTRAP_JDKS= ${LOCALBASE}/openjdk11 \ ${LOCALBASE}/bootstrap-openjdk11 diff --git a/java/openjdk11/files/patch-make_hotspot_lib_JvmDtraceObjects.gmk b/java/openjdk11/files/patch-make_hotspot_lib_JvmDtraceObjects.gmk new file mode 100644 index 000000000000..a3bc5762dedb --- /dev/null +++ b/java/openjdk11/files/patch-make_hotspot_lib_JvmDtraceObjects.gmk @@ -0,0 +1,18 @@ +--- make/hotspot/lib/JvmDtraceObjects.gmk ++++ make/hotspot/lib/JvmDtraceObjects.gmk +@@ -201,8 +201,13 @@ ifeq ($(call check-jvm-feature, dtrace), true) + ) + endif + +- DTRACE_FLAGS := -64 -G +- DTRACE_CPP_FLAGS := -D_LP64 -x c ++ ifeq ($(OPENJDK_TARGET_CPU_BITS), 32) ++ DTRACE_FLAGS := -32 -G ++ DTRACE_CPP_FLAGS := -x c ++ else ++ DTRACE_FLAGS := -64 -G ++ DTRACE_CPP_FLAGS := -D_LP64 -x c ++ endif + + # Make sure we run our selected compiler for preprocessing instead of letting + # the dtrace tool pick it on it's own.