├── .classpath
├── .gitignore
├── .project
├── .settings
├── org.eclipse.core.resources.prefs
├── org.eclipse.core.runtime.prefs
├── org.eclipse.jdt.core.prefs
└── org.eclipse.m2e.core.prefs
├── .vscode
├── c_cpp_properties.json
└── tasks.json
├── LICENSE.txt
├── bin
├── .gitignore
├── COPYING
├── bin-linux
│ ├── COPYING
│ ├── ld
│ └── windres
├── bin-linux64
│ ├── COPYING
│ ├── ld
│ └── windres
├── bin-macosx-x86
│ ├── COPYING
│ ├── ld
│ └── windres
└── bin-win32
│ ├── COPYING
│ ├── ld.exe
│ └── windres.exe
├── build-private.xml
├── build.xml
├── demo
├── ConsoleApp
│ ├── .gitignore
│ ├── build.bat
│ ├── build.xml
│ ├── l4j
│ │ └── ConsoleApp.ico
│ ├── lib
│ │ └── readme.txt
│ ├── readme.txt
│ └── src
│ │ └── net
│ │ └── sf
│ │ └── launch4j
│ │ └── example
│ │ └── ConsoleApp.java
├── ExitCodeApp
│ ├── .gitignore
│ ├── build.bat
│ ├── pom.xml
│ └── src
│ │ └── net
│ │ └── sf
│ │ └── launch4j
│ │ └── example
│ │ └── ExitCodeApp.java
├── LICENSE.txt
├── ModuleApp
│ ├── build.bat
│ ├── clean.bat
│ ├── run.bat
│ └── src
│ │ └── net.sf.launch4j.example
│ │ ├── module-info.java
│ │ └── net
│ │ └── sf
│ │ └── launch4j
│ │ └── example
│ │ └── ModuleApp.java
├── SimpleApp
│ ├── .gitignore
│ ├── build.bat
│ ├── build.xml
│ ├── l4j
│ │ ├── SimpleApp.ico
│ │ ├── SimpleApp.xml
│ │ └── splash.bmp
│ ├── lib
│ │ └── readme.txt
│ ├── readme.txt
│ └── src
│ │ └── net
│ │ └── sf
│ │ └── launch4j
│ │ └── example
│ │ └── SimpleApp.java
└── readme.txt
├── head
├── LICENSE.txt
├── consolehead.o
├── guihead.o
└── head.o
├── head_jni_BETA
├── LICENSE.txt
├── head.o
├── jniconsolehead.o
├── jniguihead.o
└── jnihead.o
├── head_src
├── LICENSE.txt
├── consolehead
│ ├── .gitignore
│ ├── Makefile.win
│ ├── consolehead.c
│ └── consolehead.dev
├── guihead
│ ├── .gitignore
│ ├── Makefile.win
│ ├── guihead.c
│ ├── guihead.dev
│ └── guihead.h
├── head.c
├── head.h
├── jniconsolehead_BETA
│ ├── .gitignore
│ ├── Makefile.win
│ ├── jniconsolehead.c
│ └── jniconsolehead.dev
├── jniguihead_BETA
│ ├── .gitignore
│ ├── Makefile.win
│ ├── jniguihead.c
│ ├── jniguihead.dev
│ └── jniguihead.h
├── jnihead.c
├── jnihead.h
├── makefile
└── resource.h
├── l4j
├── checkVersions.bat
├── launch4j-use.odg
├── launch4j.xml
├── launch4jc.xml
├── nsis
│ ├── launch4j-setup-license.txt
│ └── launch4j.nsi
└── web
│ ├── bullet.gif
│ ├── changelog.html
│ ├── docs.html
│ ├── footer.html
│ ├── header.html
│ ├── index.html
│ ├── launch4j-use.gif
│ ├── launch4j.gif
│ ├── links.html
│ └── style-13112022.css
├── launch4j
├── launch4j.jfpr
├── launch4jc
├── lib
├── JGoodies.Forms.LICENSE.txt
├── Nuvola.Icon.Theme.LICENSE.txt
├── XStream.LICENSE.txt
├── ant.LICENSE.txt
├── ant.jar
├── commons-beanutils.jar
├── commons-logging.jar
├── commons.LICENSE.txt
├── flatlaf.LICENSE.txt
├── flatlaf.jar
├── formsrt.jar
├── jgoodies-common.jar
├── jgoodies-forms.jar
└── xstream.jar
├── manifest
└── uac.exe.manifest
├── maven
├── .classpath
├── .project
├── .settings
│ └── org.eclipse.m2e.core.prefs
├── assembly
│ ├── assemble-dist.xml
│ ├── assemble-linux.xml
│ ├── assemble-linux64.xml
│ ├── assemble-mac.xml
│ ├── assemble-win32.xml
│ └── src.xml
├── maven-readme.txt
└── pom.xml
├── sign4j
├── Bouncy Castle.LICENSE.txt
├── create-key.bat
├── jsign-2.0.LICENSE.txt
├── jsign-2.0.jar
├── sign.bat
├── sign4j.README.txt
├── sign4j.c
└── sign4j.exe
├── src
├── LICENSE.txt
├── images
│ ├── asterix-o.gif
│ ├── asterix.gif
│ ├── build.png
│ ├── button_ok.png
│ ├── cancel16.png
│ ├── down16.png
│ ├── edit_add16.png
│ ├── info.png
│ ├── new.png
│ ├── new16.png
│ ├── ok16.png
│ ├── open.png
│ ├── open16.png
│ ├── run.png
│ ├── save.png
│ └── up16.png
├── launch4j.properties
└── net
│ └── sf
│ └── launch4j
│ ├── Builder.java
│ ├── BuilderException.java
│ ├── ExecException.java
│ ├── FileChooserFilter.java
│ ├── KanjiEscapeOutputStream.java
│ ├── Log.java
│ ├── Main.java
│ ├── Messages.java
│ ├── RcBuilder.java
│ ├── Util.java
│ ├── ant
│ ├── AntClassPath.java
│ ├── AntConfig.java
│ ├── AntJre.java
│ ├── Launch4jTask.java
│ ├── Messages.java
│ ├── StringWrapper.java
│ └── messages.properties
│ ├── binding
│ ├── Binding.java
│ ├── BindingException.java
│ ├── Bindings.java
│ ├── IValidatable.java
│ ├── InvariantViolationException.java
│ ├── JComboBoxBinding.java
│ ├── JListBinding.java
│ ├── JRadioButtonBinding.java
│ ├── JTextAreaBinding.java
│ ├── JTextComponentBinding.java
│ ├── JToggleButtonBinding.java
│ ├── Messages.java
│ ├── OptComponentBinding.java
│ ├── OptJTextAreaBinding.java
│ ├── Validator.java
│ └── messages.properties
│ ├── config
│ ├── CharsetID.java
│ ├── ClassPath.java
│ ├── Config.java
│ ├── ConfigPersister.java
│ ├── ConfigPersisterException.java
│ ├── Describable.java
│ ├── Jre.java
│ ├── JreVersion.java
│ ├── LanguageID.java
│ ├── LdDefaults.java
│ ├── Messages.java
│ ├── Msg.java
│ ├── SingleInstance.java
│ ├── Splash.java
│ ├── VersionInfo.java
│ └── messages.properties
│ ├── form
│ ├── BasicForm.java
│ ├── BasicForm.jfrm
│ ├── ClassPathForm.java
│ ├── ClassPathForm.jfrm
│ ├── ConfigForm.java
│ ├── ConfigForm.jfrm
│ ├── EnvironmentVarsForm.java
│ ├── EnvironmentVarsForm.jfrm
│ ├── HeaderForm.java
│ ├── HeaderForm.jfrm
│ ├── JreForm.java
│ ├── JreForm.jfrm
│ ├── Messages.java
│ ├── MessagesForm.java
│ ├── MessagesForm.jfrm
│ ├── SingleInstanceForm.java
│ ├── SingleInstanceForm.jfrm
│ ├── SplashForm.java
│ ├── SplashForm.jfrm
│ ├── VersionInfoForm.java
│ ├── VersionInfoForm.jfrm
│ └── messages.properties
│ ├── formimpl
│ ├── AbstractAcceptListener.java
│ ├── BasicFormImpl.java
│ ├── BrowseActionListener.java
│ ├── ClassPathFormImpl.java
│ ├── ConfigFormImpl.java
│ ├── EnvironmentVarsFormImpl.java
│ ├── FileChooser.java
│ ├── GlassPane.java
│ ├── HeaderFormImpl.java
│ ├── JreFormImpl.java
│ ├── MainFrame.java
│ ├── Messages.java
│ ├── MessagesFormImpl.java
│ ├── SingleInstanceFormImpl.java
│ ├── SplashFormImpl.java
│ ├── VersionInfoFormImpl.java
│ └── messages.properties
│ └── messages.properties
├── w32api
├── MinGW.LICENSE.txt
├── crt2.o
├── libadvapi32.a
├── libgcc.a
├── libkernel32.a
├── libmingw32.a
├── libmingwex.a
├── libmoldname.a
├── libmsvcrt.a
├── libshell32.a
└── libuser32.a
└── web
└── .gitignore
/.classpath:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 | /target
3 | demo/ModuleApp/mlib
4 | demo/ModuleApp/mods
5 | demo/ModuleApp/ModuleApp
6 |
--------------------------------------------------------------------------------
/.project:
--------------------------------------------------------------------------------
1 |
2 |
3 | launch4j
4 |
5 |
6 |
7 |
8 |
9 | org.eclipse.jdt.core.javabuilder
10 |
11 |
12 |
13 |
14 |
15 | org.eclipse.jdt.core.javanature
16 |
17 |
18 |
--------------------------------------------------------------------------------
/.settings/org.eclipse.core.resources.prefs:
--------------------------------------------------------------------------------
1 | eclipse.preferences.version=1
2 | encoding/=UTF-8
3 |
--------------------------------------------------------------------------------
/.settings/org.eclipse.core.runtime.prefs:
--------------------------------------------------------------------------------
1 | eclipse.preferences.version=1
2 | line.separator=\n
3 |
--------------------------------------------------------------------------------
/.settings/org.eclipse.m2e.core.prefs:
--------------------------------------------------------------------------------
1 | activeProfiles=
2 | eclipse.preferences.version=1
3 | resolveWorkspaceProjects=true
4 | version=1
5 |
--------------------------------------------------------------------------------
/.vscode/c_cpp_properties.json:
--------------------------------------------------------------------------------
1 | {
2 | "configurations": [
3 | {
4 | "name": "Win32",
5 | "includePath": [
6 | "${workspaceFolder}/**",
7 | "c:\\Program Files (x86)\\Dev-Cpp\\MinGW32\\include\\**"
8 | ],
9 | "defines": [
10 | "_DEBUG",
11 | "UNICODE",
12 | "_UNICODE"
13 | ],
14 | "cStandard": "gnu89",
15 | "cppStandard": "gnu++98",
16 | "intelliSenseMode": "windows-gcc-x86",
17 | "compilerPath": "c:\\Program Files (x86)\\Dev-Cpp\\MinGW32\\bin\\gcc.exe"
18 | }
19 | ],
20 | "version": 4
21 | }
--------------------------------------------------------------------------------
/.vscode/tasks.json:
--------------------------------------------------------------------------------
1 | {
2 | "version": "2.0.0",
3 | "tasks": [
4 | {
5 | "type": "make",
6 | "targetName": "all",
7 | "makeFileRelativePath": "head_src\\makefile",
8 | "problemMatcher": [],
9 | "label": "make: all",
10 | "detail": "./head_src\\makefile",
11 | "group": {
12 | "kind": "build",
13 | "isDefault": true
14 | }
15 | }
16 | ]
17 | }
--------------------------------------------------------------------------------
/LICENSE.txt:
--------------------------------------------------------------------------------
1 | Launch4j (http://launch4j.sourceforge.net/)
2 | Cross-platform Java application wrapper for creating Windows native executables.
3 |
4 | Copyright (c) 2004, 2021 Grzegorz Kowal
5 | All rights reserved.
6 |
7 | Redistribution and use in source and binary forms, with or without modification,
8 | are permitted provided that the following conditions are met:
9 |
10 | 1. Redistributions of source code must retain the above copyright notice,
11 | this list of conditions and the following disclaimer.
12 |
13 | 2. Redistributions in binary form must reproduce the above copyright notice,
14 | this list of conditions and the following disclaimer in the documentation
15 | and/or other materials provided with the distribution.
16 |
17 | 3. Neither the name of the copyright holder nor the names of its contributors
18 | may be used to endorse or promote products derived from this software without
19 | specific prior written permission.
20 |
21 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
22 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
23 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
25 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
26 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
27 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
28 | AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
29 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
--------------------------------------------------------------------------------
/bin/.gitignore:
--------------------------------------------------------------------------------
1 | /ld.exe
2 | /windres.exe
3 |
--------------------------------------------------------------------------------
/bin/bin-linux/ld:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/bin/bin-linux/ld
--------------------------------------------------------------------------------
/bin/bin-linux/windres:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/bin/bin-linux/windres
--------------------------------------------------------------------------------
/bin/bin-linux64/ld:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/bin/bin-linux64/ld
--------------------------------------------------------------------------------
/bin/bin-linux64/windres:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/bin/bin-linux64/windres
--------------------------------------------------------------------------------
/bin/bin-macosx-x86/ld:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/bin/bin-macosx-x86/ld
--------------------------------------------------------------------------------
/bin/bin-macosx-x86/windres:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/bin/bin-macosx-x86/windres
--------------------------------------------------------------------------------
/bin/bin-win32/ld.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/bin/bin-win32/ld.exe
--------------------------------------------------------------------------------
/bin/bin-win32/windres.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/bin/bin-win32/windres.exe
--------------------------------------------------------------------------------
/build.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
--------------------------------------------------------------------------------
/demo/ConsoleApp/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/demo/ConsoleApp/build.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 | if "%ANT_HOME%"=="" goto noAntHome
3 | if "%JAVA_HOME%"=="" goto noJavaHome
4 | call "%ANT_HOME%\bin\ant.bat" exe
5 | goto end
6 |
7 | :noAntHome
8 | echo ANT_HOME environment variable is not set
9 | goto end
10 |
11 | :noJavaHome
12 | echo JAVA_HOME environment variable is not set
13 |
14 | :end
15 |
--------------------------------------------------------------------------------
/demo/ConsoleApp/build.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
--------------------------------------------------------------------------------
/demo/ConsoleApp/l4j/ConsoleApp.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/demo/ConsoleApp/l4j/ConsoleApp.ico
--------------------------------------------------------------------------------
/demo/ConsoleApp/lib/readme.txt:
--------------------------------------------------------------------------------
1 | Put your jar libs here and the build script will include them
2 | in the classpath stored inside the jar manifest.
3 | In order to run your application move the output exe file from
4 | the dist directory to the same level as lib.
5 |
6 | SimpleApp.exe
7 | lib/
8 | lib/xml.jar
9 |
--------------------------------------------------------------------------------
/demo/ConsoleApp/readme.txt:
--------------------------------------------------------------------------------
1 | To build the example application set JAVA_HOME and ANT_HOME environment variables.
2 |
--------------------------------------------------------------------------------
/demo/ConsoleApp/src/net/sf/launch4j/example/ConsoleApp.java:
--------------------------------------------------------------------------------
1 | /*
2 | Launch4j (http://launch4j.sourceforge.net/)
3 | Cross-platform Java application wrapper for creating Windows native executables.
4 |
5 | Copyright (c) 2004, 2015 Grzegorz Kowal
6 | All rights reserved.
7 |
8 | Redistribution and use in source and binary forms, with or without modification,
9 | are permitted provided that the following conditions are met:
10 |
11 | 1. Redistributions of source code must retain the above copyright notice,
12 | this list of conditions and the following disclaimer.
13 |
14 | 2. Redistributions in binary form must reproduce the above copyright notice,
15 | this list of conditions and the following disclaimer in the documentation
16 | and/or other materials provided with the distribution.
17 |
18 | 3. Neither the name of the copyright holder nor the names of its contributors
19 | may be used to endorse or promote products derived from this software without
20 | specific prior written permission.
21 |
22 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
23 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
24 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
25 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
26 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
27 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
28 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
29 | AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
30 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 |
34 | package net.sf.launch4j.example;
35 |
36 | import java.io.BufferedReader;
37 | import java.io.IOException;
38 | import java.io.InputStreamReader;
39 |
40 | /**
41 | * @author Copyright (C) 2005 Grzegorz Kowal
42 | */
43 | public class ConsoleApp {
44 | public static void main(String[] args) {
45 | StringBuffer sb = new StringBuffer("Hello World!\n\nJava version: ");
46 | sb.append(System.getProperty("java.version"));
47 | sb.append("\nJava home: ");
48 | sb.append(System.getProperty("java.home"));
49 | sb.append("\nCurrent dir: ");
50 | sb.append(System.getProperty("user.dir"));
51 | if (args.length > 0) {
52 | sb.append("\nArgs: ");
53 | for (int i = 0; i < args.length; i++) {
54 | sb.append(args[i]);
55 | sb.append(' ');
56 | }
57 | }
58 | sb.append("\n\nEnter a line of text, 'quit' or Ctrl-C to stop.\n\n>");
59 | System.out.print(sb.toString());
60 | try {
61 | BufferedReader is = new BufferedReader(new InputStreamReader(System.in));
62 | String line;
63 | while ((line = is.readLine()) != null && !line.equalsIgnoreCase("quit")) {
64 | System.out.print("You wrote: " + line + "\n\n>");
65 | }
66 | is.close();
67 | System.exit(123);
68 | } catch (IOException e) {
69 | System.err.print(e);
70 | }
71 | }
72 | }
73 |
--------------------------------------------------------------------------------
/demo/ExitCodeApp/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 | /target
3 |
--------------------------------------------------------------------------------
/demo/ExitCodeApp/build.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 | rem Wrap executable using the Maven plugin.
3 | call "c:\Program Files\apache-maven-3.2.5\bin\mvn.bat" clean package
4 |
--------------------------------------------------------------------------------
/demo/ExitCodeApp/pom.xml:
--------------------------------------------------------------------------------
1 |
3 | 4.0.0
4 | net.sf.launch4j.example
5 | ExitCodeApp
6 | 1.0
7 | ExitCodeApp
8 | jar
9 |
10 |
11 | UTF-8
12 |
13 |
14 |
15 | src
16 |
17 |
18 | src
19 |
20 | **/*.java
21 |
22 |
23 |
24 |
25 |
26 | maven-compiler-plugin
27 | 3.1
28 |
29 | 1.8
30 | 1.8
31 |
32 |
33 |
34 | com.akathist.maven.plugins.launch4j
35 | launch4j-maven-plugin
36 | 1.7.22
37 |
38 |
39 | l4j
40 | package
41 |
42 | launch4j
43 |
44 |
45 | console
46 | target/ExitCodeApp.exe
47 | target/ExitCodeApp-1.0.jar
48 | ExitCodeApp
49 |
50 | net.sf.launch4j.example.ExitCodeApp
51 | false
52 | anything
53 |
54 |
55 | %JAVA_HOME%;%PATH%
56 | 1.8.0
57 |
58 |
59 | 1.0.0.0
60 | 1.0
61 | Simple app for testing exit code.
62 | Copyright (C) 2022 GK
63 | 3.9.0.0
64 | 3.9
65 | ExitCodeApp
66 | ExitCodeApp
67 | ExitCodeApp.exe
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
--------------------------------------------------------------------------------
/demo/ExitCodeApp/src/net/sf/launch4j/example/ExitCodeApp.java:
--------------------------------------------------------------------------------
1 | /*
2 | Launch4j (http://launch4j.sourceforge.net/)
3 | Cross-platform Java application wrapper for creating Windows native executables.
4 |
5 | Copyright (c) 2004, 2015 Grzegorz Kowal
6 | All rights reserved.
7 |
8 | Redistribution and use in source and binary forms, with or without modification,
9 | are permitted provided that the following conditions are met:
10 |
11 | 1. Redistributions of source code must retain the above copyright notice,
12 | this list of conditions and the following disclaimer.
13 |
14 | 2. Redistributions in binary form must reproduce the above copyright notice,
15 | this list of conditions and the following disclaimer in the documentation
16 | and/or other materials provided with the distribution.
17 |
18 | 3. Neither the name of the copyright holder nor the names of its contributors
19 | may be used to endorse or promote products derived from this software without
20 | specific prior written permission.
21 |
22 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
23 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
24 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
25 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
26 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
27 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
28 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
29 | AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
30 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 |
34 | package net.sf.launch4j.example;
35 |
36 | public class ExitCodeApp {
37 | public static void main(String[] args) {
38 | int exitCode = 0;
39 |
40 | if (args.length > 0) {
41 | exitCode = Integer.parseInt(args[0]);
42 | }
43 |
44 | System.out.println("Exit code: " + String.valueOf(exitCode));
45 | System.exit(exitCode);
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/demo/LICENSE.txt:
--------------------------------------------------------------------------------
1 | Launch4j (http://launch4j.sourceforge.net/)
2 | Cross-platform Java application wrapper for creating Windows native executables.
3 |
4 | Copyright (c) 2004, 2015 Grzegorz Kowal
5 | All rights reserved.
6 |
7 | Redistribution and use in source and binary forms, with or without modification,
8 | are permitted provided that the following conditions are met:
9 |
10 | 1. Redistributions of source code must retain the above copyright notice,
11 | this list of conditions and the following disclaimer.
12 |
13 | 2. Redistributions in binary form must reproduce the above copyright notice,
14 | this list of conditions and the following disclaimer in the documentation
15 | and/or other materials provided with the distribution.
16 |
17 | 3. Neither the name of the copyright holder nor the names of its contributors
18 | may be used to endorse or promote products derived from this software without
19 | specific prior written permission.
20 |
21 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
22 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
23 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
25 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
26 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
27 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
28 | AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
29 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 |
--------------------------------------------------------------------------------
/demo/ModuleApp/build.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 | rem Requires Java 11 or higher.
3 |
4 | call clean.bat
5 | echo building...
6 | if not exist "mlib" mkdir mlib
7 | javac -d mods\net.sf.launch4j.example src\net.sf.launch4j.example\module-info.java src\net.sf.launch4j.example\net\sf\launch4j\example\ModuleApp.java
8 | jar --create --file=mlib\net.sf.launch4j.example.jar --main-class=net.sf.launch4j.example.ModuleApp -C mods\net.sf.launch4j.example .
9 | jlink --module-path mlib --add-modules java.base,net.sf.launch4j.example --output ModuleApp
10 | echo done.
11 |
--------------------------------------------------------------------------------
/demo/ModuleApp/clean.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 | if exist "mods" rmdir /q /s mods
3 | if exist "mlib" rmdir /q /s mlib
4 | if exist "ModuleApp" rmdir /q /s ModuleApp
5 | echo cleaned.
6 |
--------------------------------------------------------------------------------
/demo/ModuleApp/run.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 | .\ModuleApp\bin\java -m net.sf.launch4j.example
3 |
--------------------------------------------------------------------------------
/demo/ModuleApp/src/net.sf.launch4j.example/module-info.java:
--------------------------------------------------------------------------------
1 | module net.sf.launch4j.example { }
2 |
--------------------------------------------------------------------------------
/demo/ModuleApp/src/net.sf.launch4j.example/net/sf/launch4j/example/ModuleApp.java:
--------------------------------------------------------------------------------
1 | /*
2 | Launch4j (http://launch4j.sourceforge.net/)
3 | Cross-platform Java application wrapper for creating Windows native executables.
4 |
5 | Copyright (c) 2022 Grzegorz Kowal
6 | All rights reserved.
7 |
8 | Redistribution and use in source and binary forms, with or without modification,
9 | are permitted provided that the following conditions are met:
10 |
11 | 1. Redistributions of source code must retain the above copyright notice,
12 | this list of conditions and the following disclaimer.
13 |
14 | 2. Redistributions in binary form must reproduce the above copyright notice,
15 | this list of conditions and the following disclaimer in the documentation
16 | and/or other materials provided with the distribution.
17 |
18 | 3. Neither the name of the copyright holder nor the names of its contributors
19 | may be used to endorse or promote products derived from this software without
20 | specific prior written permission.
21 |
22 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
23 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
24 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
25 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
26 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
27 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
28 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
29 | AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
30 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 | */
33 |
34 | package net.sf.launch4j.example;
35 |
36 | import java.io.BufferedReader;
37 | import java.io.IOException;
38 | import java.io.InputStreamReader;
39 |
40 | /**
41 | * @author Copyright (C) 2022 Grzegorz Kowal
42 | */
43 | public class ModuleApp {
44 | public static void main(String[] args) {
45 | StringBuffer sb = new StringBuffer("Hello World!\n\nJava version: ");
46 | sb.append(System.getProperty("java.version"));
47 | sb.append("\nJava home: ");
48 | sb.append(System.getProperty("java.home"));
49 | sb.append("\nCurrent dir: ");
50 | sb.append(System.getProperty("user.dir"));
51 | if (args.length > 0) {
52 | sb.append("\nArgs: ");
53 | for (int i = 0; i < args.length; i++) {
54 | sb.append(args[i]);
55 | sb.append(' ');
56 | }
57 | }
58 | System.out.print(sb.toString());
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/demo/SimpleApp/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/demo/SimpleApp/build.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 | if "%ANT_HOME%"=="" goto noAntHome
3 | if "%JAVA_HOME%"=="" goto noJavaHome
4 | call "%ANT_HOME%\bin\ant.bat" exe
5 | goto end
6 |
7 | :noAntHome
8 | echo ANT_HOME environment variable is not set
9 | goto end
10 |
11 | :noJavaHome
12 | echo JAVA_HOME environment variable is not set
13 |
14 | :end
15 |
--------------------------------------------------------------------------------
/demo/SimpleApp/build.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
--------------------------------------------------------------------------------
/demo/SimpleApp/l4j/SimpleApp.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/demo/SimpleApp/l4j/SimpleApp.ico
--------------------------------------------------------------------------------
/demo/SimpleApp/l4j/SimpleApp.xml:
--------------------------------------------------------------------------------
1 |
2 | gui
3 | SimpleApp.jar
4 | true
5 | ../SimpleApp.exe
6 | SimpleApp
7 | .
8 | SimpleApp.ico
9 | true
10 |
11 | %JAVA_HOME%;%PATH%
12 | 1.8.0
13 |
14 |
15 | splash.bmp
16 | true
17 | 60
18 | true
19 |
20 |
--------------------------------------------------------------------------------
/demo/SimpleApp/l4j/splash.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/demo/SimpleApp/l4j/splash.bmp
--------------------------------------------------------------------------------
/demo/SimpleApp/lib/readme.txt:
--------------------------------------------------------------------------------
1 | Put your jar libs here and the build script will include them
2 | in the classpath stored inside the jar manifest.
3 | In order to run your application move the output exe file from
4 | the dist directory to the same level as lib.
5 |
6 | SimpleApp.exe
7 | lib/
8 | lib/xml.jar
9 |
--------------------------------------------------------------------------------
/demo/SimpleApp/readme.txt:
--------------------------------------------------------------------------------
1 | To build the example application set JAVA_HOME and ANT_HOME environment variables.
2 |
--------------------------------------------------------------------------------
/demo/readme.txt:
--------------------------------------------------------------------------------
1 | JRE/SDK 1.6.0 or higher must be installed on your system to run this demo.
2 |
3 | try running it with some command line arguments...
4 |
--------------------------------------------------------------------------------
/head/LICENSE.txt:
--------------------------------------------------------------------------------
1 | Launch4j (http://launch4j.sourceforge.net/)
2 | Cross-platform Java application wrapper for creating Windows native executables.
3 |
4 | Copyright (c) 2004, 2015 Grzegorz Kowal
5 |
6 | Permission is hereby granted, free of charge, to any person obtaining a copy
7 | of this software and associated documentation files (the "Software"), to deal
8 | in the Software without restriction, including without limitation the rights
9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10 | copies of the Software, and to permit persons to whom the Software is
11 | furnished to do so, subject to the following conditions:
12 |
13 | The above copyright notice and this permission notice shall be included in
14 | all copies or substantial portions of the Software.
15 |
16 | Except as contained in this notice, the name(s) of the above copyright holders
17 | shall not be used in advertising or otherwise to promote the sale, use or other
18 | dealings in this Software without prior written authorization.
19 |
20 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26 | THE SOFTWARE.
--------------------------------------------------------------------------------
/head/consolehead.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/head/consolehead.o
--------------------------------------------------------------------------------
/head/guihead.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/head/guihead.o
--------------------------------------------------------------------------------
/head/head.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/head/head.o
--------------------------------------------------------------------------------
/head_jni_BETA/LICENSE.txt:
--------------------------------------------------------------------------------
1 | Launch4j (http://launch4j.sourceforge.net/)
2 | Cross-platform Java application wrapper for creating Windows native executables.
3 |
4 | Copyright (c) 2004, 2015 Grzegorz Kowal
5 |
6 | Permission is hereby granted, free of charge, to any person obtaining a copy
7 | of this software and associated documentation files (the "Software"), to deal
8 | in the Software without restriction, including without limitation the rights
9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10 | copies of the Software, and to permit persons to whom the Software is
11 | furnished to do so, subject to the following conditions:
12 |
13 | The above copyright notice and this permission notice shall be included in
14 | all copies or substantial portions of the Software.
15 |
16 | Except as contained in this notice, the name(s) of the above copyright holders
17 | shall not be used in advertising or otherwise to promote the sale, use or other
18 | dealings in this Software without prior written authorization.
19 |
20 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26 | THE SOFTWARE.
--------------------------------------------------------------------------------
/head_jni_BETA/head.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/head_jni_BETA/head.o
--------------------------------------------------------------------------------
/head_jni_BETA/jniconsolehead.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/head_jni_BETA/jniconsolehead.o
--------------------------------------------------------------------------------
/head_jni_BETA/jniguihead.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/head_jni_BETA/jniguihead.o
--------------------------------------------------------------------------------
/head_jni_BETA/jnihead.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/head_jni_BETA/jnihead.o
--------------------------------------------------------------------------------
/head_src/LICENSE.txt:
--------------------------------------------------------------------------------
1 | Launch4j (http://launch4j.sourceforge.net/)
2 | Cross-platform Java application wrapper for creating Windows native executables.
3 |
4 | Copyright (c) 2004, 2015 Grzegorz Kowal
5 |
6 | Permission is hereby granted, free of charge, to any person obtaining a copy
7 | of this software and associated documentation files (the "Software"), to deal
8 | in the Software without restriction, including without limitation the rights
9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10 | copies of the Software, and to permit persons to whom the Software is
11 | furnished to do so, subject to the following conditions:
12 |
13 | The above copyright notice and this permission notice shall be included in
14 | all copies or substantial portions of the Software.
15 |
16 | Except as contained in this notice, the name(s) of the above copyright holders
17 | shall not be used in advertising or otherwise to promote the sale, use or other
18 | dealings in this Software without prior written authorization.
19 |
20 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26 | THE SOFTWARE.
27 |
--------------------------------------------------------------------------------
/head_src/consolehead/.gitignore:
--------------------------------------------------------------------------------
1 | /consolehead.exe
2 | /consolehead.layout
3 |
--------------------------------------------------------------------------------
/head_src/consolehead/Makefile.win:
--------------------------------------------------------------------------------
1 | # Project: consolehead
2 | # Makefile created by Dev-C++ 5.7.1
3 |
4 | CPP = g++.exe
5 | CC = gcc.exe
6 | WINDRES = windres.exe
7 | OBJ = ../../head/consolehead.o ../../head/head.o
8 | LINKOBJ = ../../head/consolehead.o ../../head/head.o
9 | LIBS = -L"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib" -L"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/lib" -static-libstdc++ -static-libgcc -n -s
10 | INCS = -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include"
11 | CXXINCS = -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include/c++"
12 | BIN = consolehead.exe
13 | CXXFLAGS = $(CXXINCS) -Os
14 | CFLAGS = $(INCS) -Os
15 | RM = rm.exe -f
16 |
17 | .PHONY: all all-before all-after clean clean-custom
18 |
19 | all: all-before $(BIN) all-after
20 |
21 | clean: clean-custom
22 | ${RM} $(OBJ) $(BIN)
23 |
24 | $(BIN): $(OBJ)
25 | $(CC) $(LINKOBJ) -o $(BIN) $(LIBS)
26 |
27 | ../../head/consolehead.o: consolehead.c
28 | $(CC) -c consolehead.c -o ../../head/consolehead.o $(CFLAGS)
29 |
30 | ../../head/head.o: ../head.c
31 | $(CC) -c ../head.c -o ../../head/head.o $(CFLAGS)
32 |
--------------------------------------------------------------------------------
/head_src/consolehead/consolehead.c:
--------------------------------------------------------------------------------
1 | /*
2 | Launch4j (http://launch4j.sourceforge.net/)
3 | Cross-platform Java application wrapper for creating Windows native executables.
4 |
5 | Copyright (c) 2004, 2007 Grzegorz Kowal
6 |
7 | Permission is hereby granted, free of charge, to any person obtaining a copy
8 | of this software and associated documentation files (the "Software"), to deal
9 | in the Software without restriction, including without limitation the rights
10 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11 | copies of the Software, and to permit persons to whom the Software is
12 | furnished to do so, subject to the following conditions:
13 |
14 | The above copyright notice and this permission notice shall be included in
15 | all copies or substantial portions of the Software.
16 |
17 | Except as contained in this notice, the name(s) of the above copyright holders
18 | shall not be used in advertising or otherwise to promote the sale, use or other
19 | dealings in this Software without prior written authorization.
20 |
21 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
26 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
27 | THE SOFTWARE.
28 | */
29 |
30 | #include "../resource.h"
31 | #include "../head.h"
32 |
33 | extern FILE* hLog;
34 |
35 | BOOL restartOnCrash = FALSE;
36 |
37 | int main(int argc, char* argv[])
38 | {
39 | setConsoleFlag();
40 | LPTSTR cmdLine = GetCommandLine();
41 |
42 | if (*cmdLine == '"')
43 | {
44 | if (*(cmdLine = strchr(cmdLine + 1, '"') + 1))
45 | {
46 | cmdLine++;
47 | }
48 | }
49 | else if ((cmdLine = strchr(cmdLine, ' ')) != NULL)
50 | {
51 | cmdLine++;
52 | }
53 | else
54 | {
55 | cmdLine = "";
56 | }
57 |
58 | int result = prepare(cmdLine, FALSE);
59 |
60 | if (result == ERROR_ALREADY_EXISTS)
61 | {
62 | char errMsg[BIG_STR] = {0};
63 | loadString(INSTANCE_ALREADY_EXISTS_MSG, errMsg);
64 | msgBox(errMsg);
65 | closeLogFile();
66 | return 2;
67 | }
68 |
69 | if (result != TRUE)
70 | {
71 | signalError();
72 | return 1;
73 | }
74 |
75 | restartOnCrash = loadBool(RESTART_ON_CRASH);
76 | DWORD dwExitCode;
77 |
78 | do
79 | {
80 | dwExitCode = 0;
81 |
82 | if (!execute(TRUE, &dwExitCode))
83 | {
84 | signalError();
85 | break;
86 | }
87 |
88 | if (restartOnCrash && dwExitCode != 0)
89 | {
90 | debug("Exit code:\t%d, restarting the application!\n", dwExitCode);
91 | }
92 | } while (restartOnCrash && dwExitCode != 0);
93 |
94 | debug("Exit code:\t%d\n", dwExitCode);
95 | closeLogFile();
96 | return (int) dwExitCode;
97 | }
98 |
--------------------------------------------------------------------------------
/head_src/consolehead/consolehead.dev:
--------------------------------------------------------------------------------
1 | [Project]
2 | FileName=consolehead.dev
3 | Name=consolehead
4 | UnitCount=4
5 | Type=1
6 | Ver=2
7 | ObjFiles=
8 | Includes=
9 | Libs=
10 | PrivateResource=
11 | ResourceIncludes=
12 | MakeIncludes=
13 | Compiler=
14 | CppCompiler=
15 | Linker=-n_@@_
16 | IsCpp=0
17 | Icon=
18 | ExeOutput=
19 | ObjectOutput=..\..\head
20 | OverrideOutput=0
21 | OverrideOutputName=consolehead.exe
22 | HostApplication=
23 | Folders=
24 | CommandLine=
25 | UseCustomMakefile=0
26 | CustomMakefile=Makefile.win
27 | IncludeVersionInfo=0
28 | SupportXPThemes=0
29 | CompilerSet=0
30 | CompilerSettings=000000d000000000000001000
31 | LogOutput=
32 | LogOutputEnabled=0
33 |
34 | [Unit1]
35 | FileName=consolehead.c
36 | CompileCpp=0
37 | Folder=consolehead
38 | Compile=1
39 | Link=1
40 | Priority=1000
41 | OverrideBuildCmd=0
42 | BuildCmd=
43 |
44 | [VersionInfo]
45 | Major=0
46 | Minor=1
47 | Release=1
48 | Build=1
49 | LanguageID=1033
50 | CharsetID=1252
51 | CompanyName=
52 | FileVersion=0.1.1.1
53 | FileDescription=Developed using the Dev-C++ IDE
54 | InternalName=
55 | LegalCopyright=
56 | LegalTrademarks=
57 | OriginalFilename=
58 | ProductName=
59 | ProductVersion=
60 | AutoIncBuildNr=0
61 | SyncProduct=0
62 |
63 | [Unit2]
64 | FileName=..\resource.h
65 | CompileCpp=0
66 | Folder=consolehead
67 | Compile=1
68 | Link=1
69 | Priority=1000
70 | OverrideBuildCmd=0
71 | BuildCmd=
72 |
73 | [Unit3]
74 | FileName=..\head.c
75 | CompileCpp=0
76 | Folder=consolehead
77 | Compile=1
78 | Link=1
79 | Priority=1000
80 | OverrideBuildCmd=0
81 | BuildCmd=
82 |
83 | [Unit4]
84 | FileName=..\head.h
85 | CompileCpp=0
86 | Folder=consolehead
87 | Compile=1
88 | Link=1
89 | Priority=1000
90 | OverrideBuildCmd=0
91 | BuildCmd=
92 |
93 | [Unit5]
94 | FileName=..\head.rc
95 | Folder=consolehead
96 | Compile=1
97 | Link=0
98 | Priority=1000
99 | OverrideBuildCmd=0
100 | BuildCmd=
101 |
102 | [Unit6]
103 | FileName=..\resid.h
104 | CompileCpp=0
105 | Folder=consolehead
106 | Compile=1
107 | Link=1
108 | Priority=1000
109 | OverrideBuildCmd=0
110 | BuildCmd=
111 |
112 |
--------------------------------------------------------------------------------
/head_src/guihead/.gitignore:
--------------------------------------------------------------------------------
1 | /guihead.exe
2 | /guihead.layout
3 |
--------------------------------------------------------------------------------
/head_src/guihead/Makefile.win:
--------------------------------------------------------------------------------
1 | # Project: guihead
2 | # Makefile created by Dev-C++ 5.7.1
3 |
4 | CPP = g++.exe
5 | CC = gcc.exe
6 | WINDRES = windres.exe
7 | OBJ = ../../head/guihead.o ../../head/head.o
8 | LINKOBJ = ../../head/guihead.o ../../head/head.o
9 | LIBS = -L"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib" -L"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/lib" -static-libstdc++ -static-libgcc -mwindows -n -s
10 | INCS = -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include"
11 | CXXINCS = -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include/c++"
12 | BIN = guihead.exe
13 | CXXFLAGS = $(CXXINCS) -Os
14 | CFLAGS = $(INCS) -Os
15 | RM = rm.exe -f
16 |
17 | .PHONY: all all-before all-after clean clean-custom
18 |
19 | all: all-before $(BIN) all-after
20 |
21 | clean: clean-custom
22 | ${RM} $(OBJ) $(BIN)
23 |
24 | $(BIN): $(OBJ)
25 | $(CC) $(LINKOBJ) -o $(BIN) $(LIBS)
26 |
27 | ../../head/guihead.o: guihead.c
28 | $(CC) -c guihead.c -o ../../head/guihead.o $(CFLAGS)
29 |
30 | ../../head/head.o: ../head.c
31 | $(CC) -c ../head.c -o ../../head/head.o $(CFLAGS)
32 |
--------------------------------------------------------------------------------
/head_src/guihead/guihead.dev:
--------------------------------------------------------------------------------
1 | [Project]
2 | FileName=guihead.dev
3 | Name=guihead
4 | UnitCount=5
5 | Type=0
6 | Ver=2
7 | ObjFiles=
8 | Includes=
9 | Libs=
10 | PrivateResource=
11 | ResourceIncludes=
12 | MakeIncludes=
13 | Compiler=
14 | CppCompiler=
15 | Linker=-n_@@_
16 | IsCpp=0
17 | Icon=
18 | ExeOutput=
19 | ObjectOutput=..\..\head
20 | OverrideOutput=0
21 | OverrideOutputName=guihead.exe
22 | HostApplication=
23 | Folders=
24 | CommandLine=
25 | UseCustomMakefile=0
26 | CustomMakefile=Makefile.win
27 | IncludeVersionInfo=0
28 | SupportXPThemes=0
29 | CompilerSet=0
30 | CompilerSettings=000000d000000000000001000
31 | LogOutput=
32 | LogOutputEnabled=0
33 |
34 | [Unit1]
35 | FileName=guihead.c
36 | CompileCpp=0
37 | Folder=guihead
38 | Compile=1
39 | Link=1
40 | Priority=1000
41 | OverrideBuildCmd=0
42 | BuildCmd=$(CC) -c guihead.c -o ../../head/guihead.o $(CFLAGS)
43 |
44 | [Unit2]
45 | FileName=guihead.h
46 | CompileCpp=0
47 | Folder=guihead
48 | Compile=1
49 | Link=1
50 | Priority=1000
51 | OverrideBuildCmd=0
52 | BuildCmd=
53 |
54 | [VersionInfo]
55 | Major=0
56 | Minor=1
57 | Release=1
58 | Build=1
59 | LanguageID=1033
60 | CharsetID=1252
61 | CompanyName=
62 | FileVersion=
63 | FileDescription=Developed using the Dev-C++ IDE
64 | InternalName=
65 | LegalCopyright=
66 | LegalTrademarks=
67 | OriginalFilename=
68 | ProductName=
69 | ProductVersion=
70 | AutoIncBuildNr=0
71 | SyncProduct=0
72 |
73 | [Unit4]
74 | FileName=..\head.h
75 | CompileCpp=0
76 | Folder=guihead
77 | Compile=1
78 | Link=1
79 | Priority=1000
80 | OverrideBuildCmd=0
81 | BuildCmd=
82 |
83 | [Unit6]
84 | FileName=..\resid.h
85 | CompileCpp=0
86 | Folder=guihead
87 | Compile=1
88 | Link=1
89 | Priority=1000
90 | OverrideBuildCmd=0
91 | BuildCmd=
92 |
93 | [Unit3]
94 | FileName=..\head.c
95 | CompileCpp=0
96 | Folder=guihead
97 | Compile=1
98 | Link=1
99 | Priority=1000
100 | OverrideBuildCmd=0
101 | BuildCmd=$(CC) -c head.c -o ../../head/head.o $(CFLAGS)
102 |
103 | [Unit5]
104 | FileName=..\resource.h
105 | CompileCpp=0
106 | Folder=guihead
107 | Compile=1
108 | Link=1
109 | Priority=1000
110 | OverrideBuildCmd=0
111 | BuildCmd=
112 |
113 |
--------------------------------------------------------------------------------
/head_src/guihead/guihead.h:
--------------------------------------------------------------------------------
1 | /*
2 | Launch4j (http://launch4j.sourceforge.net/)
3 | Cross-platform Java application wrapper for creating Windows native executables.
4 |
5 | Copyright (c) 2004, 2007 Grzegorz Kowal
6 |
7 | Permission is hereby granted, free of charge, to any person obtaining a copy
8 | of this software and associated documentation files (the "Software"), to deal
9 | in the Software without restriction, including without limitation the rights
10 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11 | copies of the Software, and to permit persons to whom the Software is
12 | furnished to do so, subject to the following conditions:
13 |
14 | The above copyright notice and this permission notice shall be included in
15 | all copies or substantial portions of the Software.
16 |
17 | Except as contained in this notice, the name(s) of the above copyright holders
18 | shall not be used in advertising or otherwise to promote the sale, use or other
19 | dealings in this Software without prior written authorization.
20 |
21 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
26 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
27 | THE SOFTWARE.
28 | */
29 |
30 | #define ID_TIMER 1
31 | #define DEFAULT_SPLASH_TIMEOUT 60 /* 60 seconds */
32 | #define MAX_SPLASH_TIMEOUT 60 * 15 /* 15 minutes */
33 | #define TIMER_PROC_INTERVAL 100 /* interval in ms between calls to EnumWindows */
34 |
35 | HWND getInstanceWindow();
36 |
37 | BOOL CALLBACK enumwndfn(HWND hwnd, LPARAM lParam);
38 |
39 | VOID CALLBACK TimerProc(
40 | HWND hwnd, // handle of window for timer messages
41 | UINT uMsg, // WM_TIMER message
42 | UINT idEvent, // timer identifier
43 | DWORD dwTime // current system time
44 | );
45 |
--------------------------------------------------------------------------------
/head_src/jniconsolehead_BETA/.gitignore:
--------------------------------------------------------------------------------
1 | /jniconsolehead.exe
2 | /jniconsolehead.layout
3 |
--------------------------------------------------------------------------------
/head_src/jniconsolehead_BETA/Makefile.win:
--------------------------------------------------------------------------------
1 | # Project: jniconsolehead
2 | # Makefile created by Dev-C++ 5.7.1
3 |
4 | CPP = g++.exe
5 | CC = gcc.exe
6 | WINDRES = windres.exe
7 | OBJ = ../../head_jni_BETA/jniconsolehead.o ../../head_jni_BETA/head.o ../../head_jni_BETA/jnihead.o
8 | LINKOBJ = ../../head_jni_BETA/jniconsolehead.o ../../head_jni_BETA/head.o ../../head_jni_BETA/jnihead.o
9 | LIBS = -L"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib" -L"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/lib" -static-libstdc++ -static-libgcc -n -s
10 | INCS = -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include" -I"c:/Program Files/AdoptOpenJDK/jdk-8.0.282.8-hotspot/include" -I"c:/Program Files/AdoptOpenJDK/jdk-8.0.282.8-hotspot/include/win32"
11 | CXXINCS = -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include/c++" -I"c:/Program Files/AdoptOpenJDK/jdk-8.0.282.8-hotspot/include" -I"c:/Program Files/AdoptOpenJDK/jdk-8.0.282.8-hotspot/include/win32"
12 | BIN = jniconsolehead.exe
13 | CXXFLAGS = $(CXXINCS) -Os
14 | CFLAGS = $(INCS) -Os
15 | RM = rm.exe -f
16 |
17 | .PHONY: all all-before all-after clean clean-custom
18 |
19 | all: all-before $(BIN) all-after
20 |
21 | clean: clean-custom
22 | ${RM} $(OBJ) $(BIN)
23 |
24 | $(BIN): $(OBJ)
25 | $(CC) $(LINKOBJ) -o $(BIN) $(LIBS)
26 |
27 | ../../head_jni_BETA/jniconsolehead.o: jniconsolehead.c
28 | $(CC) -c jniconsolehead.c -o ../../head_jni_BETA/jniconsolehead.o $(CFLAGS)
29 |
30 | ../../head_jni_BETA/head.o: ../head.c
31 | $(CC) -c ../head.c -o ../../head_jni_BETA/head.o $(CFLAGS)
32 |
33 | ../../head_jni_BETA/jnihead.o: ../jnihead.c
34 | $(CC) -c ../jnihead.c -o ../../head_jni_BETA/jnihead.o $(CFLAGS)
35 |
--------------------------------------------------------------------------------
/head_src/jniconsolehead_BETA/jniconsolehead.c:
--------------------------------------------------------------------------------
1 | /*
2 | Launch4j (http://launch4j.sourceforge.net/)
3 | Cross-platform Java application wrapper for creating Windows native executables.
4 |
5 | Copyright (c) 2004, 2007 Grzegorz Kowal
6 |
7 | Permission is hereby granted, free of charge, to any person obtaining a copy
8 | of this software and associated documentation files (the "Software"), to deal
9 | in the Software without restriction, including without limitation the rights
10 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11 | copies of the Software, and to permit persons to whom the Software is
12 | furnished to do so, subject to the following conditions:
13 |
14 | The above copyright notice and this permission notice shall be included in
15 | all copies or substantial portions of the Software.
16 |
17 | Except as contained in this notice, the name(s) of the above copyright holders
18 | shall not be used in advertising or otherwise to promote the sale, use or other
19 | dealings in this Software without prior written authorization.
20 |
21 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
26 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
27 | THE SOFTWARE.
28 | */
29 |
30 | #include "../resource.h"
31 | #include "../head.h"
32 | #include "../jnihead.h"
33 |
34 | extern FILE* hLog;
35 |
36 | BOOL restartOnCrash = FALSE;
37 |
38 | int main(int argc, char* argv[])
39 | {
40 | setConsoleFlag();
41 | LPTSTR cmdLine = GetCommandLine();
42 |
43 | if (*cmdLine == '"')
44 | {
45 | if (*(cmdLine = strchr(cmdLine + 1, '"') + 1))
46 | {
47 | cmdLine++;
48 | }
49 | }
50 | else if ((cmdLine = strchr(cmdLine, ' ')) != NULL)
51 | {
52 | cmdLine++;
53 | }
54 | else
55 | {
56 | cmdLine = "";
57 | }
58 |
59 | int result = prepare(cmdLine, TRUE);
60 |
61 | if (result == ERROR_ALREADY_EXISTS)
62 | {
63 | char errMsg[BIG_STR] = {0};
64 | loadString(INSTANCE_ALREADY_EXISTS_MSG, errMsg);
65 | msgBox(errMsg);
66 | closeLogFile();
67 | return 2;
68 | }
69 |
70 | if (result != TRUE)
71 | {
72 | signalError();
73 | return 1;
74 | }
75 |
76 | restartOnCrash = loadBool(RESTART_ON_CRASH);
77 | DWORD dwExitCode;
78 |
79 | do
80 | {
81 | dwExitCode = 0;
82 | saveJvmOptions(getJavaHome(), getMainClass(), getLauncherArgs());
83 |
84 | if (!executeVm(&dwExitCode))
85 | {
86 | signalError();
87 | break;
88 | }
89 |
90 | if (restartOnCrash && dwExitCode != 0)
91 | {
92 | debug("Exit code:\t%d, restarting the application!\n", dwExitCode);
93 | }
94 | } while (restartOnCrash && dwExitCode != 0);
95 |
96 | debug("Exit code:\t%d\n", dwExitCode);
97 | closeLogFile();
98 | return (int) dwExitCode;
99 | }
100 |
--------------------------------------------------------------------------------
/head_src/jniconsolehead_BETA/jniconsolehead.dev:
--------------------------------------------------------------------------------
1 | [Project]
2 | FileName=jniconsolehead.dev
3 | Name=jniconsolehead
4 | UnitCount=6
5 | Type=1
6 | Ver=2
7 | ObjFiles=
8 | Includes="c:\Program Files\AdoptOpenJDK\jdk-8.0.282.8-hotspot\include";"c:\Program Files\AdoptOpenJDK\jdk-8.0.282.8-hotspot\include\win32"
9 | Libs=
10 | PrivateResource=
11 | ResourceIncludes=
12 | MakeIncludes=
13 | Compiler=
14 | CppCompiler=
15 | Linker=-n_@@_
16 | IsCpp=0
17 | Icon=
18 | ExeOutput=
19 | ObjectOutput=..\..\head_jni_BETA
20 | OverrideOutput=0
21 | OverrideOutputName=jniconsolehead.exe
22 | HostApplication=
23 | Folders=
24 | CommandLine=
25 | UseCustomMakefile=0
26 | CustomMakefile=Makefile.win
27 | IncludeVersionInfo=0
28 | SupportXPThemes=0
29 | CompilerSet=0
30 | CompilerSettings=000000d000000000000001000
31 | LogOutput=
32 | LogOutputEnabled=0
33 |
34 | [Unit1]
35 | FileName=jniconsolehead.c
36 | CompileCpp=0
37 | Folder=jniconsolehead
38 | Compile=1
39 | Link=1
40 | Priority=1000
41 | OverrideBuildCmd=0
42 | BuildCmd=
43 |
44 | [VersionInfo]
45 | Major=0
46 | Minor=1
47 | Release=1
48 | Build=1
49 | LanguageID=1033
50 | CharsetID=1252
51 | CompanyName=
52 | FileVersion=0.1.1.1
53 | FileDescription=Developed using the Dev-C++ IDE
54 | InternalName=
55 | LegalCopyright=
56 | LegalTrademarks=
57 | OriginalFilename=
58 | ProductName=
59 | ProductVersion=
60 | AutoIncBuildNr=0
61 | SyncProduct=0
62 |
63 | [Unit2]
64 | FileName=..\resource.h
65 | CompileCpp=0
66 | Folder=jniconsolehead
67 | Compile=1
68 | Link=1
69 | Priority=1000
70 | OverrideBuildCmd=0
71 | BuildCmd=
72 |
73 | [Unit3]
74 | FileName=..\head.c
75 | CompileCpp=0
76 | Folder=jniconsolehead
77 | Compile=1
78 | Link=1
79 | Priority=1000
80 | OverrideBuildCmd=0
81 | BuildCmd=
82 |
83 | [Unit4]
84 | FileName=..\head.h
85 | CompileCpp=0
86 | Folder=jniconsolehead
87 | Compile=1
88 | Link=1
89 | Priority=1000
90 | OverrideBuildCmd=0
91 | BuildCmd=
92 |
93 | [Unit5]
94 | FileName=..\jnihead.h
95 | Folder=jniconsolehead
96 | Compile=1
97 | Link=1
98 | Priority=1000
99 | OverrideBuildCmd=0
100 | BuildCmd=
101 | CompileCpp=0
102 |
103 | [Unit6]
104 | FileName=..\jnihead.c
105 | CompileCpp=0
106 | Folder=jniconsolehead
107 | Compile=1
108 | Link=1
109 | Priority=1000
110 | OverrideBuildCmd=0
111 | BuildCmd=
112 |
113 |
--------------------------------------------------------------------------------
/head_src/jniguihead_BETA/.gitignore:
--------------------------------------------------------------------------------
1 | /jniguihead.exe
2 | /jniguihead.layout
3 |
--------------------------------------------------------------------------------
/head_src/jniguihead_BETA/Makefile.win:
--------------------------------------------------------------------------------
1 | # Project: jniguihead
2 | # Makefile created by Dev-C++ 5.7.1
3 |
4 | CPP = g++.exe
5 | CC = gcc.exe
6 | WINDRES = windres.exe
7 | OBJ = ../../head_jni_BETA/jniguihead.o ../../head_jni_BETA/head.o ../../head_jni_BETA/jnihead.o
8 | LINKOBJ = ../../head_jni_BETA/jniguihead.o ../../head_jni_BETA/head.o ../../head_jni_BETA/jnihead.o
9 | LIBS = -L"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib" -L"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/lib" -static-libstdc++ -static-libgcc -mwindows -n -s
10 | INCS = -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include" -I"c:/Program Files/AdoptOpenJDK/jdk-8.0.282.8-hotspot/include" -I"c:/Program Files/AdoptOpenJDK/jdk-8.0.282.8-hotspot/include/win32"
11 | CXXINCS = -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/mingw32/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include" -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib/gcc/mingw32/4.8.1/include/c++" -I"c:/Program Files/AdoptOpenJDK/jdk-8.0.282.8-hotspot/include" -I"c:/Program Files/AdoptOpenJDK/jdk-8.0.282.8-hotspot/include/win32"
12 | BIN = jniguihead.exe
13 | CXXFLAGS = $(CXXINCS) -Os
14 | CFLAGS = $(INCS) -Os
15 | RM = rm.exe -f
16 |
17 | .PHONY: all all-before all-after clean clean-custom
18 |
19 | all: all-before $(BIN) all-after
20 |
21 | clean: clean-custom
22 | ${RM} $(OBJ) $(BIN)
23 |
24 | $(BIN): $(OBJ)
25 | $(CC) $(LINKOBJ) -o $(BIN) $(LIBS)
26 |
27 | ../../head_jni_BETA/jniguihead.o: jniguihead.c
28 | $(CC) -c jniguihead.c -o ../../head_jni_BETA/jniguihead.o $(CFLAGS)
29 |
30 | ../../head_jni_BETA/head.o: ../head.c
31 | $(CC) -c ../head.c -o ../../head_jni_BETA/head.o $(CFLAGS)
32 |
33 | ../../head_jni_BETA/jnihead.o: ../jnihead.c
34 | $(CC) -c ../jnihead.c -o ../../head_jni_BETA/jnihead.o $(CFLAGS)
35 |
--------------------------------------------------------------------------------
/head_src/jniguihead_BETA/jniguihead.dev:
--------------------------------------------------------------------------------
1 | [Project]
2 | FileName=jniguihead.dev
3 | Name=jniguihead
4 | UnitCount=7
5 | Type=0
6 | Ver=2
7 | ObjFiles=
8 | Includes="c:\Program Files\AdoptOpenJDK\jdk-8.0.282.8-hotspot\include";"c:\Program Files\AdoptOpenJDK\jdk-8.0.282.8-hotspot\include\win32"
9 | Libs=
10 | PrivateResource=
11 | ResourceIncludes=
12 | MakeIncludes=
13 | Compiler=
14 | CppCompiler=
15 | Linker=-n_@@_
16 | IsCpp=0
17 | Icon=
18 | ExeOutput=
19 | ObjectOutput=..\..\head_jni_BETA
20 | OverrideOutput=0
21 | OverrideOutputName=jniguihead.exe
22 | HostApplication=
23 | Folders=
24 | CommandLine=
25 | UseCustomMakefile=0
26 | CustomMakefile=Makefile.win
27 | IncludeVersionInfo=0
28 | SupportXPThemes=0
29 | CompilerSet=0
30 | CompilerSettings=000000d000000000000001000
31 | LogOutput=
32 | LogOutputEnabled=0
33 |
34 | [Unit1]
35 | FileName=jniguihead.c
36 | CompileCpp=0
37 | Folder=jniguihead_BETA
38 | Compile=1
39 | Link=1
40 | Priority=1000
41 | OverrideBuildCmd=0
42 | BuildCmd=$(CC) -c jniguihead.c -o ../../head_jni_BETA/jniguihead.o $(CFLAGS)
43 |
44 | [Unit2]
45 | FileName=jniguihead.h
46 | CompileCpp=0
47 | Folder=jniguihead_BETA
48 | Compile=1
49 | Link=1
50 | Priority=1000
51 | OverrideBuildCmd=0
52 | BuildCmd=
53 |
54 | [VersionInfo]
55 | Major=0
56 | Minor=1
57 | Release=1
58 | Build=1
59 | LanguageID=1033
60 | CharsetID=1252
61 | CompanyName=
62 | FileVersion=0.1.1.1
63 | FileDescription=Developed using the Dev-C++ IDE
64 | InternalName=
65 | LegalCopyright=
66 | LegalTrademarks=
67 | OriginalFilename=
68 | ProductName=
69 | ProductVersion=
70 | AutoIncBuildNr=0
71 | SyncProduct=0
72 |
73 | [Unit4]
74 | FileName=..\head.h
75 | CompileCpp=0
76 | Folder=jniguihead_BETA
77 | Compile=1
78 | Link=1
79 | Priority=1000
80 | OverrideBuildCmd=0
81 | BuildCmd=
82 |
83 | [Unit6]
84 | FileName=..\jnihead.c
85 | CompileCpp=0
86 | Folder=jniguihead_BETA
87 | Compile=1
88 | Link=1
89 | Priority=1000
90 | OverrideBuildCmd=0
91 | BuildCmd=
92 |
93 | [Unit3]
94 | FileName=..\head.c
95 | CompileCpp=0
96 | Folder=jniguihead_BETA
97 | Compile=1
98 | Link=1
99 | Priority=1000
100 | OverrideBuildCmd=0
101 | BuildCmd=$(CC) -c head.c -o ../../head/head.o $(CFLAGS)
102 |
103 | [Unit5]
104 | FileName=..\resource.h
105 | CompileCpp=0
106 | Folder=jniguihead_BETA
107 | Compile=1
108 | Link=1
109 | Priority=1000
110 | OverrideBuildCmd=0
111 | BuildCmd=
112 |
113 | [Unit7]
114 | FileName=..\jnihead.h
115 | CompileCpp=0
116 | Folder=jniguihead_BETA
117 | Compile=1
118 | Link=1
119 | Priority=1000
120 | OverrideBuildCmd=0
121 | BuildCmd=
122 |
123 |
--------------------------------------------------------------------------------
/head_src/jniguihead_BETA/jniguihead.h:
--------------------------------------------------------------------------------
1 | /*
2 | Launch4j (http://launch4j.sourceforge.net/)
3 | Cross-platform Java application wrapper for creating Windows native executables.
4 |
5 | Copyright (c) 2004, 2007 Grzegorz Kowal
6 |
7 | Permission is hereby granted, free of charge, to any person obtaining a copy
8 | of this software and associated documentation files (the "Software"), to deal
9 | in the Software without restriction, including without limitation the rights
10 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11 | copies of the Software, and to permit persons to whom the Software is
12 | furnished to do so, subject to the following conditions:
13 |
14 | The above copyright notice and this permission notice shall be included in
15 | all copies or substantial portions of the Software.
16 |
17 | Except as contained in this notice, the name(s) of the above copyright holders
18 | shall not be used in advertising or otherwise to promote the sale, use or other
19 | dealings in this Software without prior written authorization.
20 |
21 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
26 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
27 | THE SOFTWARE.
28 | */
29 |
30 | #define ID_TIMER 1
31 | #define DEFAULT_SPLASH_TIMEOUT 60 /* 60 seconds */
32 | #define MAX_SPLASH_TIMEOUT 60 * 15 /* 15 minutes */
33 |
34 | HWND getInstanceWindow();
35 |
36 | BOOL CALLBACK enumwndfn(HWND hwnd, LPARAM lParam);
37 |
38 | VOID CALLBACK TimerProc(
39 | HWND hwnd, // handle of window for timer messages
40 | UINT uMsg, // WM_TIMER message
41 | UINT idEvent, // timer identifier
42 | DWORD dwTime // current system time
43 | );
44 |
--------------------------------------------------------------------------------
/head_src/jnihead.h:
--------------------------------------------------------------------------------
1 | /*
2 | Launch4j (http://launch4j.sourceforge.net/)
3 | Cross-platform Java application wrapper for creating Windows native executables.
4 |
5 | Copyright (c) 2007 Ryan Rusaw
6 |
7 | Permission is hereby granted, free of charge, to any person obtaining a copy
8 | of this software and associated documentation files (the "Software"), to deal
9 | in the Software without restriction, including without limitation the rights
10 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11 | copies of the Software, and to permit persons to whom the Software is
12 | furnished to do so, subject to the following conditions:
13 |
14 | The above copyright notice and this permission notice shall be included in
15 | all copies or substantial portions of the Software.
16 |
17 | Except as contained in this notice, the name(s) of the above copyright holders
18 | shall not be used in advertising or otherwise to promote the sale, use or other
19 | dealings in this Software without prior written authorization.
20 |
21 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
26 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
27 | THE SOFTWARE.
28 | */
29 |
30 | #include
31 | #include
32 |
33 | #include "head.h"
34 |
35 | int getArgCount(const char* pcArgStr);
36 | void saveJvmOptions(const char *jrePath, const char *mainClass, const char *pcOpts);
37 | JNIEnv* createVm();
38 | int invokeMainClass(JNIEnv* psJNIEnv);
39 | void cleanupVm();
40 | BOOL executeVm(DWORD *dwExitCode);
41 |
42 |
--------------------------------------------------------------------------------
/head_src/makefile:
--------------------------------------------------------------------------------
1 | MAKE = mingw32-make.exe
2 |
3 | all:
4 | $(MAKE) -C guihead -f Makefile.win all
5 | $(MAKE) -C consolehead -f Makefile.win all
6 | $(MAKE) -C jniguihead_BETA -f Makefile.win all
7 | $(MAKE) -C jniconsolehead_BETA -f Makefile.win all
8 |
9 | clean:
10 | $(MAKE) -C guihead -f Makefile.win clean
11 | $(MAKE) -C consolehead -f Makefile.win clean
12 | $(MAKE) -C jniguihead_BETA -f Makefile.win clean
13 | $(MAKE) -C jniconsolehead_BETA -f Makefile.win clean
14 |
--------------------------------------------------------------------------------
/head_src/resource.h:
--------------------------------------------------------------------------------
1 | /*
2 | Launch4j (http://launch4j.sourceforge.net/)
3 | Cross-platform Java application wrapper for creating Windows native executables.
4 |
5 | Copyright (c) 2004, 2014 Grzegorz Kowal
6 | Ian Roberts (jdk preference patch)
7 |
8 | Permission is hereby granted, free of charge, to any person obtaining a copy
9 | of this software and associated documentation files (the "Software"), to deal
10 | in the Software without restriction, including without limitation the rights
11 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
12 | copies of the Software, and to permit persons to whom the Software is
13 | furnished to do so, subject to the following conditions:
14 |
15 | The above copyright notice and this permission notice shall be included in
16 | all copies or substantial portions of the Software.
17 |
18 | Except as contained in this notice, the name(s) of the above copyright holders
19 | shall not be used in advertising or otherwise to promote the sale, use or other
20 | dealings in this Software without prior written authorization.
21 |
22 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
25 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
26 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
27 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
28 | THE SOFTWARE.
29 | */
30 |
31 | // ICON
32 | #define APP_ICON 1
33 |
34 | // BITMAP
35 | #define SPLASH_BITMAP 1
36 |
37 | // RCDATA
38 | #define JRE_PATH 1
39 | #define JAVA_MIN_VER 2
40 | #define JAVA_MAX_VER 3
41 | #define SHOW_SPLASH 4
42 | #define SPLASH_WAITS_FOR_WINDOW 5
43 | #define SPLASH_TIMEOUT 6
44 | #define SPLASH_TIMEOUT_ERR 7
45 | #define CHDIR 8
46 | #define ERR_TITLE 10
47 | #define GUI_HEADER_STAYS_ALIVE 11
48 | #define JVM_OPTIONS 12
49 | #define CMD_LINE 13
50 | #define JAR 14
51 | #define MAIN_CLASS 15
52 | #define CLASSPATH 16
53 | #define WRAPPER 17
54 | #define REQUIRES_JDK 18
55 | #define ENV_VARIABLES 19
56 | #define PRIORITY_CLASS 20
57 | #define DOWNLOAD_URL 21
58 | #define SUPPORT_URL 22
59 | #define MUTEX_NAME 23
60 | #define INSTANCE_WINDOW_TITLE 24
61 | #define INITIAL_HEAP_SIZE 25
62 | #define INITIAL_HEAP_PERCENT 26
63 | #define MAX_HEAP_SIZE 27
64 | #define MAX_HEAP_PERCENT 28
65 | #define REQUIRES_64_BIT 29
66 | #define RESTART_ON_CRASH 31
67 | #define INI_FILE 33
68 |
69 | #define STARTUP_ERR 101
70 | #define JRE_NOT_FOUND_ERR 102
71 | #define JRE_VERSION_ERR 103
72 | #define LAUNCHER_ERR 104
73 | #define INSTANCE_ALREADY_EXISTS_MSG 105
74 |
--------------------------------------------------------------------------------
/l4j/checkVersions.bat:
--------------------------------------------------------------------------------
1 | @echo off
2 | type ..\src\launch4j.properties
3 | findstr /C:"#define VERSION" ..\head_src\head.h
4 | findstr /C:"!define PRODUCT_VERSION" nsis\launch4j.nsi
5 | findstr /C:"Copyright (c)" nsis\launch4j-setup-license.txt
6 | pause
7 |
--------------------------------------------------------------------------------
/l4j/launch4j-use.odg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/l4j/launch4j-use.odg
--------------------------------------------------------------------------------
/l4j/launch4j.xml:
--------------------------------------------------------------------------------
1 |
2 | gui
3 | true
4 | launch4j.jar
5 | ../launch4j.exe
6 | launch4j
7 | .
8 | false
9 |
10 | %JAVA_HOME%;%PATH%
11 | 1.8.0
12 |
13 |
14 | Cross-platform Java application wrapper
15 | Copyright (C) 2004, 2022 Grzegorz Kowal
16 | launch4j
17 | http://launch4j.sourceforge.net/
18 | GUI launcher
19 | launch4j.exe
20 |
21 |
--------------------------------------------------------------------------------
/l4j/launch4jc.xml:
--------------------------------------------------------------------------------
1 |
2 | console
3 | true
4 | launch4j.jar
5 | ../launch4jc.exe
6 | launch4j
7 | false
8 |
9 | %JAVA_HOME%;%PATH%
10 | 1.8.0
11 |
12 |
13 | Cross-platform Java application wrapper
14 | Copyright (C) 2004, 2022 Grzegorz Kowal
15 | launch4j
16 | http://launch4j.sourceforge.net/
17 | Console launcher
18 | launch4jc.exe
19 |
20 |
--------------------------------------------------------------------------------
/l4j/nsis/launch4j-setup-license.txt:
--------------------------------------------------------------------------------
1 | Launch4j :: Cross-platform Java application wrapper
2 | for creating Windows native executables
3 |
4 | Copyright (c) 2004, 2022 Grzegorz Kowal
5 | All rights reserved.
6 |
7 | Redistribution and use in source and binary forms, with or without modification,
8 | are permitted provided that the following conditions are met:
9 |
10 | 1. Redistributions of source code must retain the above copyright notice,
11 | this list of conditions and the following disclaimer.
12 |
13 | 2. Redistributions in binary form must reproduce the above copyright notice,
14 | this list of conditions and the following disclaimer in the documentation
15 | and/or other materials provided with the distribution.
16 |
17 | 3. Neither the name of the copyright holder nor the names of its contributors
18 | may be used to endorse or promote products derived from this software without
19 | specific prior written permission.
20 |
21 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
23 | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
24 | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
25 | HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
26 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
27 | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
28 | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
29 | THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 |
33 | This product includes software developed by the Apache Software Foundation (http://www.apache.org/).
34 |
--------------------------------------------------------------------------------
/l4j/web/bullet.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mirror/launch4j/c48081b48b4483663395e5736ed310904a611cc2/l4j/web/bullet.gif
--------------------------------------------------------------------------------
/l4j/web/footer.html:
--------------------------------------------------------------------------------
1 |
2 |
9 |
10 |