[PATCH] gnu: openjdk9: Fix build on aarch64.

  • Done
  • quality assurance status badge
Details
4 participants
  • Andreas Enge
  • burning2007
  • Ludovic Courtès
  • Christopher Baines
Owner
unassigned
Submitted by
Christopher Baines
Severity
normal
C
C
Christopher Baines wrote on 6 May 2023 12:50
(address . guix-patches@gnu.org)
bfe5cba3542670b2244cbedc383d4be95190400e.1683370247.git.mail@cbaines.net
* gnu/packages/java.scm (openjdk9)[arguments]: Add 'patch-for-aarch64 phase to
remove duplicate line in interp_masm_aarch64.hpp.
---
gnu/packages/java.scm | 12 ++++++++++++
1 file changed, 12 insertions(+)

Toggle diff (27 lines)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 067284017c..166417a73d 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -884,6 +884,18 @@ (define-public openjdk9
#:phases
(modify-phases %standard-phases
+ ,@(if (target-aarch64?)
+ `((add-after 'unpack 'patch-for-aarch64
+ (lambda _
+ (substitute* "hotspot/src/cpu/aarch64/vm/interp_masm_aarch64.hpp"
+ ;; This line is duplicated, so remove both occurrences,
+ ;; then add back one occurrence by substituting a
+ ;; comment that occurs once.
+ (("using MacroAssembler::call_VM_leaf_base;") "")
+ (("Interpreter specific version of call_VM_base")
+ "Interpreter specific version of call_VM_base
+ using MacroAssembler::call_VM_leaf_base;")))))
+ '())
(add-after 'patch-source-shebangs 'fix-java-shebangs
(lambda _
;; This file was "fixed" by patch-source-shebangs, but it requires

base-commit: 64086a4fa449a9f6d2f835fcdf5498222b309e3a
--
2.39.1
B
B
burning2007 wrote on 9 May 2023 04:45
(name . 63327@debbugs.gnu.org)(address . 63327@debbugs.gnu.org)
263341683599922@mail.yandex.ru
Attachment: file
A
A
Anthony wrote on 9 May 2023 05:10
(address . 63327@debbugs.gnu.org)(address . burning2007@ya.ru)
20230509031039.1060838-1-burning2007@ya.ru
From: burning2007@ya.ru

Hello!

I've encountered this issue and tested similar solution (patch). It builds successfully. It even allows openjdk@10 to build as well - mine has same build errors as for openjdk@9.

But, on the other hand, it is not sufficient for building jdk@9 itself - please, take a look at https://issues.guix.gnu.org/issue/63069.

P. S. Sorry for attachment in previous message - my email provider does not even have a plain text option in UI.

--
Best regards,

Anthony
L
L
Ludovic Courtès wrote on 22 May 2023 16:50
(name . Christopher Baines)(address . mail@cbaines.net)(address . 63327@debbugs.gnu.org)
874jo4xvxf.fsf@gnu.org
Christopher Baines <mail@cbaines.net> skribis:

Toggle quote (3 lines)
> * gnu/packages/java.scm (openjdk9)[arguments]: Add 'patch-for-aarch64 phase to
> remove duplicate line in interp_masm_aarch64.hpp.

I’d say go for it if it fixes the problem.

Thanks,
Ludo’.
A
A
Andreas Enge wrote on 26 Jul 2023 16:00
Close
(address . 63327-done@debbugs.gnu.org)
ZMEnCMsiRqn2jfx5@jurong
I just ran the patch, and can confirm that it enables the build of openjdk@9
on aarch64. So I have pushed it and am closing this bug.


Andreas
Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 63327@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 63327
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch