[MacPorts] #67377: openjdk8: Error: Unable to open port: can't read "datamodel": no such variable
MacPorts
noreply at macports.org
Fri May 5 17:24:38 UTC 2023
#67377: openjdk8: Error: Unable to open port: can't read "datamodel": no such
variable
------------------------+----------------------
Reporter: ryandesign | Owner: usersxx
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.8.1
Keywords: | Port: openjdk8
------------------------+----------------------
The openjdk8 Portfile fails to parse if build_arch is i386 or ppc64:
{{{
% port info openjdk8 build_arch=i386
Error: Unable to open port: can't read "datamodel": no such variable
}}}
Even if the port does not support building for those architectures, the
portfile should still parse so that users can get `port info`, etc.
A simple fix would be:
{{{
--- java/openjdk8/Portfile
+++ java/openjdk8/Portfile
@@ -54,11 +54,9 @@
set tpath /Library/Java
use_xcode yes
use_configure yes
-if {${configure.build_arch} eq "ppc"} {
+if {${configure.build_arch} in [list i386 ppc]} {
set datamodel 32
-} elseif {${configure.build_arch} eq "x86_64"} {
- set datamodel 64
-} elseif {${configure.build_arch} eq "arm64"} {
+} else {
set datamodel 64
}
}}}
--
Ticket URL: <https://trac.macports.org/ticket/67377>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list