Opened 6 months ago

Last modified 5 months ago

#69922 new defect

openjdk8: arm patch has broken ppc

Reported by: barracuda156 Owned by:
Priority: Normal Milestone:
Component: ports Version: 2.9.3
Keywords: powerpc Cc: usersxx, catap (Kirill A. Korinsky), Dave-Allured (Dave Allured)
Port: openjdk8

Description (last modified by ryandesign (Ryan Carsten Schmidt))

Earlier openjdk8 has been building with minimal patches pretty far (though failing on AWT libs down the road), but current revision makes it fail in the very beginning of the build. It looks like arm patch should not be used unconditionally, since it introduces a conflict in definitions:

/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.hpp:38:44: note:   initializing argument 1 of 'static void os::atomic_copy64(volatile void*, volatile void*)'
   38 |   static void atomic_copy64(volatile void *src, volatile void *dst) {
      |                             ~~~~~~~~~~~~~~~^~~
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:423:31: error: invalid conversion from 'const void*' to 'volatile void*' [-fpermissive]
  423 |         os::atomic_copy64(from--, to--);
      |                           ~~~~^~
      |                               |
      |                               const void*
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.hpp:38:44: note:   initializing argument 1 of 'static void os::atomic_copy64(volatile void*, volatile void*)'
   38 |   static void atomic_copy64(volatile void *src, volatile void *dst) {
      |                             ~~~~~~~~~~~~~~~^~~
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp: At global scope:
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:427:8: error: conflicting declaration of C function 'void _Copy_arrayof_conjoint_bytes(const HeapWord*, HeapWord*, size_t)'
  427 |   void _Copy_arrayof_conjoint_bytes(const HeapWord* from,
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:49:8: note: previous declaration 'void _Copy_arrayof_conjoint_bytes(HeapWord*, HeapWord*, size_t)'
   49 |   void _Copy_arrayof_conjoint_bytes  (HeapWord* from, HeapWord* to, size_t count);
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:432:8: error: conflicting declaration of C function 'void _Copy_arrayof_conjoint_jshorts(const HeapWord*, HeapWord*, size_t)'
  432 |   void _Copy_arrayof_conjoint_jshorts(const HeapWord* from,
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:50:8: note: previous declaration 'void _Copy_arrayof_conjoint_jshorts(HeapWord*, HeapWord*, size_t)'
   50 |   void _Copy_arrayof_conjoint_jshorts(HeapWord* from, HeapWord* to, size_t count);
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:437:8: error: conflicting declaration of C function 'void _Copy_arrayof_conjoint_jints(const HeapWord*, HeapWord*, size_t)'
  437 |   void _Copy_arrayof_conjoint_jints(const HeapWord* from,
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:51:8: note: previous declaration 'void _Copy_arrayof_conjoint_jints(HeapWord*, HeapWord*, size_t)'
   51 |   void _Copy_arrayof_conjoint_jints  (HeapWord* from, HeapWord* to, size_t count);
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp:442:8: error: conflicting declaration of C function 'void _Copy_arrayof_conjoint_jlongs(const HeapWord*, HeapWord*, size_t)'
  442 |   void _Copy_arrayof_conjoint_jlongs(const HeapWord* from,
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_java_openjdk8/openjdk8/work/jdk8u-jdk8u372-ga/hotspot/src/share/vm/utilities/copy.hpp:52:8: note: previous declaration 'void _Copy_arrayof_conjoint_jlongs(HeapWord*, HeapWord*, size_t)'
   52 |   void _Copy_arrayof_conjoint_jlongs (HeapWord* from, HeapWord* to, size_t count);
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~

This fails with gcc-4.2 and gcc13 alike. I cannot recall seeing this error before. arm patches were introduced in [674c6c47f1d12c3025ca2ddc231d06270f684222/macports-ports] And yes, I did not touch this for a year, so just now bumped into the breakage.

Change History (4)

comment:1 Changed 6 months ago by ryandesign (Ryan Carsten Schmidt)

Description: modified (diff)

comment:2 Changed 6 months ago by barracuda156

This fixes initial breakages, including the one reported: https://github.com/macports/macports-ports/pull/23844

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

Cc: Dave-Allured added

comment:4 in reply to:  3 Changed 5 months ago by barracuda156

Replying to Dave-Allured:

I am just short on time, and building JDK is a long and annoying process LOL It should be doable, I am trying to unbreak what upstream has done.

Note: See TracTickets for help on using tickets.