gnu: openjdk-10: Fix building on aarch64-linux.

* gnu/packages/java.scm (openjdk-10)[arguments]: Replace inherited
'patch-for-aarch64 phase for changes in source code layout.

Co-authored-by: Christopher Baines <mail@cbaines.net>
Co-authored-by: Tim Johann <t1m@phrogstar.de>
This commit is contained in:
Efraim Flashner 2023-10-05 09:48:49 +03:00
parent 6f8f98f334
commit a31725ff90
No known key found for this signature in database
GPG key ID: 41AAE7DCCA3D8351

View file

@ -9,7 +9,7 @@
;;; Copyright © 2017, 2019, 2021 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2018, 2019 Gábor Boskovits <boskovits@gmail.com>
;;; Copyright © 2018 Chris Marusich <cmmarusich@gmail.com>
;;; Copyright © 2018, 2019, 2020, 2021, 2022 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2018-2023 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2019, 2020, 2021 Björn Höfling <bjoern.hoefling@bjoernhoefling.de>
;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
;;; Copyright © 2020 Raghav Gururajan <raghavgururajan@disroot.org>
@ -1078,6 +1078,18 @@ (define-public openjdk10
(substitute-keyword-arguments (package-arguments openjdk9)
((#:phases phases)
`(modify-phases ,phases
,@(if (target-aarch64?)
`((replace 'patch-for-aarch64
(lambda _
(substitute* "src/hotspot/cpu/aarch64/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")
(string-append "Interpreter specific version of call_VM_base\n"
" using MacroAssembler::call_VM_leaf_base;"))))))
'())
(replace 'fix-java-shebangs
(lambda _
;; This file was "fixed" by patch-source-shebangs, but it requires