Build: Add non-pack200 release targets (ticket #2693)

Update: Don't require pack200 for in-net update (ticket #2693)
This commit is contained in:
zzz
2020-02-20 18:36:03 +00:00
parent 2524a7a69d
commit 4bcd896829
6 changed files with 42 additions and 9 deletions

View File

@ -240,12 +240,14 @@ class NewsFetcher extends UpdateRunner {
_mgr.notifyVersionConstraint(this, _currentURI, ROUTER_SIGNED, "", ver, msg);
return;
}
/*
if (!FileUtil.isPack200Supported()) {
String msg = _mgr._t("No Pack200 support in Java runtime.");
_log.logAlways(Log.WARN, "Cannot update to version " + ver + ": " + msg);
_mgr.notifyVersionConstraint(this, _currentURI, ROUTER_SIGNED, "", ver, msg);
return;
}
*/
if (!ConfigUpdateHandler.USE_SU3_UPDATE) {
String msg = _mgr._t("No update certificates installed.");
_log.logAlways(Log.WARN, "Cannot update to version " + ver + ": " + msg);

View File

@ -85,6 +85,8 @@ public class ConfigUpdateHandler extends FormHandler {
* Changed as of release 0.8 to support both .sud and .su2
* Some JVMs (IcedTea) don't have pack200
* Update hosts must maintain both
*
* These versions have not been released since 0.9.22, 2015.
*/
private static final String PACK200_URLS =
"http://echelon.i2p/i2p/i2pupdate.su2\r\n" +
@ -121,13 +123,13 @@ public class ConfigUpdateHandler extends FormHandler {
private static final String SU3_CERT_DIR = "certificates/router";
/**
* Only enabled if we have pack200 and trusted public key certificates installed
* Only enabled if we have trusted public key certificates installed
* @since 0.9.9
*/
public static final boolean USE_SU3_UPDATE;
static {
String[] files = (new File(I2PAppContext.getGlobalContext().getBaseDir(), SU3_CERT_DIR)).list();
USE_SU3_UPDATE = FileUtil.isPack200Supported() && files != null && files.length > 0;
USE_SU3_UPDATE = files != null && files.length > 0;
}
private static final String DEFAULT_SU3_UPDATE_URLS =

View File

@ -345,8 +345,9 @@ public class RouterConsoleRunner implements RouterApp {
/** @since 0.9.17 */
private void checkJavaVersion() {
boolean noJava8 = !SystemVersion.isJava8();
boolean noPack200 = (PluginStarter.pluginsEnabled(_context) || !NewsHelper.isUpdateDisabled(_context)) &&
!FileUtil.isPack200Supported();
//boolean noPack200 = (PluginStarter.pluginsEnabled(_context) || !NewsHelper.isUpdateDisabled(_context)) &&
// !FileUtil.isPack200Supported();
boolean noPack200 = false;
boolean openARM = SystemVersion.isARM() && SystemVersion.isOpenJDK() && !SystemVersion.isJava9();
boolean isZero = SystemVersion.isZeroVM();
boolean isJava11 = false; // SystemVersion.isJava11();