mirror of
https://github.com/AngelAuraMC/Amethyst-Android.git
synced 2025-09-17 08:35:37 -04:00
Fix rumtime
This commit is contained in:
parent
4089fa270c
commit
2cef96b8fa
2
.github/workflows/android.yml
vendored
2
.github/workflows/android.yml
vendored
@ -26,7 +26,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Build APK without runtime
|
- name: Build APK without runtime
|
||||||
run: |
|
run: |
|
||||||
rm app/src/main/assets/components/jre/*.tar.xz
|
rm -r app/src/main/assets/components/jre
|
||||||
./gradlew assembleDebug
|
./gradlew assembleDebug
|
||||||
mv app/build/outputs/apk/debug/app-debug.apk out/app-debug-noruntime.apk
|
mv app/build/outputs/apk/debug/app-debug.apk out/app-debug-noruntime.apk
|
||||||
|
|
||||||
|
@ -306,12 +306,12 @@ public class PojavLoginActivity extends BaseActivity
|
|||||||
}
|
}
|
||||||
|
|
||||||
private boolean isJavaRuntimeInstalled(AssetManager am) {
|
private boolean isJavaRuntimeInstalled(AssetManager am) {
|
||||||
|
boolean prefValue = firstLaunchPrefs.getBoolean(PREF_IS_INSTALLED_JAVARUNTIME, false);
|
||||||
try {
|
try {
|
||||||
|
return prefValue && Tools.read(new FileInputStream(Tools.homeJreDir+"/version")).equals(Tools.read(am.open("components/jre/version")));
|
||||||
return firstLaunchPrefs.getBoolean(PREF_IS_INSTALLED_JAVARUNTIME, false) && Tools.read(new FileInputStream(Tools.homeJreDir+"/version")).equals(Tools.read(am.open("components/jre/version")));
|
} catch(IOException e) {
|
||||||
}catch(IOException e) {
|
|
||||||
Log.e("JVMCtl","failed to read file",e);
|
Log.e("JVMCtl","failed to read file",e);
|
||||||
return firstLaunchPrefs.getBoolean(PREF_IS_INSTALLED_JAVARUNTIME, false);
|
return prefValue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user