refactor: support armhf
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
This commit is contained in:
parent
19ee736e1d
commit
545944cb0d
@ -29,9 +29,14 @@ struct RuntimeContext {
|
||||
QString system;
|
||||
|
||||
QString mappedJavaRealArchitecture() const {
|
||||
if (javaRealArchitecture == "aarch64") {
|
||||
if (javaRealArchitecture == "amd64")
|
||||
return "x86_64";
|
||||
if (javaRealArchitecture == "i386" || javaRealArchitecture == "i686")
|
||||
return "x86";
|
||||
if (javaRealArchitecture == "aarch64")
|
||||
return "arm64";
|
||||
}
|
||||
if (javaRealArchitecture == "arm" || javaRealArchitecture == "armhf")
|
||||
return "arm32";
|
||||
return javaRealArchitecture;
|
||||
}
|
||||
|
||||
@ -48,8 +53,8 @@ struct RuntimeContext {
|
||||
|
||||
// "Legacy" refers to the fact that Mojang assumed that these are the only two architectures
|
||||
bool isLegacyArch() const {
|
||||
QSet<QString> legacyArchitectures{"amd64", "x86_64", "i386", "i686", "x86"};
|
||||
return legacyArchitectures.contains(mappedJavaRealArchitecture());
|
||||
const QString mapped = mappedJavaRealArchitecture();
|
||||
return mapped == "x86_64" || mapped == "x86";
|
||||
}
|
||||
|
||||
bool classifierMatches(QString target) const {
|
||||
|
Loading…
Reference in New Issue
Block a user