Bug 244947 - java/openjdk12: Fails to build on on 13.0-CURRENT
Summary: java/openjdk12: Fails to build on on 13.0-CURRENT
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-java (Nobody)
URL:
Keywords: needs-patch
Depends on:
Blocks:
 
Reported: 2020-03-21 11:20 UTC by Trond Endrestøl
Modified: 2020-04-18 20:43 UTC (History)
2 users (show)

See Also:
bugzilla: maintainer-feedback? (java)


Attachments
Patch for src/hotspot/share/runtime/arguments.cpp (700 bytes, patch)
2020-03-21 11:22 UTC, Trond Endrestøl
no flags Details | Diff
Patch for src/hotspot/share/c1/c1_LIR.cpp (3.08 KB, patch)
2020-03-21 11:24 UTC, Trond Endrestøl
no flags Details | Diff
Patch for src/hotspot/share/runtime/sharedRuntime.cpp (603 bytes, patch)
2020-03-21 11:25 UTC, Trond Endrestøl
no flags Details | Diff
Patch for src/hotspot/share/gc/shenandoah/c1/shenandoahBarrierSetC1.hpp (692 bytes, patch)
2020-03-21 11:27 UTC, Trond Endrestøl
no flags Details | Diff
Patch for src/java.base/share/native/libfdlibm/e_asin.c (715 bytes, patch)
2020-03-21 11:29 UTC, Trond Endrestøl
no flags Details | Diff
Patch for Clang 10 (5.73 KB, patch)
2020-03-29 08:05 UTC, Trond Endrestøl
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Trond Endrestøl 2020-03-21 11:20:44 UTC
Without the five soon to be attached patches, Clang 10 throws a lot of error messages.
Comment 1 Trond Endrestøl 2020-03-21 11:22:17 UTC
Created attachment 212572 [details]
Patch for src/hotspot/share/runtime/arguments.cpp

Patch 1 of 5. Turned pointer comparison into regular C-style string comparison.
Comment 2 Trond Endrestøl 2020-03-21 11:24:08 UTC
Created attachment 212573 [details]
Patch for src/hotspot/share/c1/c1_LIR.cpp

Patch 2 of 5. Weird indentation makes Clang 10 highly suspicious. Solved by adding curly braces.
Comment 3 Trond Endrestøl 2020-03-21 11:25:54 UTC
Created attachment 212574 [details]
Patch for src/hotspot/share/runtime/sharedRuntime.cpp

Patch 3 of 5. Clang 10 wants the extra parenthesis.
Comment 4 Trond Endrestøl 2020-03-21 11:27:21 UTC
Created attachment 212575 [details]
Patch for src/hotspot/share/gc/shenandoah/c1/shenandoahBarrierSetC1.hpp

Patch 4 of 5. Weird indentation makes Clang 10 highly suspicious. Solved by adding curly braces.
Comment 5 Trond Endrestøl 2020-03-21 11:29:02 UTC
Created attachment 212576 [details]
Patch for src/java.base/share/native/libfdlibm/e_asin.c

Patch 5 of 5. Added curly braces to the else branch.
Comment 6 Kubilay Kocak freebsd_committer freebsd_triage 2020-03-24 08:59:37 UTC
@Trond Can you produce a single patch against the port, fixing the errors you've identified using `make makepatch` [1] please:

[1] https://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/slow-patch.html
Comment 7 Trond Endrestøl 2020-03-29 08:05:49 UTC
Created attachment 212819 [details]
Patch for Clang 10
Comment 8 Greg Lewis freebsd_committer freebsd_triage 2020-04-15 02:19:19 UTC
I think the patch for e_asin.c is incorrect

Compare your patch with

https://svnweb.freebsd.org/base/head/lib/msun/src/e_asin.c?revision=317349&view=markup#l87
Comment 9 Greg Lewis freebsd_committer freebsd_triage 2020-04-15 02:28:27 UTC
Nope my bad.  They will do the same thing as the FreeBSD version due to the return in the if statement.
Comment 10 commit-hook freebsd_committer freebsd_triage 2020-04-18 20:42:58 UTC
A commit references this bug:

Author: glewis
Date: Sat Apr 18 20:42:12 UTC 2020
New revision: 532044
URL: https://svnweb.freebsd.org/changeset/ports/532044

Log:
  Update to 12.0.2+10.4

  PR:		244947
  Submitted by:	Trond.Endrestol@ximalas.info

Changes:
  head/java/openjdk12/Makefile
  head/java/openjdk12/distinfo
  head/java/openjdk12/files/patch-src_hotspot_os__cpu_bsd__aarch64_vm__version__bsd__aarch64.cpp
Comment 11 Greg Lewis freebsd_committer freebsd_triage 2020-04-18 20:43:37 UTC
Pulled upstream, released and integrated.