1331 if (JLI_StrCCmp(arg, "-Djava.class.path=") == 0) {
1332 _have_classpath = JNI_TRUE;
1333 } else if (JLI_StrCmp(arg, "-Djava.awt.headless=true") == 0) {
1334 /*
1335 * Checking for headless toolkit option in the same way as AWT does:
1336 * "true" means true and any other value means false
1337 */
1338 headless = true;
1339 } else if (JLI_StrCCmp(arg, "-Djava.awt.headless=") == 0) {
1340 headless = false;
1341 }
1342 AddOption(arg, NULL);
1343 }
1344
1345 /*
1346 * Check for CDS option
1347 */
1348 if (JLI_StrCmp(arg, "-Xshare:dump") == 0) {
1349 dumpSharedSpaces = JNI_TRUE;
1350 }
1351 }
1352
1353 if (*pwhat == NULL && --argc >= 0) {
1354 *pwhat = *argv++;
1355 }
1356
1357 if (*pwhat == NULL) {
1358 /* LM_UNKNOWN okay for options that exit */
1359 if (!listModules && !describeModule && !validateModules && !dumpSharedSpaces) {
1360 *pret = 1;
1361 printUsageKind = HELP_CONCISE;
1362 }
1363 } else if (mode == LM_UNKNOWN) {
1364 if (!_have_classpath) {
1365 SetClassPath(".");
1366 }
1367 /* If neither of -m, -jar, --source option is set, then the
1368 * launcher mode is LM_UNKNOWN. In such cases, we determine the
1369 * mode as LM_CLASS or LM_SOURCE per the input file. */
1370 mode = IsSourceFile(arg) ? LM_SOURCE : LM_CLASS;
|
1331 if (JLI_StrCCmp(arg, "-Djava.class.path=") == 0) {
1332 _have_classpath = JNI_TRUE;
1333 } else if (JLI_StrCmp(arg, "-Djava.awt.headless=true") == 0) {
1334 /*
1335 * Checking for headless toolkit option in the same way as AWT does:
1336 * "true" means true and any other value means false
1337 */
1338 headless = true;
1339 } else if (JLI_StrCCmp(arg, "-Djava.awt.headless=") == 0) {
1340 headless = false;
1341 }
1342 AddOption(arg, NULL);
1343 }
1344
1345 /*
1346 * Check for CDS option
1347 */
1348 if (JLI_StrCmp(arg, "-Xshare:dump") == 0) {
1349 dumpSharedSpaces = JNI_TRUE;
1350 }
1351 if (JLI_StrCmp(arg, "-XX:AOTMode=create") == 0) {
1352 // Alias for -Xshare:dump
1353 dumpSharedSpaces = JNI_TRUE;
1354 }
1355 }
1356
1357 if (*pwhat == NULL && --argc >= 0) {
1358 *pwhat = *argv++;
1359 }
1360
1361 if (*pwhat == NULL) {
1362 /* LM_UNKNOWN okay for options that exit */
1363 if (!listModules && !describeModule && !validateModules && !dumpSharedSpaces) {
1364 *pret = 1;
1365 printUsageKind = HELP_CONCISE;
1366 }
1367 } else if (mode == LM_UNKNOWN) {
1368 if (!_have_classpath) {
1369 SetClassPath(".");
1370 }
1371 /* If neither of -m, -jar, --source option is set, then the
1372 * launcher mode is LM_UNKNOWN. In such cases, we determine the
1373 * mode as LM_CLASS or LM_SOURCE per the input file. */
1374 mode = IsSourceFile(arg) ? LM_SOURCE : LM_CLASS;
|