Skip to content

Commit a2167c2

Browse files
committed
accept runtime arguments
1 parent 8271ac1 commit a2167c2

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,3 +50,10 @@ You can customize the generated launcher by passing build options.
5050
| -DAPP_COPYRIGHT=\<copyright notice\> | application copyright notice |
5151
| -DAPP_PREDEF_OPTIONS=\<predef vm options\> | predefined VM options, separate multiple options with `;;;`. See [JNI_CreateJavaVM](https://docs.oracle.com/en/java/javase/11/docs/specs/jni/invocation.html#jni_createjavavm), *Standard Options* table |
5252

53+
## Runtime Options
54+
The launcher accepts arguments starting with `-J` and passes the rest of the content to JVM
55+
56+
Example:
57+
```
58+
.\ClassViewer.exe -J-Xms128m -J-Xmx128m
59+
```

launcher_win_main.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ int WINAPI wWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, PWSTR pCmdLine
4545
return EXIT_FAILURE;
4646
}
4747

48+
parseCMD();
4849
jobjectArray args = javaArguments();
4950
ex = (*env)->ExceptionOccurred(env);
5051
if (args == NULL) {

0 commit comments

Comments
 (0)