Opened 10 months ago

Last modified 4 months ago

#69120 assigned update

openjdk8: Update to 8u402

Reported by: breun (Nils Breunese) Owned by: usersxx
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc: Dave-Allured (Dave Allured)
Port: openjdk8

Description (last modified by breun (Nils Breunese))

The openjdk8 is currently at version 8u372, which is three releases behind the current latest version. The current version in MacPorts is missing fixes for various vulnerabilities:

When I try bumping the version beyond 8u372 locally, the openjdk8 build fails on my macOS 14 (arm64) machine. With 8u402 the build log ends with this:

:info:build dtrace headers generated
:info:build gmake[6]: Leaving directory '/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/build/openjdk8/hotspot/bsd_aarch64_zero/product'
:info:build gmake[6]: Entering directory '/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/build/openjdk8/hotspot/bsd_aarch64_zero/product'
:info:build Generating precompiled header precompiled.hpp.pch
:info:build In file included from <built-in>:1:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/precompiled/precompiled.hpp:29:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/asm/assembler.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/asm/codeBuffer.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/code/oopRecorder.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/universe.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/runtime/handles.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/oops/klass.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/genOopClosures.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/iterator.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/allocation.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/runtime/globals.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/utilities/debug.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/utilities/globalDefinitions.hpp:38:
:info:build /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/utilities/globalDefinitions_gcc.hpp:252:59: error: use of undec
lared identifier 'finite'; did you mean 'isfinite'?
:info:build inline int g_isfinite(jfloat  f)                 { return finite(f); }
:info:build                                                           ^~~~~~
:info:build                                                           isfinite
:info:build /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.sdk/usr/include/c++/v1/math.h:403:80: note: 'isfinite' declared here
:info:build _LIBCPP_NODISCARD_EXT _LIBCPP_CONSTEXPR_SINCE_CXX23 _LIBCPP_HIDE_FROM_ABI bool isfinite(_A1 __x) _NOEXCEPT {
:info:build                                                                                ^
:info:build In file included from <built-in>:1:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/precompiled/precompiled.hpp:29:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/asm/assembler.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/asm/codeBuffer.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/code/oopRecorder.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/universe.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/runtime/handles.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/oops/klass.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/genOopClosures.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/iterator.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/allocation.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/runtime/globals.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/utilities/debug.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/utilities/globalDefinitions.hpp:38:
:info:build /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/utilities/globalDefinitions_gcc.hpp:253:59: error: use of undec
lared identifier 'finite'; did you mean 'isfinite'?
:info:build inline int g_isfinite(jdouble f)                 { return finite(f); }
:info:build                                                           ^~~~~~
:info:build                                                           isfinite
:info:build /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.sdk/usr/include/c++/v1/math.h:403:80: note: 'isfinite' declared here
:info:build _LIBCPP_NODISCARD_EXT _LIBCPP_CONSTEXPR_SINCE_CXX23 _LIBCPP_HIDE_FROM_ABI bool isfinite(_A1 __x) _NOEXCEPT {
:info:build                                                                                ^
:info:build In file included from <built-in>:1:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/precompiled/precompiled.hpp:29:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/asm/assembler.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/asm/codeBuffer.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/code/oopRecorder.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/universe.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/runtime/handles.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/oops/klass.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/genOopClosures.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/iterator.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/memory/allocation.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/runtime/globals.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/utilities/debug.hpp:28:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/share/vm/utilities/globalDefinitions.hpp:450:
:info:build In file included from /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/src/cpu/zero/vm/globalDefinitions_zero.hpp:29:
:info:build /opt/local/include/ffi.h:477:5: warning: 'FFI_GO_CLOSURES' is not defined, evaluates to 0 [-Wundef]
:info:build #if FFI_GO_CLOSURES
:info:build     ^
:info:build 1 warning and 2 errors generated.
:info:build gmake[6]: *** [/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/make/bsd/makefiles/vm.make:311: precompiled.hpp.pch] Error 1
:info:build gmake[6]: Leaving directory '/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/build/openjdk8/hotspot/bsd_aarch64_zero/product'
:info:build gmake[5]: *** [/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/make/bsd/makefiles/top.make:128: the_vm] Error 2
:info:build gmake[5]: Leaving directory '/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/build/openjdk8/hotspot/bsd_aarch64_zero/product'
:info:build gmake[4]: *** [/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/make/bsd/Makefile:314: productzero] Error 2
:info:build gmake[4]: Leaving directory '/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/build/openjdk8/hotspot'
:info:build gmake[3]: *** [Makefile:261: generic_buildzero] Error 2
:info:build gmake[3]: Leaving directory '/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/make'
:info:build gmake[2]: *** [Makefile:185: productzero] Error 2
:info:build gmake[2]: Leaving directory '/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/hotspot/make'
:info:build gmake[1]: *** [HotspotWrapper.gmk:45: /opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/build/openjdk8/hotspot/_hotspot.timestamp] Error 2
:info:build gmake[1]: Leaving directory '/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga/make'
:info:build gnumake: *** [hotspot-only] Error 2
:info:build gnumake: Leaving directory `/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga'
:info:build Command failed:  cd "/opt/local/var/macports/build/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/work/jdk8u-jdk8u402-ga" && /usr/bin/gnumake -j1 COMPILER_WARNINGS_FATAL=false -w all 
:info:build Exit code: 2
:error:build Failed to build openjdk8: command execution failed
:debug:build Error code: CHILDSTATUS 98188 2
:debug:build Backtrace: command execution failed
:debug:build     while executing
:debug:build "system {*}$notty {*}$callback {*}$nice $fullcmdstring"
:debug:build     invoked from within
:debug:build "command_exec -callback portprogress::target_progress_callback build"
:debug:build     (procedure "portbuild::build_main" line 8)
:debug:build     invoked from within
:debug:build "$procedure $targetname"
:error:build See /opt/local/var/macports/logs/_Users_breun_Projects_macports-ports-test_java_openjdk8/openjdk8/main.log for details.

Apparently some changes are needed, but I don't know how to deal with this build failure.

Change History (17)

comment:1 Changed 10 months ago by breun (Nils Breunese)

Description: modified (diff)

comment:2 Changed 10 months ago by jmroot (Joshua Root)

#69124 was opened for the finite() error.

comment:3 Changed 9 months ago by Dave-Allured (Dave Allured)

Cc: Dave-Allured added

comment:4 Changed 9 months ago by Dave-Allured (Dave Allured)

  • I had to add github.com/openjdk to master_sites to get this version to work for me. I am unsure whether this is correct. @breun, would you please take a look and see if this addition is okay with you?
  • If anyone has the time, please test this portfile on your own system and report here, so that I can improve the testing profile of my PR. Thanks in advance.

comment:5 Changed 9 months ago by breun (Nils Breunese)

Looking at https://openjdk.org/projects/jdk/ it looks like the official repository is now on GitHub, so I think you should just replace https://git.openjdk.org/jdk8u/archive/refs/tags/ with https://github.com/openjdk/jdk8u/archive/refs/tags/

comment:6 Changed 7 months ago by breun (Nils Breunese)

comment:7 in reply to:  5 Changed 7 months ago by ryandesign (Ryan Carsten Schmidt)

Replying to breun:

Looking at https://openjdk.org/projects/jdk/ it looks like the official repository is now on GitHub, so I think you should just replace https://git.openjdk.org/jdk8u/archive/refs/tags/ with https://github.com/openjdk/jdk8u/archive/refs/tags/

Ideally one uses the facilities of the github portgroup for projects that are hosted on GitHub rather than implementing things manually.

comment:8 Changed 7 months ago by Dave-Allured (Dave Allured)

@breun @ryandesign

it looks like the official repository is now on GitHub, so I think you should just replace ...

The official release announcement points to a private repo for current source. So why use github?
https://mail.openjdk.org/pipermail/jdk8u-dev/2024-April/018329.html
https://openjdk-sources.osci.io/openjdk8/openjdk8u412-b08.tar.xz

comment:9 Changed 7 months ago by Dave-Allured (Dave Allured)

I am now working on updating the source build to 8u412. I switched to the official source repo and fixed some patches.
https://github.com/Dave-Allured/macports-ports/tree/openjdk8.5/java/openjdk8

The current problem for Ventura is:

... work/jdk8u412-b08/hotspot/agent/src/os/bsd/MacosxDebuggerLocal.m:27:9:
note: did not find header 'JavaNativeFoundation.h' in framework 'JavaNativeFoundation'
(loaded from '/Applications/Xcode_15.0.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.0.sdk/System/Library/Frameworks')

It looks like Apple dropped partial support for JavaNativeFoundation in recent SDK's. Do you have any idea how to fix this?

Last edited 7 months ago by Dave-Allured (Dave Allured) (previous) (diff)

comment:10 Changed 7 months ago by Dave-Allured (Dave Allured)

Missing JavaNativeFoundation was originally discussed in #63319, with no final resolution.

comment:11 Changed 7 months ago by Dave-Allured (Dave Allured)

The JavaNativeFoundation framework is present in all versions. However ...

C headers are present in the MacOS 13 SDK (Ventura):

[mac30:Library/Frameworks/JavaNativeFoundation.framework] dallured% pwd
/Library/Developer/CommandLineTools/SDKs/MacOSX13.3.sdk/System/Library/Frameworks/JavaNativeFoundation.framework
[mac30:Library/Frameworks/JavaNativeFoundation.framework] dallured% ls -Tgo `find * -type f`
-rw-r--r--  1    2017 Mar  4 15:01:08 2023 Versions/A/Headers/JNFAssert.h
-rw-r--r--  1     764 Mar  4 15:01:08 2023 Versions/A/Headers/JNFAutoreleasePool.h
-rw-r--r--  1    1157 Mar  4 15:01:08 2023 Versions/A/Headers/JNFDate.h
-rw-r--r--  1    2185 Mar  4 15:01:09 2023 Versions/A/Headers/JNFException.h
-rw-r--r--  1   14031 Mar  4 15:01:09 2023 Versions/A/Headers/JNFJNI.h
-rw-r--r--  1    1547 Mar  4 15:01:09 2023 Versions/A/Headers/JNFJObjectWrapper.h
-rw-r--r--  1    1079 Mar  4 15:01:08 2023 Versions/A/Headers/JNFNumber.h
-rw-r--r--  1     682 Mar  4 15:01:08 2023 Versions/A/Headers/JNFObject.h
-rw-r--r--  1     810 Mar  4 15:01:09 2023 Versions/A/Headers/JNFPath.h
-rw-r--r--  1     632 Mar  4 15:01:09 2023 Versions/A/Headers/JNFRunLoop.h
-rw-r--r--  1     501 Mar  4 15:01:09 2023 Versions/A/Headers/JNFRunnable.h
-rw-r--r--  1    1594 Mar  4 15:01:08 2023 Versions/A/Headers/JNFString.h
-rw-r--r--  1    1948 Sep 26 13:24:22 2023 Versions/A/Headers/JNFThread.h
-rw-r--r--  1    2836 Mar  4 15:01:09 2023 Versions/A/Headers/JNFTypeCoercion.h
-rw-r--r--  1     820 Mar  4 15:01:09 2023 Versions/A/Headers/JavaNativeFoundation.h
-rw-r--r--  1   68548 Mar  4 15:01:08 2023 Versions/A/Headers/jnf_fallback_jni.h
-rw-r--r--  1     507 Mar  4 15:01:09 2023 Versions/A/Headers/jnf_fallback_jni_md.h
-rw-r--r--  1    3848 Mar  4 15:01:10 2023 Versions/A/JavaNativeFoundation.tbd
-rw-r--r--  1     137 Mar  4 15:00:20 2023 Versions/A/Modules/module.modulemap

C headers were removed in the MacOS 14 SDK (Sonoma):

[mac30:Library/Frameworks/JavaNativeFoundation.framework] dallured% pwd
/Library/Developer/CommandLineTools/SDKs/MacOSX14.2.sdk/System/Library/Frameworks/JavaNativeFoundation.framework
[mac30:Library/Frameworks/JavaNativeFoundation.framework] dallured% ls -Tgo `find * -type f`
-rw-r--r--  1   3848 Nov 12 02:15:15 2023 Versions/A/JavaNativeFoundation.tbd

comment:12 Changed 7 months ago by Dave-Allured (Dave Allured)

Is it possible to select a framework specifically from /Library/Developer/CommandLineTools, rather than from the current Xcode bundle?

comment:13 Changed 5 months ago by isolated-matrix

I've come across a similar issue trying to install openjdk8 (8u372_2), however the end of the output log looks slightly different:

:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:245:16: warning: format string is not a string literal [-Wformat-nonliteral]
:info:build   sprintf(buf, fmt, sig, info->si_addr);
:info:build                ^~~
:info:build Compiling /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/ostream.cpp
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:384:8: error: conflicting types for '_Copy_conjoint_jshorts_atomic'
:info:build   void _Copy_conjoint_jshorts_atomic(const jshort* from, jshort* to, size_t count) {
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:44:8: note: previous declaration is here
:info:build   void _Copy_conjoint_jshorts_atomic(jshort* from, jshort* to, size_t count);
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:398:8: error: conflicting types for '_Copy_conjoint_jints_atomic'
:info:build   void _Copy_conjoint_jints_atomic(const jint* from, jint* to, size_t count) {
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:45:8: note: previous declaration is here
:info:build   void _Copy_conjoint_jints_atomic  (jint*   from, jint*   to, size_t count);
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:412:8: error: conflicting types for '_Copy_conjoint_jlongs_atomic'
:info:build   void _Copy_conjoint_jlongs_atomic(const jlong* from, jlong* to, size_t count) {
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:46:8: note: previous declaration is here
:info:build   void _Copy_conjoint_jlongs_atomic (jlong*  from, jlong*  to, size_t count);
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:416:27: error: cannot initialize a parameter of type 'volatile void *' with an rvalue of type 'const jlong *' (aka 'const long *')
:info:build         os::atomic_copy64(from++, to++);
:info:build                           ^~~~~~
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.hpp:38:44: note: passing argument to parameter 'src' here
:info:build   static void atomic_copy64(volatile void *src, volatile void *dst) {
:info:build                                            ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:423:27: error: cannot initialize a parameter of type 'volatile void *' with an rvalue of type 'const jlong *' (aka 'const long *')
:info:build         os::atomic_copy64(from--, to--);
:info:build                           ^~~~~~
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.hpp:38:44: note: passing argument to parameter 'src' here
:info:build   static void atomic_copy64(volatile void *src, volatile void *dst) {
:info:build                                            ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:427:8: error: conflicting types for '_Copy_arrayof_conjoint_bytes'
:info:build   void _Copy_arrayof_conjoint_bytes(const HeapWord* from,
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:49:8: note: previous declaration is here
:info:build   void _Copy_arrayof_conjoint_bytes  (HeapWord* from, HeapWord* to, size_t count);
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:432:8: error: conflicting types for '_Copy_arrayof_conjoint_jshorts'
:info:build   void _Copy_arrayof_conjoint_jshorts(const HeapWord* from,
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:50:8: note: previous declaration is here
:info:build   void _Copy_arrayof_conjoint_jshorts(HeapWord* from, HeapWord* to, size_t count);
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:437:8: error: conflicting types for '_Copy_arrayof_conjoint_jints'
:info:build   void _Copy_arrayof_conjoint_jints(const HeapWord* from,
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:51:8: note: previous declaration is here
:info:build   void _Copy_arrayof_conjoint_jints  (HeapWord* from, HeapWord* to, size_t count);
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:442:8: error: conflicting types for '_Copy_arrayof_conjoint_jlongs'
:info:build   void _Copy_arrayof_conjoint_jlongs(const HeapWord* from,
:info:build        ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:52:8: note: previous declaration is here
:info:build   void _Copy_arrayof_conjoint_jlongs (HeapWord* from, HeapWord* to, size_t count);
:info:build        ^
:info:build Done with /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/interpreter/oopMapCache.cpp
:info:build Compiling /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/gc_implementation/parNew/parCardTableModRefBS.cpp
:info:build 1 warning and 9 errors generated.
:info:build gmake[6]: *** [/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/make/bsd/makefiles/rules.make:151: os_bsd_zero.o] Error 1
:info:build gmake[6]: *** Waiting for unfinished jobs....
:info:build Done with /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/code/nmethod.cpp
:info:build Done with /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/runtime/os.cpp
:info:build Done with /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os/posix/vm/os_posix.cpp
:info:build Done with /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os/bsd/vm/os_perf_bsd.cpp
:info:build Done with /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/gc_implementation/parNew/parCardTableModRefBS.cpp
:info:build Done with /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/ostream.cpp
:info:build Done with /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/oops/objArrayKlass.cpp
:info:build Done with /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os/bsd/vm/os_bsd.cpp
:info:build gmake[6]: Leaving directory '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/build/openjdk8/hotspot/bsd_aarch64_zero/product'
:info:build gmake[5]: *** [/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/make/bsd/makefiles/top.make:129: the_vm] Error 2
:info:build gmake[5]: Leaving directory '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/build/openjdk8/hotspot/bsd_aarch64_zero/product'
:info:build gmake[4]: *** [/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/make/bsd/Makefile:314: productzero] Error 2
:info:build gmake[4]: Leaving directory '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/build/openjdk8/hotspot'
:info:build gmake[3]: *** [Makefile:261: generic_buildzero] Error 2
:info:build gmake[3]: Leaving directory '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/make'
:info:build gmake[2]: *** [Makefile:185: productzero] Error 2
:info:build gmake[2]: Leaving directory '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/make'
:info:build gmake[1]: *** [HotspotWrapper.gmk:45: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/build/openjdk8/hotspot/_hotspot.timestamp] Error 2
:info:build gmake[1]: Leaving directory '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/make'
:info:build gnumake: *** [hotspot-only] Error 2
:info:build gnumake: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga'
:info:build Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga" && /usr/bin/gnumake COMPILER_WARNINGS_FATAL=false -w all 
:info:build Exit code: 2
:error:build Failed to build openjdk8: command execution failed
:debug:build Error code: CHILDSTATUS 3720 2
:debug:build Backtrace: command execution failed
:debug:build     while executing
:debug:build "system {*}$notty {*}$callback {*}$nice $fullcmdstring"
:debug:build     invoked from within
:debug:build "command_exec -callback portprogress::target_progress_callback build"
:debug:build     (procedure "portbuild::build_main" line 10)
:debug:build     invoked from within
:debug:build "$procedure $targetname"
:error:build See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_java_openjdk8/openjdk8/main.log for details.

I'm not sure if this is the same issue (I understand none of output in the log file), but, based on the last few lines of the log file, it certainly sounds like the problems could have the same cause (if it is a different issue, let me know and I will make a separate ticket). Has there been any progress on this ticket since the last comment? Any workarounds which might be able to get openjdk8 working on Sonoma?

comment:14 Changed 5 months ago by Dave-Allured (Dave Allured)

@isolated-matrix, your primary error is:

error: conflicting types for '_Copy_conjoint_jshorts_atomic'

That is a duplicate of https://trac.macports.org/ticket/69583.

A patch fix for this is part of my work in progress for the 8u412 update, but that is currently stuck on a different issue.
https://github.com/Dave-Allured/macports-ports/tree/openjdk8.5/java/openjdk8

If you are building on Sonoma, then your build logs may contain an important clue for my current problem, which is missing header files. Please post your config.log and main.log. Please post as file attachments, not inline. Thank you.

Last edited 5 months ago by Dave-Allured (Dave Allured) (previous) (diff)

comment:15 in reply to:  13 Changed 5 months ago by breun (Nils Breunese)

Replying to isolated-matrix:

Any workarounds which might be able to get openjdk8 working on Sonoma?

Maybe you can also do what you want to do using one of the openjdk8-* ports that install a pre-built binary OpenJDK distribution? openjdk8-zulu install Azul Zulu OpenJDK, openjdk8-temurin installs Eclipse Temurin, openjdk8-corretto installs Amazon Corretto OpenJDK and openjdk8-openj9 installs IBM Semeru OpenJ9.

comment:16 in reply to:  14 Changed 4 months ago by barracuda156

Replying to Dave-Allured:

@isolated-matrix, your primary error is:

error: conflicting types for '_Copy_conjoint_jshorts_atomic'

That is a duplicate of https://trac.macports.org/ticket/69583.

A patch fix for this is part of my work in progress for the 8u412 update, but that is currently stuck on a different issue.
https://github.com/Dave-Allured/macports-ports/tree/openjdk8.5/java/openjdk8

If you are building on Sonoma, then your build logs may contain an important clue for my current problem, which is missing header files. Please post your config.log and main.log. Please post as file attachments, not inline. Thank you.

Ah, okay, so it is expected that it fails on Sonoma.

I got a PowerPC fix in https://github.com/macports/macports-ports/pull/24872

comment:17 Changed 4 months ago by Dave-Allured (Dave Allured)

Note: See TracTickets for help on using tickets.