Giter Club home page Giter Club logo

gradle-launch4j's Introduction

Gradle Plugin Portal

Build status: Build status master Build status develop

Table of contents

Introduction

The gradle-launch4j plugin uses launch4j 3.50 to create windows .exe files for java applications. This plugin is compatible with the Gradle versions 4.10 and later. If you still rely on an outdated gradle version [2-4.10[, use the plugin version 2.5.4.

Since version 2.5 this plugin requires *Java 8, as launch4j in version 3.14 and later requires that as well. If you are still forced to work with Java 6, use the plugin version 2.4.9.

Tasks

There are 2 tasks:

  • createExe - Backward compatible task to generate an .exe file. Execute this task to generate an executable. With default settings this creates the executable under ${project.buildDir}/launch4j and puts all runtime libraries into the lib subfolder.
  • createAllExecutables - Helper task to run all tasks of the Launch4jExternalTask and Launch4jLibraryTask type.

Launch4j no longer needs to be installed separately, but if you want, you can still use it from the PATH. Since version 2.0 use the Launch4jExternalTask to create your executable.

Configuration

The configuration follows the structure of the launch4j xml file. The gradle-launch4j plugin tries to pick sensible defaults based on the project. The only required value is the mainClassName.

How to include

An example configuration within your build.gradle for use in all Gradle versions might look like:

plugins {
  id 'java'
  id 'edu.sc.seis.launch4j' version '3.0.6'
}

launch4j {
  mainClassName = 'com.example.myapp.Start'
  icon = "${projectDir}/icons/myApp.ico"
}

The same script snippet for using legacy plugin application:

buildscript {
  repositories {
    gradlePluginPortal()
  }
  dependencies {
    classpath 'edu.sc.seis.launch4j:launch4j:3.0.6'
  }
}

repositories {
  mavenCentral()
}

apply plugin: 'java'
apply plugin: 'edu.sc.seis.launch4j'

launch4j {
  mainClassName = 'com.example.myapp.Start'
  icon = "${projectDir}/icons/myApp.ico"
}

If no repository is configured before applying this plugin the Maven central repository will be added to the project.

See the Gradle User guide for more information on how to use a custom plugin and the plugin page for the above settings.

How to configure

The values configurable within the launch4j extension along with their defaults are:

Property Name Default Value Comment
String outputDir "launch4j" This is the plugin's working path relative to $buildDir. Use the distribution plugin or a custom implementation to copy necessary files to an output location instead of adjusting this property.
String libraryDir "lib" The library directory next to the created executable, where all dependencies, i.e. libraries, will be copied into.
Object copyConfigurable null User-defined set of files to copy tolibraryDir (if not set, the default copy logic is used)
Set<String> classpath [] User-defined classpath property (if not set, the default logic based on the set of files copied to libraryDir is used)
String xmlFileName "launch4j.xml"
String mainClassName
boolean dontWrapJar false
String headerType "gui"
Task jarTask tasks[jar], if the JavaPlugin is loaded The jar producing task. See here how to use this for the shadow plugin.
String outfile project.name+'.exe'
String errTitle ""
String cmdLine ""
String chdir '.' After launching, '.' changes working directory to directory of executable, or '' to not change. Note that env variable %OLDPWD% contains the original working directory and can be passed on launch to your application if needed.
String priority 'normal'
String downloadUrl "http://java.com/download"
String supportUrl ""
boolean stayAlive false
boolean restartOnCrash false
String manifest ""
String icon "" A relative path from the outfile or an absolute path to the icon file. If you are unsure, use "${projectDir}/path/to/icon.ico"
String version project.version
String textVersion project.version
String copyright "unknown"
String companyName ""
String fileDescription project.name
String productName project.name
String internalName project.name
String trademarks
String language "ENGLISH_US"
Set<String> jvmOptions [ ]
String bundledJrePath
boolean requires64Bit false
String jreMinVersion project.targetCompatibility or
the current java version,
if the property is not set
String jreMaxVersion
Set<String> variables [ ]
String mutexName
String windowTitle
String messagesStartupError
String messagesJreNotFoundError
String messagesJreVersionError
String messagesLauncherError
String messagesInstanceAlreadyExists
Integer initialHeapSize
Integer initialHeapPercent
Integer maxHeapSize
Integer maxHeapPercent
String splashFileName A relative path from the outfile or an absolute path to the bmp splash file.
boolean splashWaitForWindows true
Integer splashTimeout 60
boolean splashTimeoutError true
DuplicatesStrategy duplicatesStrategy DuplicatesStrategy.EXCLUDE The duplication strategy to use when duplicates are found. See also here.
Removed properties Default Value Description
boolean bundledJreAsFallback false
boolean bundledJre64Bit false use requires64Bit instead
jar "lib/"+project.tasks[jar].archiveName
or
"", if the JavaPlugin is not loaded
String jdkPreference "preferJre" use requiresJdk instead
String jreRuntimeBits "64/32" use requires64Bit instead
String messagesBundledJreError use messagesJreNotFoundError instead

Configurable input configuration

In order to configure the input of the copyL4jLib task set the copyConfigurable property. The following example shows how to use this plugin hand in hand with the shadow plugin:

launch4j {
    outfile = 'TestMain.exe'
    mainClassName = project.mainClassName
    copyConfigurable = []
    jarTask = project.tasks.shadowJar
}

If you use the outdated fatJar plugin the following configuration correctly wires the execution graph:

fatJar {
    classifier 'fat'
    with jar
    manifest {
        attributes 'Main-Class': project.mainClassName
    }
}

fatJarPrepareFiles.dependsOn jar

launch4j {
    outfile = 'TestMain.exe'
    mainClassName = project.mainClassName
    copyConfigurable = []
    jarTask = project.tasks.fatJar
}

Launch4jLibraryTask

This task type can be used to build multiple executables with Launch4j. The default launch4j configuration from how to configure is used for the default values but can be adjusted. To avoid replacing the resulting xml file or executable on each invocation, xmlFileName and outfile are set to the task name (name.xml and name.exe respectively).

Creating three executables is as easy as:

launch4j {
    outfile = 'MyApp.exe'
    mainClassName = 'com.example.myapp.Start'
    icon = "${projectDir}/icons/myApp.ico"
    productName = 'My App'
}

tasks.register('createFastStart', edu.sc.seis.launch4j.tasks.Launch4jLibraryTask) {
    outfile = 'FastMyApp.exe'
    mainClassName = 'com.example.myapp.FastStart'
    icon = "${projectDir}/icons/myAppFast.ico"
    fileDescription = 'The lightning fast implementation'
}

tasks.register('MyApp-memory', edu.sc.seis.launch4j.tasks.Launch4jLibraryTask) {
    fileDescription = 'The default implementation with increased heap size'
    maxHeapPercent = 50
}

Running the createAllExecutables task will create the following executables in the launch4j folder located in the buildDir:

  • MyApp.exe
  • FastMyApp.exe
  • MyApp-memory.exe

Launch4jExternalTask

The section from above applies to this task, too. This task type has the following additional property:

  • String launch4jCmd = "launch4j"

In order to use a launch4j instance named 'launch4j-test' located in the PATH create a task like the following:

launch4j {
    mainClassName = 'com.example.myapp.Start'
}

task createMyApp(type: edu.sc.seis.launch4j.tasks.Launch4jExternalTask) {
    launch4jCmd = 'launch4j-test'
    outfile = 'MyApp.exe'
}

Using another launch4j binary

To use a different launch4j binary instead of the default one, you can provide it as follows. Use your desired version instead of 3.50.

dependencies {
    launch4jBin 'net.sf.launch4j:launch4j:3.50:workdir-win32'
}

Kotlin

To get started using this plugin from a kotlin build script the above example from the section Launch4jLibraryTask would be written as:

tasks.withType<edu.sc.seis.launch4j.tasks.DefaultLaunch4jTask> {
    outfile.set("${appName}.exe")
    mainClassName.set(mainClass)
    icon.set("$projectDir/icons/myApp.ico")
    productName.set("My App")
}

tasks.register<edu.sc.seis.launch4j.tasks.Launch4jLibraryTask>("createFastStart") {
    outfile.set("FastMyApp.exe")
    mainClassName.set("com.example.myapp.FastStart")
    icon.set("$projectDir/icons/myAppFast.ico")
    fileDescription.set("The lightning fast implementation")
}
tasks.register<edu.sc.seis.launch4j.tasks.Launch4jLibraryTask>("MyApp-memory") {
    fileDescription.set("The default implementation with increased heap size")
    maxHeapPercent.set(50)
}

Debugging

To get insight into the launch4j creation process start a launch4j task, e.g. createExe, createExecutables or your custom task, with the script parameter -Pl4j-debug. This will copy the created xml into ${buildDir}/tmp/${task.name}.

In order to debug the created executable call it with the command line argument --l4j-debug. This will create the log file launch4j.log next to the executable.

Using SNAPSHOT versions

When you report a bug and it got fixed, you will have access to some -SNAPSHOT version. Adjust your buildscript to use the artifactory OSS repo:

buildscript {
  repositories {
    maven { url 'https://boegl.jfrog.io/artifactory/snapshots-gradle-dev-local/' }
  }
  dependencies {
    classpath 'edu.sc.seis.launch4j:launch4j:latest.integration'
  }
}

apply plugin: 'edu.sc.seis.launch4j'

Contributors

See contributors for a complete list.

Version

See VERSION.md for more information.

gradle-launch4j's People

Contributors

andretietz avatar crotwell avatar dependabot[bot] avatar evelak avatar ffourtytwo avatar itsnotoger avatar naftalmm avatar riggs333 avatar shadow-devil avatar sschuberth avatar streuspeicher avatar thc202 avatar theboegl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gradle-launch4j's Issues

Launch4j and Shadow plugins potentially don't play nice with each other

I have the following project which uses this plugin as well as the Shadow plugin.

The idea is simple:

  1. Let the Shadow plugin produce a self-contained "fat" jar of all my classes and their transitive dependencies; then
  2. Let this plugin wrap my shaded fat jar into an EXE

If you clone that project and run:

./gradlew clean build shadowJar createAllExecutables

You will get errors that I can't seem to fix. Any ideas (looking at the build.gradle file) as to how I can get this plugin to play nicely with my fat jar?

<var></var> properties

Is there a magical way that I am not aware of to set the var properties ?

<var>blablaa=1</var>

So far I was only able to do so by modifying the source code

Directory of the icon file

I have the problem that the createExe task cannot find the icon.ico file specified.

launch4j {
    outputDir = "release"
    outfile = "App.exe"
    mainClassName = "com.something.AppStarter"
    opt = "-Djogamp.gluegen.UseTempJarCache=false"
    jreRuntimeBits = "32"
    libraryDir = "libs"
    icon = "icon.ico"
}

Commenting out the line works and it will create the exe under the folder ./build/release.
Placing the icon.ico in build or in the root doesn't work.

Please update to Launch4J 3.9.0

3.8 contains a bug that when the minimum JRE update version is set and the installed JRE version is > 100, will cause erroneously to report that the minimum version is not met.

I.e. a min version set to 1.8.0_77 and actual JRE version of 1.8.0_101 will fail the minimum version check.

This bug is resolved in 3.9.0.

I reference the original bug report that I made to L4J tracker: https://sourceforge.net/p/launch4j/bugs/153/

Multiple Executables

Love the plugin @TheBoegl! Seriously good work.

I did want to inquire about being able to create more than one executable. I know that gradle tasks cannot be run more than once, but my goal is to create tasks that essentially alter the launch4j settings and then run createExe. Of course it wouldn't be able to work like that.

Is there a way to do what I'm asking now and I'm ignorant to gradle's ability? If so disregard this, otherwise do you think this is a feature worth including?

Thanks

MissingMethodException: No signature of method: Launch4jPluginExtension.onSetCopyConfigurable()

groovy.lang.MissingMethodException: No signature of method: edu.sc.seis.launch4j.Launch4jPluginExtension.onSetCopyConfigurable() is applicable for argument types: (edu.sc.seis.launch4j.Launch4jPlugin$_apply_closure1$_closure39) values: [edu.sc.seis.launch4j.Launch4jPlugin$_apply_closure1$_closure39@64327959]
  Possible solutions: onSetCopyConfigurable(org.gradle.api.Action), getCopyConfigurable(), setCopyConfigurable(java.lang.Object)

Doesn't seem to work

I guess it's due to the lack of experience, but the task has no output to help debugging either. Here's the script I'm using. hope it helps somehow to find my issue.

task assembleGameExe <<{
launch4j {
mainClassName = 'pcgen.system.Main'
icon = "${projectDir}/installers/win-installer/Local/pcgen.ico"
outfile = "${projectDir}/code/pcgen.exe"
jreMaxVersion = '1.8.9'
jdkPreference = 'preferJre'
initialHeapSize = 128
maxHeapSize = 512
stayAlive = false
bundledJre64Bit = true
jar = "${projectDir}/pcgen.jar"
dontWrapJar = true
bundledJrePath = 'jre'
}
}

I don't see the exe file being created. Just this output:

Executing: gradle :assembleGameExe
Arguments: [-c, /home/javier/Desktop/PCGen/settings.gradle]

:assembleGameExe

BUILD SUCCESSFUL

Total time: 3.101 secs

xmlConfigName doesnot seem to work

xmlConfigName does not work with either the launch4j plugin config or the External task. Is anyone trying to use the xml config and may be override some of the attributes with the plugin?

EXE will not start the JVM

The exe will not start the jvm.

Using process monitor, the last error the process shows before exiting is this:

HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\GRE_Initialize\DisableMetaFiles
This conversation is being saved. You'll see it soon in your Outlook Inbox folder.

it tries to open this key in the registry, and it isn't found

Windows reports virus

Hello,

I have created the exe file using gradle.plugin.edu.sc.seis.gradle:launch4j:2.4.2, but Windows 10 does not enable to run it.

What am I missing?

Thank you,
Serge

createExe failed

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':createExe'.
> net.sf.launch4j.BuilderException: net.sf.launch4j.ExecException: Exec failed (1): C:\Users\Kaochong\IdeaProjects\LiveDesktopTeacher\build\tmp\launch4j\bin-launch4j-3.11\bin\windres.exe --preprocessor=type -J rc -O coff -F pe-i386 C:\Users\Kaochong\AppData\Local\Temp\launch4j1150559857716479846rc C:\Users\Kaochong\AppData\Local\Temp\launch4j5131616090907150079o

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Total time: 44.128 secs
Exec failed (1): C:\Users\Kaochong\IdeaProjects\LiveDesktopTeacher\build\tmp\launch4j\bin-launch4j-3.11\bin\windres.exe --preprocessor=type -J rc -O coff -F pe-i386 C:\Users\Kaochong\AppData\Local\Temp\launch4j1150559857716479846rc C:\Users\Kaochong\AppData\Local\Temp\launch4j5131616090907150079o
17:36:56: External task execution finished 'createExe'.

 

My gradle:


launch4j {
    mainClassName = 'com.kaochong.live.desktop.Main'
    icon = 'application.ico'
    outfile = appFileName + '.exe'
    libraryDir = 'libs'
    outputDir = 'winApp'
}

Error when specifying an absolute path for outputDir

I am unable to set an absolute path for the outputDir property. I get the following message:

Could not normalize path for file 'C:\workspace\MyProj\build\C:\workspace\Other'.

Should this property work with an absolute path ? Or should this be better documented in the README ? In both cases, I can contribute with a PR.

Trying version 2.0.0: Failed to notify project evaluation listener

I just updated the version from 1.6.2 to 2.0.0 and now I get this error:

A problem occurred configuring root project 'pcgen'.
> Failed to notify project evaluation listener.
   > org.gradle.api.internal.AbstractTask.getInputs()Lorg/gradle/api/internal/TaskInputsInternal;

org.gradle.tooling.BuildException: Could not execute build using Gradle distribution 'https://services.gradle.org/distributions/gradle-2.14.1-all.zip'.
	at org.gradle.tooling.internal.consumer.ExceptionTransformer.transform(ExceptionTransformer.java:51)
	at org.gradle.tooling.internal.consumer.ExceptionTransformer.transform(ExceptionTransformer.java:29)
	at org.gradle.tooling.internal.consumer.ResultHandlerAdapter.onFailure(ResultHandlerAdapter.java:41)
	at org.gradle.tooling.internal.consumer.async.DefaultAsyncConsumerActionExecutor$1$1.run(DefaultAsyncConsumerActionExecutor.java:57)
	at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:54)
	at org.gradle.internal.concurrent.StoppableExecutorImpl$1.run(StoppableExecutorImpl.java:40)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:745)
	at org.gradle.tooling.internal.consumer.BlockingResultHandler.getResult(BlockingResultHandler.java:46)
	at org.gradle.tooling.internal.consumer.DefaultBuildLauncher.run(DefaultBuildLauncher.java:77)
	at org.netbeans.gradle.project.tasks.AsyncGradleTask.runBuild(AsyncGradleTask.java:371)
	at org.netbeans.gradle.project.tasks.AsyncGradleTask.doGradleTasksWithProgressIgnoreTaskDefCancel(AsyncGradleTask.java:494)
	at org.netbeans.gradle.project.tasks.AsyncGradleTask.doGradleTasksWithProgressIgnoreTaskDefCancel(AsyncGradleTask.java:404)
	at org.netbeans.gradle.project.tasks.AsyncGradleTask.doGradleTasksWithProgress(AsyncGradleTask.java:395)
	at org.netbeans.gradle.project.tasks.AsyncGradleTask.access$400(AsyncGradleTask.java:86)
	at org.netbeans.gradle.project.tasks.AsyncGradleTask$BuildExecutionItem$1.run(AsyncGradleTask.java:776)
	at org.netbeans.gradle.project.tasks.GradleDaemonManager.runBlockingGradleTask(GradleDaemonManager.java:51)
	at org.netbeans.gradle.project.tasks.GradleDaemonManager.access$200(GradleDaemonManager.java:22)
	at org.netbeans.gradle.project.tasks.GradleDaemonManager$2.execute(GradleDaemonManager.java:128)
	at org.jtrim.concurrent.AbstractTaskExecutorService$FunctionWrapper.execute(AbstractTaskExecutorService.java:270)
	at org.jtrim.concurrent.AbstractTaskExecutorService$TaskOfAbstractExecutor.execute(AbstractTaskExecutorService.java:340)
	at org.jtrim.concurrent.Tasks$RunOnceCancelableTask.execute(Tasks.java:342)
	at org.jtrim.concurrent.ThreadPoolTaskExecutor$ThreadPoolTaskExecutorImpl$QueuedItem.runTask(ThreadPoolTaskExecutor.java:1213)
	at org.jtrim.concurrent.ThreadPoolTaskExecutor$ThreadPoolTaskExecutorImpl$Worker.executeTask(ThreadPoolTaskExecutor.java:1049)
	at org.jtrim.concurrent.ThreadPoolTaskExecutor$ThreadPoolTaskExecutorImpl$Worker.run(ThreadPoolTaskExecutor.java:1179)
	at org.jtrim.concurrent.ThreadPoolTaskExecutor$ThreadPoolTaskExecutorImpl$Worker$1.run(ThreadPoolTaskExecutor.java:998)
	at java.lang.Thread.run(Thread.java:745)
Caused by: org.gradle.internal.exceptions.LocationAwareException: A problem occurred configuring root project 'pcgen'.
	at org.gradle.initialization.DefaultExceptionAnalyser.transform(DefaultExceptionAnalyser.java:74)
	at org.gradle.initialization.MultipleBuildFailuresExceptionAnalyser.transform(MultipleBuildFailuresExceptionAnalyser.java:47)
	at org.gradle.initialization.StackTraceSanitizingExceptionAnalyser.transform(StackTraceSanitizingExceptionAnalyser.java:30)
	at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:100)
	at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:92)
	at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:91)
	at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:63)
	at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:92)
	at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLauncher.java:83)
	at org.gradle.launcher.exec.InProcessBuildActionExecuter$DefaultBuildController.run(InProcessBuildActionExecuter.java:99)
	at org.gradle.tooling.internal.provider.runner.BuildModelActionRunner.run(BuildModelActionRunner.java:46)
	at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
	at org.gradle.tooling.internal.provider.runner.SubscribableBuildActionRunner.run(SubscribableBuildActionRunner.java:58)
	at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
	at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:48)
	at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:30)
	at org.gradle.launcher.exec.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:81)
	at org.gradle.launcher.exec.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:46)
	at org.gradle.launcher.daemon.server.exec.ExecuteBuild.doBuild(ExecuteBuild.java:52)
	at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
	at org.gradle.launcher.daemon.server.exec.WatchForDisconnection.execute(WatchForDisconnection.java:37)
	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
	at org.gradle.launcher.daemon.server.exec.ResetDeprecationLogger.execute(ResetDeprecationLogger.java:26)
	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
	at org.gradle.launcher.daemon.server.exec.RequestStopIfSingleUsedDaemon.execute(RequestStopIfSingleUsedDaemon.java:34)
	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
	at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:74)
	at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:72)
	at org.gradle.util.Swapper.swap(Swapper.java:38)
	at org.gradle.launcher.daemon.server.exec.ForwardClientInput.execute(ForwardClientInput.java:72)
	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
	at org.gradle.launcher.daemon.server.health.DaemonHealthTracker.execute(DaemonHealthTracker.java:47)
	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
	at org.gradle.launcher.daemon.server.exec.LogToClient.doBuild(LogToClient.java:60)
	at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
	at org.gradle.launcher.daemon.server.exec.EstablishBuildEnvironment.doBuild(EstablishBuildEnvironment.java:72)
	at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
	at org.gradle.launcher.daemon.server.health.HintGCAfterBuild.execute(HintGCAfterBuild.java:41)
	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
	at org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy$1.run(StartBuildOrRespondWithBusy.java:50)
	at org.gradle.launcher.daemon.server.DaemonStateCoordinator$1.run(DaemonStateCoordinator.java:237)
	at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:54)
	at org.gradle.internal.concurrent.StoppableExecutorImpl$1.run(StoppableExecutorImpl.java:40)
Caused by: org.gradle.api.ProjectConfigurationException: A problem occurred configuring root project 'pcgen'.
	at org.gradle.configuration.project.LifecycleProjectEvaluator.addConfigurationFailure(LifecycleProjectEvaluator.java:79)
	at org.gradle.configuration.project.LifecycleProjectEvaluator.notifyAfterEvaluate(LifecycleProjectEvaluator.java:74)
	at org.gradle.configuration.project.LifecycleProjectEvaluator.evaluate(LifecycleProjectEvaluator.java:61)
	at org.gradle.api.internal.project.AbstractProject.evaluate(AbstractProject.java:540)
	at org.gradle.api.internal.project.AbstractProject.evaluate(AbstractProject.java:93)
	at org.gradle.execution.TaskPathProjectEvaluator.configureHierarchy(TaskPathProjectEvaluator.java:42)
	at org.gradle.configuration.DefaultBuildConfigurer.configure(DefaultBuildConfigurer.java:35)
	at org.gradle.initialization.DefaultGradleLauncher$2.run(DefaultGradleLauncher.java:124)
	at org.gradle.internal.Factories$1.create(Factories.java:22)
	at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:91)
	at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:53)
	at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:121)
	at org.gradle.initialization.DefaultGradleLauncher.access$200(DefaultGradleLauncher.java:32)
	at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:98)
	... 42 more
Caused by: org.gradle.internal.event.ListenerNotificationException: Failed to notify project evaluation listener.
	at org.gradle.internal.event.AbstractBroadcastDispatch.dispatch(AbstractBroadcastDispatch.java:55)
	at org.gradle.internal.event.BroadcastDispatch.dispatch(BroadcastDispatch.java:79)
	at org.gradle.internal.event.BroadcastDispatch.dispatch(BroadcastDispatch.java:30)
	at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:93)
	at com.sun.proxy.$Proxy11.afterEvaluate(Unknown Source)
	at org.gradle.configuration.project.LifecycleProjectEvaluator.notifyAfterEvaluate(LifecycleProjectEvaluator.java:67)
	... 54 more
Caused by: java.lang.NoSuchMethodError: org.gradle.api.internal.AbstractTask.getInputs()Lorg/gradle/api/internal/TaskInputsInternal;
	at edu.sc.seis.launch4j.tasks.DefaultLaunch4jTask$_evaluateTaskDependencyIfAvailable_closure1.doCall(DefaultLaunch4jTask.groovy:32)
	at org.gradle.listener.ClosureBackedMethodInvocationDispatch.dispatch(ClosureBackedMethodInvocationDispatch.java:40)
	at org.gradle.listener.ClosureBackedMethodInvocationDispatch.dispatch(ClosureBackedMethodInvocationDispatch.java:25)
	at org.gradle.internal.event.AbstractBroadcastDispatch.dispatch(AbstractBroadcastDispatch.java:44)
	... 59 more

use sync instead of copy

If the jar that is produced in the jar task changes its name the current implementation will copy it into the lib folder and keep the old version there, too.

Can' define "launch4j" task like in the README

I have the following configuration:

plugins {
    id "com.github.jk1.dependency-license-report" version "0.3.5"
    id 'edu.sc.seis.launch4j' version '2.0.1'
}
apply plugin: 'java'

...

def mainClass = 'mediathek.Main'

...

//Windows executable generation

    launch4j {
        mainClassName = mainClass
        icon="../../res/Info/MediathekView.ico"
        dontWrapJar = true
    }

    task createNormalExe(type: edu.sc.seis.launch4j.tasks.Launch4jLibraryTask) {
	   outfile="MediathekView__Start.exe"

	   initialHeapSize=256
	   maxHeapSize=2048
	   maxHeapPercent=80
    }

    task createIpv4Exe(type: edu.sc.seis.launch4j.tasks.Launch4jLibraryTask) {
        outfile="MediathekView__ipv4__Start.exe"
        opt="-Djava.net.preferIPv4Stack=true"
	
	    initialHeapSize=256
	    maxHeapSize=2048
	    maxHeapPercent=80
    }

    task createOhneSpeichernExe(type: edu.sc.seis.launch4j.tasks.Launch4jLibraryTask) {
    	outfile="MediathekView__ohne_Speicher__Start.exe"
    }  

    task createPortableExe(type: edu.sc.seis.launch4j.tasks.Launch4jLibraryTask) {
    	outfile="MediathekView__Portable.exe"
    	cmdLine="Einstellungen/.mediathek3"
	
        initialHeapSize=256
	    maxHeapSize=2048
	    maxHeapPercent=80
    }

    task copyExesInRes(type: Copy) {
    	logger.lifecycle 'Copying windows programm executables.'
    	from 'build/launch4j'
    	into 'res'
    	include '*.exe'
    }

    assemble.dependsOn copyExesInRes
    copyExesInRes.dependsOn createAllExecutables

And if i run this i get:
Could not set unknown property 'mainClassName' for object of type org.gradle.api.distribution.internal.DefaultDistribution.

it works if i change it so the code from "launch4j" is in the tasks an run it works but i became an extra exe i not defined. And if i rename the "launch4j" task to "createExe" i get the same error as above.

applying 2.4.0 with the plugins DSL fails

Applying the plugin in version 2.4.0 with the plugins DSL

plugins {
   id 'edu.sc.seis.launch4j' version '2.4.0'
}

does not work.
This fails with the following error:

Error:Could not find com.springsource.org.apache.batik.ext.awt.jar (org.apache.batik:com.springsource.org.apache.batik.ext.awt:1.7.0).
Searched in the following locations:
    https://jcenter.bintray.com/org/apache/batik/com.springsource.org.apache.batik.ext.awt/1.7.0/com.springsource.org.apache.batik.ext.awt-1.7.0.jar

Plugin broken with gradle 3.4.1

I upgraded my wrapper to gradle 3.4.1 from 3.1 and the project started to give the following error during project configuration phase. id "edu.sc.seis.launch4j" version "2.3.0"

**Caused by: java.lang.NoClassDefFoundError: org/gradle/api/plugins/JavaPlugin
        at edu.sc.seis.launch4j.Launch4jPluginExtension.afterEvaluate(Launch4jPluginExtension.groovy:109)**


FAILURE: Build failed with an exception.

* What went wrong:
A problem occurred configuring project ':ECR_GMP3_SIMULATOR'.
> Failed to notify project evaluation listener.
   > org/gradle/api/plugins/JavaPlugin

* Try:
Run with --debug option to get more log output.

* Exception is:
org.gradle.api.ProjectConfigurationException: A problem occurred configuring project ':ECR_GMP3_SIMULATOR'.
        at org.gradle.configuration.project.LifecycleProjectEvaluator.addConfigurationFailure(LifecycleProjectEvaluator.java:94)
        at org.gradle.configuration.project.LifecycleProjectEvaluator.notifyAfterEvaluate(LifecycleProjectEvaluator.java:89)
        at org.gradle.configuration.project.LifecycleProjectEvaluator.doConfigure(LifecycleProjectEvaluator.java:76)
        at org.gradle.configuration.project.LifecycleProjectEvaluator.access$000(LifecycleProjectEvaluator.java:33)
        at org.gradle.configuration.project.LifecycleProjectEvaluator$1.execute(LifecycleProjectEvaluator.java:53)
        at org.gradle.configuration.project.LifecycleProjectEvaluator$1.execute(LifecycleProjectEvaluator.java:50)
        at org.gradle.internal.Transformers$4.transform(Transformers.java:169)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:106)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:61)
        at org.gradle.configuration.project.LifecycleProjectEvaluator.evaluate(LifecycleProjectEvaluator.java:50)
        at org.gradle.api.internal.project.DefaultProject.evaluate(DefaultProject.java:599)
        at org.gradle.api.internal.project.DefaultProject.evaluate(DefaultProject.java:125)
        at org.gradle.execution.TaskPathProjectEvaluator.configure(TaskPathProjectEvaluator.java:35)
        at org.gradle.execution.TaskPathProjectEvaluator.configureHierarchy(TaskPathProjectEvaluator.java:62)
        at org.gradle.configuration.DefaultBuildConfigurer.configure(DefaultBuildConfigurer.java:38)
        at org.gradle.initialization.DefaultGradleLauncher$ConfigureBuildAction.execute(DefaultGradleLauncher.java:233)
        at org.gradle.initialization.DefaultGradleLauncher$ConfigureBuildAction.execute(DefaultGradleLauncher.java:230)
        at org.gradle.internal.Transformers$4.transform(Transformers.java:169)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:106)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:56)
        at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:160)
        at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:119)
        at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLauncher.java:102)
        at org.gradle.launcher.exec.GradleBuildController.run(GradleBuildController.java:71)
        at org.gradle.tooling.internal.provider.ExecuteBuildActionRunner.run(ExecuteBuildActionRunner.java:28)
        at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
        at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:41)
        at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:26)
        at org.gradle.tooling.internal.provider.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:75)
        at org.gradle.tooling.internal.provider.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:49)
        at org.gradle.tooling.internal.provider.ServicesSetupBuildActionExecuter.execute(ServicesSetupBuildActionExecuter.java:49)
        at org.gradle.tooling.internal.provider.ServicesSetupBuildActionExecuter.execute(ServicesSetupBuildActionExecuter.java:31)
        at org.gradle.launcher.daemon.server.exec.ExecuteBuild.doBuild(ExecuteBuild.java:67)
        at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.WatchForDisconnection.execute(WatchForDisconnection.java:47)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.ResetDeprecationLogger.execute(ResetDeprecationLogger.java:26)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.RequestStopIfSingleUsedDaemon.execute(RequestStopIfSingleUsedDaemon.java:34)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:74)
        at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:72)
        at org.gradle.util.Swapper.swap(Swapper.java:38)
        at org.gradle.launcher.daemon.server.exec.ForwardClientInput.execute(ForwardClientInput.java:72)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.LogAndCheckHealth.execute(LogAndCheckHealth.java:55)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.LogToClient.doBuild(LogToClient.java:60)
        at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.EstablishBuildEnvironment.doBuild(EstablishBuildEnvironment.java:72)
        at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy$1.run(StartBuildOrRespondWithBusy.java:50)
        at org.gradle.launcher.daemon.server.DaemonStateCoordinator$1.run(DaemonStateCoordinator.java:297)
        at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63)
        at org.gradle.internal.concurrent.StoppableExecutorImpl$1.run(StoppableExecutorImpl.java:46)
Caused by: org.gradle.internal.event.ListenerNotificationException: Failed to notify project evaluation listener.
        at org.gradle.internal.event.AbstractBroadcastDispatch.dispatch(AbstractBroadcastDispatch.java:55)
        at org.gradle.internal.event.BroadcastDispatch.dispatch(BroadcastDispatch.java:79)
        at org.gradle.internal.event.BroadcastDispatch.dispatch(BroadcastDispatch.java:30)
        at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:93)
        at com.sun.proxy.$Proxy16.afterEvaluate(Unknown Source)
        at org.gradle.configuration.project.LifecycleProjectEvaluator.notifyAfterEvaluate(LifecycleProjectEvaluator.java:82)
        ... 56 more
Caused by: java.lang.NoClassDefFoundError: org/gradle/api/plugins/JavaPlugin
        at edu.sc.seis.launch4j.Launch4jPluginExtension.afterEvaluate(Launch4jPluginExtension.groovy:109)
        at edu.sc.seis.launch4j.Launch4jPluginExtension$afterEvaluate.call(Unknown Source)
        at edu.sc.seis.launch4j.Launch4jPlugin$_apply_closure1.doCall(Launch4jPlugin.groovy:55)
        at org.gradle.listener.ClosureBackedMethodInvocationDispatch.dispatch(ClosureBackedMethodInvocationDispatch.java:40)
        at org.gradle.listener.ClosureBackedMethodInvocationDispatch.dispatch(ClosureBackedMethodInvocationDispatch.java:25)
        at org.gradle.internal.event.AbstractBroadcastDispatch.dispatch(AbstractBroadcastDispatch.java:44)
        ... 61 more

The dependencies.classpath in the example might not be correct.

Hi,

just fyi...

When I use from the example:
buildscript { repositories { jcenter() } dependencies { classpath 'gradle.plugin.edu.sc.seis.gradle:launch4j:2.3.0' } }

I get this error:

Error:Could not find gradle.plugin.edu.sc.seis.gradle:launch4j:2.3.0.
Searched in the following locations:
https://jcenter.bintray.com/gradle/plugin/edu/sc/seis/gradle/launch4j/2.3.0/launch4j-2.3.0.pom
https://jcenter.bintray.com/gradle/plugin/edu/sc/seis/gradle/launch4j/2.3.0/launch4j-2.3.0.jar
Required by:
project :

But when I use the following, it works:
buildscript { repositories { jcenter() } dependencies { classpath 'edu.sc.seis.gradle:launch4j:2.3.0' } }

Should the "jar" task be skipped if "shadowJar" is used?

I use the next config:

shadowJar {
  classifier = null
  dependsOn ':test'
}

jar {
  manifest {
    attributes 'Main-Class': 'org.superman.SuperClass',
               'SplashScreen-Image': splashImagePath,
               'Implementation-Version': buildVersion
  }
}

task mainJarBuild (type:Task) {
  dependsOn ':clean', ':shadowJar', ':test'
  jar.enabled = false
}

task winLauncherBuild(dependsOn:[mainJarBuild, createExe], type:Task) {
  createExe.dependsOn mainJarBuild
  createExe.mustRunAfter mainJarBuild
}

launch4j {
  mainClassName =  'org.superman.SuperClass'
  version = buildVersion
  textVersion = "${archivesBaseName} version ${buildVersion}"
  copyConfigurable = project.tasks.shadowJar.outputs.files
  jar = "lib/${project.tasks.shadowJar.archiveName}"
  outfile = "${archivesBaseName}.exe"
}

When i run ./gradlew winLauncherBuild all the task are executed in proper order, except the jar task is executed right before createExe task and overrides shadowJar results:

:clean
:compileJava
:processResources
:classes
:compileTestJava
:processTestResources UP-TO-DATE
:testClasses
:test
:shadowJar
:mainJarBuild
:winLauncherBuild
:jar 
:createExe

Apparently, createExe depends on jar and shadowJar task, but how to avoid jar execution if shadowJar is expected?

Now i do the next crutch:

jar.enabled = false

But this looks a bit ugly. Is there any other solution?

Remove dependency for JavaPlugin

Comment by [email protected] (@david-hall)

The snippet of build.gradle shown should also include a line saying "apply plugin: 'java'" since the java plugin is referenced as the default value of the jar property: >"lib/"+project.tasks[JavaPlugin.JAR_TASK_NAME].outputs.files.getSingleFile().name.

I use launch4j (and this plugin) in a gradle sub-project which does not require the java plugin otherwise. The sub-project is simply for generating the Windows executable wrapper and a self extracting zip file with a bundled JRE. The main project is the one with all of the java code and the java plugin. Since the java plugin is included in the subproject, it creates a bunch of unnecessary jar files. Is there any way to make this plugin work without requiring the java plugin? Maybe keep the default as-is if the plugin is in the project, but otherwise default to an empty string? I think that approach would maintain backwards compatibility but would no longer cause the problems I describe in a project with no java compile tasks and therefore no java plugin needed.

Add missing Issue from google code.

Dependency issue with 1.5.3

Hello,

I have the following gradle script. I generate an exe containing the resul of a fat jar (using the shadow gradle plugin). This work correctly with 1.5.1, but with 1.5.3 I have the following error:

Error:(37, 0) Could not find property 'copyL4jLib' on root project

My gradle file :

buildscript {
    repositories {
        maven {
            url 'https://plugins.gradle.org/m2/'
        }
    }
    dependencies {
        classpath 'gradle.plugin.edu.sc.seis.gradle:launch4j:1.5.3'
        classpath 'com.github.jengelman.gradle.plugins:shadow:1.2.2'
    }
}

repositories {
    mavenCentral()
}

apply plugin: 'java'
apply plugin: 'application'
apply plugin: 'edu.sc.seis.launch4j'

evaluationDependsOnChildren()

repositories {
    mavenCentral()
}

/* THIS IS THE LINE CAUSING A PROBLEM */
copyL4jLib.dependsOn shadowJar

launch4j {
    copyConfigurable = project.tasks.shadowJar.outputs.files
    mainClassName = project.mainClassName
    icon = '../../../my.ico'
    jar = "lib/${project.tasks.shadowJar.archiveName}"
    dontWrapJar = false
}

Custom slf4j logger within wrapped jar

As title says

Whenever you build far jar and wrap the jar within the .exe custom loggers aren't discovered somehow

C:\Users\UnAfraid\Desktop>java -jar ClientEditorUI.exe
2017-01-03 00:03:58,251 ERROR Error processing element GUILogger: CLASS_NOT_FOUND
2017-01-03 00:03:58,292 ERROR Unable to locate appender JavaFXLogger for logger

When running the jar:

C:\Users\UnAfraid\Desktop>java -jar ClientEditorUI.jar
[00:03:45] [INFO] MainController: Welcome to the Client Editor!

When you do java -jar the.exe it fails to find it, but when you do java -jar the.jar it works.
Whenever you open the exe with 7z manager lets say all is there the files are there, both config file and the compiled custom logger appender

Here's another report of the very same issue http://stackoverflow.com/questions/39866144/in-launch4j-wrapper-my-custom-log4j2-appender-cant-be-found

My repository with test case https://github.com/UnAfraid/Launch4jPlusSLF4j

Whenever i do dontWrapJar = true it works fine.

cleanCreateExe doesn't clean the UP-TO-DATE state

I'm trying to make sure the createExe is executed always so I'm trying something like this:

task copyToRoot(type: Copy, dependsOn: [cleanCreateExe, createExe]) {
   ....
    }

copyToRoot.mustRunAfter cleanCreateExe
copyToRoot.mustRunAfter createExe

It seems to do as expected, but still gives UP-TO-DATE result:

Executing: gradle :copyToRoot
Arguments: [-c, /home/javier/Desktop/pcgen/settings.gradle]

:cleanCreateExe UP-TO-DATE
:createExe UP-TO-DATE
...

Something seems off.

Fails under new plugin architecture

I get an error of "Error:(24, 0) Could not find property 'targetCompatibility' on root project ..." when i use the new plugin architecture with launch4j.

My file looks like

plugins {
    id 'java'
    id 'application'
    id 'edu.sc.seis.launch4j' version '1.1.2'
}

But it does work when I change it to

buildscript {
    repositories {
        maven {
            url "https://plugins.gradle.org/m2/"
        }
    }
    dependencies {
        classpath "gradle.plugin.edu.sc.seis.gradle:launch4j:1.1.2"
    }
}

apply plugin: 'java'
apply plugin: 'application'
apply plugin: 'edu.sc.seis.launch4j'

This is not a big issue and I am not sure where the problem is, launch4j plugin, or in the new architecture.

Thanks

IOException: Cannot run program "windres": error=2, No such file or directory

I'm using version 2.3.0, but was failing on previous versions as well. I verified the file is there.

I'm running Ubuntu 16.04. The source can be obtained here.

Here's the full stack trace:

`FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':createExe'.

Launch4J finished with non-zero exit value 1
launch4j: Compiling resources
launch4j: Generated resource file...

launch4j: LANGUAGE 0, 1
1 VERSIONINFO
FILEVERSION 0, 0, 0, 1
PRODUCTVERSION 0, 0, 0, 1
FILEFLAGSMASK 0
FILEOS 0x40000
FILETYPE 1
{
BLOCK "StringFileInfo"
{
BLOCK "040904E4"
{
VALUE "CompanyName", ""
VALUE "FileDescription", "pcgen"
VALUE "FileVersion", "6.07.02-SNAPSHOT"
VALUE "InternalName", "pcgen"
VALUE "LegalCopyright", "PCGen's source-code is distributed under the GNU Lesser General Public License (LGPL)"
VALUE "LegalTrademarks", ""
VALUE "OriginalFilename", "../release/pcgen.exe"
VALUE "ProductName", "pcgen"
VALUE "ProductVersion", "6.07.02-SNAPSHOT"
}
}
BLOCK "VarFileInfo"
{
VALUE "Translation", 0x0409, 0x04E4
}
}1 RCDATA BEGIN "jre\0" END
29 RCDATA BEGIN "true\0" END
2 RCDATA BEGIN "1.8.0\0" END
18 RCDATA BEGIN "1\0" END
30 RCDATA BEGIN "2\0" END
25 RCDATA BEGIN "128\0" END
27 RCDATA BEGIN "512\0" END
1 ICON DISCARDABLE "/home/javydreamercsw/NetBeansProjects/pcgen/build/launch4j/../../installers/win-installer/Local/pcgen.ico"
21 RCDATA BEGIN "http://java.com/download\0" END
8 RCDATA BEGIN ".\0" END
20 RCDATA BEGIN "32\0" END
4 RCDATA BEGIN "true\0" END
5 RCDATA BEGIN "true\0" END
6 RCDATA BEGIN "60\0" END
7 RCDATA BEGIN "true\0" END
1 BITMAP "/home/javydreamercsw/NetBeansProjects/pcgen/build/launch4j/../../installers/win-installer/Local/splash.bmp"
101 RCDATA BEGIN "An error occurred while starting the application.\0" END
102 RCDATA BEGIN "This application was configured to use a bundled Java Runtime Environment but the runtime is missing or corrupted.\0" END
103 RCDATA BEGIN "This application requires a Java Runtime Environment\0" END
104 RCDATA BEGIN "The registry refers to a nonexistent Java Runtime Environment installation or the runtime is corrupted.\0" END
15 RCDATA BEGIN "pcgen.system.Main\0" END
16 RCDATA BEGIN "..\launch4j\lib\pcgen-6.07.02-SNAPSHOT.jar;..\launch4j\lib\cobra-0.98.4-pcgen.jar;..\launch4j\lib\commons-io-2.5.jar;..\launch4j\lib\js-1.7R2.jar;..\launch4j\lib\commons-logging-1.2.jar;..\launch4j\lib\spring-core-4.3.6.RELEASE.jar;..\launch4j\lib\spring-beans-4.3.6.RELEASE.jar;..\launch4j\lib\skinlf-1.2.3.jar;..\launch4j\lib\commons-lang3-3.5.jar;..\launch4j\lib\fop-2.1.jar;..\launch4j\lib\fontbox-2.0.4.jar;..\launch4j\lib\jep-2.4.1.jar;..\launch4j\lib\freemarker-2.3.25-incubating.jar;..\launch4j\lib\jdom2-2.0.6.jar;..\launch4j\lib\xalan-2.7.2.jar;..\launch4j\lib\argparse4j-0.7.0.jar;..\launch4j\lib\PCGen-base-1.0.83-javadoc.jar;..\launch4j\lib\PCGen-base-1.0.83.jar;..\launch4j\lib\PCGen-base-1.0.83-sources.jar;..\launch4j\lib\PCGen-Formula-1.0.101-javadoc.jar;..\launch4j\lib\PCGen-Formula-1.0.101.jar;..\launch4j\lib\PCGen-Formula-1.0.101-sources.jar;..\launch4j\lib\xmlgraphics-commons-2.1.jar;..\launch4j\lib\batik-svg-dom-1.8.jar;..\launch4j\lib\batik-bridge-1.8.jar;..\launch4j\lib\batik-awt-util-1.8.jar;..\launch4j\lib\batik-gvt-1.8.jar;..\launch4j\lib\batik-transcoder-1.8.jar;..\launch4j\lib\batik-extension-1.8.jar;..\launch4j\lib\batik-ext-1.8.jar;..\launch4j\lib\avalon-framework-api-4.3.1.jar;..\launch4j\lib\avalon-framework-impl-4.3.1.jar;..\launch4j\lib\serializer-2.7.2.jar;..\launch4j\lib\batik-css-1.8.jar;..\launch4j\lib\batik-dom-1.8.jar;..\launch4j\lib\batik-parser-1.8.jar;..\launch4j\lib\batik-util-1.8.jar;..\launch4j\lib\xml-apis-1.3.04.jar;..\launch4j\lib\xml-apis-ext-1.3.04.jar;..\launch4j\lib\batik-anim-1.8.jar;..\launch4j\lib\batik-script-1.8.jar;..\launch4j\lib\batik-xml-1.8.jar;..\launch4j\lib\batik-svggen-1.8.jar\0" END
14 RCDATA BEGIN "..\launch4j\pcgen.jar\0" END

launch4j: net.sf.launch4j.ExecException: java.io.IOException: Cannot run program "/home/javydreamercsw/NetBeansProjects/pcgen/build/tmp/launch4j/bin-launch4j-3.9/bin/windres": error=2, No such file or directory`

Targeted java version?

Hi,
I tried your launch4j gradle plugin, however the error message "Unsupported major.minor version 52.0" appears, that suggests that the plugin is compiled for Java 8. My machine is still on 7.
If it is the case, any specific reason for targeting 8?
Thanks,
Stefan Frey

NoClassDefFoundError: com/thoughtworks/xstream/io/HierarchicalStreamDriver

In attempting to create an executable for my spring-boot app I get the following:

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':createExeWithJar'.

    Launch4J finished with non-zero exit value 1
    Exception in thread "main" java.lang.NoClassDefFoundError: com/thoughtworks/xstream/io/HierarchicalStreamDriver
    at net.sf.launch4j.Main.main(Main.java:61)
    Caused by: java.lang.ClassNotFoundException: com.thoughtworks.xstream.io.HierarchicalStreamDriver
    at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
    ... 1 more

I added the XStream dependency to both the buildscript classpath and project classpath to no avail. Here's my build.gradle

buildscript {
    ext {
        springBootVersion = '1.3.0.RELEASE'
    }
    repositories {
        mavenCentral()
        maven {
            url 'https://plugins.gradle.org/m2/'
        }
    }
    dependencies {
        classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
        classpath('gradle.plugin.edu.sc.seis.gradle:launch4j:1.5.4')
        classpath('com.thoughtworks.xstream:xstream:1.4.8')
    }
}

apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: 'spring-boot'
apply plugin: 'edu.sc.seis.launch4j'

launch4j {
    mainClassName = 'org.springframework.boot.loader.JarLauncher'
    icon = 'src/main/resources/ge.ico'
}



jar {
    baseName = 'cimnet-util'
    version = '1.0.0-SNAPSHOT'
}
sourceCompatibility = 1.8
targetCompatibility = 1.8

repositories {
    mavenCentral()
    maven { url "https://repo.spring.io/snapshot" }
    maven { url "https://repo.spring.io/milestone" }
}


dependencies {
    compile('org.springframework.boot:spring-boot-devtools')
    compile('org.springframework.boot:spring-boot-starter-freemarker')
    compile('org.projectlombok:lombok')
    compile('net.sf.jopt-simple:jopt-simple:4.9')
    compile("com.beust:jcommander:1.48")
    compile('com.thoughtworks.xstream:xstream:1.4.8')
    testCompile('org.springframework.boot:spring-boot-starter-test') 
}

dependencyManagement {
    imports { 
        mavenBom "org.springframework.cloud:spring-cloud-starter-parent:Brixton.M3" 
    }
}


eclipse {
    classpath {
         containers.remove('org.eclipse.jdt.launching.JRE_CONTAINER')
         containers 'org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8'
    }
}

task wrapper(type: Wrapper) {
    gradleVersion = '2.9'
}

Any help is greatly appreciated

Why "opt" property is a string

Most of the plugins with JVM wrapping (and not only JVM) use arguments as a list, but in this plugin it is just a string. Isn't it more conventional to make it as an array of strings?

Splashscreen config option

It would be nice to be able to provide a splashscreen image the same way as it
is possible in raw launch4j config:

<splash>
    <file>file</file>
    <waitForWindow>true|false</waitForWindow>
    <timeout>seconds [60]</timeout>
    <timeoutErr>true|false</timeoutErr>
</splash>

Original issue reported on code.google.com by [email protected] on 7 Jul 2014 at 3:00

Sample Scripts

This might be more of a nice idea for a wiki page, but I would really like a nice community dumping ground for working gradle build scripts utilizing launch4j. I definitely have one to contribute that I used for my master's thesis, but I'm looking to expand my knowledge of gradle and especially the usage of this plugin.
Thanks,
Alex

Simple, complete, working example

It'd be nice to see the documentation updated with an example that would work against the latest version. For example:

build.gradle

plugins {
  id 'edu.sc.seis.launch4j' version '2.1.0'
}

apply plugin: 'java'
apply plugin: 'application'

applicationName = 'example'
mainClassName = 'com.domain.ApplicationMain'

repositories {
  mavenCentral()
}

jar {
  baseName = applicationName
  
  doFirst {
    from {
      configurations.compile.collect { it.isDirectory() ? it : zipTree(it) }
    }
  }

  // Remove digital signature files to ensure an executable JAR file.
  exclude 'META-INF/*.RSA', 'META-INF/*.SF','META-INF/*.DSA' 

  manifest {
    attributes 'Main-Class': mainClassName
    attributes 'Class-Path': configurations.compile.collect {
     'libs/' + it.getName()
    }.join(' ')
  }
}

distributions {
  main {
    baseName = applicationName
    contents {
      from { ['LICENSE', 'README.md'] }
      into( 'images' ) {
        from { 'images' }
      }
    }
  }
  
  launch4j {
    mainClassName = mainClassName

    /* Example options here? Set icon, executable filename, etc. */
  }

  assemble.dependsOn createAllExecutables
}

Reduce assumptions about project structure

Hi, I've already added this as comment to #37 but I think it may have been lost.

Unfortunately I'm still unable to build my application, so I'll try to give more context.
As mentioned before, the application consists of multiple modules, and the distribution should look like this (items marked with a * should go in the classpath):

outputDir
| application.exe
+ \ module A
  + \ moduleA.jar *
    + \ lib (native .DLLs go here)
    + \ config *
    | <arbitrary other files>
+ \ module B
  + \ moduleB.jar *
    /* ... */
+ \ <third party libs> *

Ideally, I'd like to be able to convince the launch4j plugin to not make any assumptions about my directory structure. Just point it at a directory, specify what should be included in the classpath and have it generate an .exe-file.

Alternatively, being able to provide a CopySpec for copyConfigurable might work as well for me, but I'm a bit worried about that resulting in an unnecessary amount of copies of the output files.

Thanks for investing your time in this, I appreciate it.

Use the x86 version of Launch4j for Mac OS X

The main page of this project has a big warning about how Launch4j is written for PPC, which no longer works since OS 10.7 (Lion). In fact, Launch4j does have a version of x86 processors on OS X that is compatible with OS 10.7 and later. This can clearly be seen on the download page of Launch4j 3.8, the latest version as of this writing. In fact, no PPC version is available any more.

Gradle-launch4j should use a version of Launch4j that supports x86 processors, and update its instructions accordingly.

No repository

If this plugin is loaded with the new plugin mechanism like

plugins {
    id 'edu.sc.seis.launch4j' version '1.4.0'
}

the launch4j artifacts can not be retrieved, because no repository is configured yet.

Is it possible to use gradle-launch4j with XML configuration

I have my legacy project which builds exe using command line in Windows like here described in the docs:
launch4jc buldConf/launch4j-config.xml

Now i'd like to use gradle-launch4j plugin instead. Could i reuse existent XML settings file, instead of setting all those properties manually?

As i understood, xmlFileName is just an output name for generateXmlConfig task.

Thanks

Automatically install launch4j

It would be great if the plugin could automatically download and install (relative to the working tree) a given version of launch4j for use with the plugin.

Setting an empty classpath and an executable JAR file

In my setup I need launch4j to simply execute a JAR file which has a Main-Class setting in the manifest.

How how would one specify an empty classpath - so only the JAR specified in the jar parameter would be used to form the classpath? At the moment, all the dependencies for the Gradle project are listed in $build/launch4j/lib so I think those are also being added to the classpath.

I have tried:

copyConfigurable=false

And

copyConfigurable=[]

Neither seem to affect the lib/ folder.

Also, the generated launch4j.xml file is no longer stored in $build/launch4j - can that be retained for debugging purposes?

Now, maybe the listing of all libs in $build/launch4j/lib doesn't mean the libs are all added to the classpath, but in the absence of the generated launch4j.xml file I don't have visibility of that.

Here are my wider settings:

launch4j {
	dontWrapJar=true 
	headerType="gui" 
	outfile="bliss.exe" 
	chdir="." 
	stayAlive=false
	copyConfigurable=false
	
	mainClassName='com.elsten.bliss.bootstrap.Bootstrap'
	jar="..\\lib\\com.elsten.bliss.bootstrap.jar"
	jreMinVersion='1.7.0'
	splashFileName="${projectDir}/src/dist/bin/bliss-splash.bmp"
	splashWaitForWindows=false 
	splashTimeout="5" 
	splashTimeoutError=false
	mutexName="bliss"
}

launch4j: Icon doesn't exist

Hey, I'm trying to use your plugin and keep getting an Icon doesn't exist exception.

C:\Users\Leejjon\IdeaProjects\streampie>gradlew.bat desktop:launch4j --stacktrace
:desktop:compileJava UP-TO-DATE
:desktop:processResources UP-TO-DATE
:desktop:classes UP-TO-DATE
:desktop:jar UP-TO-DATE
:desktop:copyL4jLib UP-TO-DATE
:desktop:generateXmlConfig UP-TO-DATE
:desktop:createExeWithBin SKIPPED
:desktop:unzipL4jBin UP-TO-DATE
:desktop:copyL4jBinLib UP-TO-DATE
:desktop:createExeWithJar FAILED

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':desktop:createExeWithJar'.

    Launch4J finished with non-zero exit value 1
    launch4j: Icon doesn't exist.

  • Try:
    Run with --info or --debug option to get more log output.

  • Exception is:
    org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':desktop:createExeWithJar'.
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:69)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:46)
    at org.gradle.api.internal.tasks.execution.PostExecutionAnalysisTaskExecuter.execute(PostExecutionAnalysisTaskExecuter.java:35)
    at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:64)
    at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:58)
    at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:52)
    at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:52)
    at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:53)
    at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter.execute(ExecuteAtMostOnceTaskExecuter.java:43)
    at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:208)
    at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:186)
    at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.processTask(AbstractTaskPlanExecutor.java:62)
    at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.run(AbstractTaskPlanExecutor.java:50)
    at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor.process(DefaultTaskPlanExecutor.java:25)
    at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter.execute(DefaultTaskGraphExecuter.java:111)
    at org.gradle.execution.SelectedTaskExecutionAction.execute(SelectedTaskExecutionAction.java:37)
    at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:62)
    at org.gradle.execution.DefaultBuildExecuter.access$200(DefaultBuildExecuter.java:23)
    at org.gradle.execution.DefaultBuildExecuter$2.proceed(DefaultBuildExecuter.java:68)
    at org.gradle.execution.DryRunBuildExecutionAction.execute(DryRunBuildExecutionAction.java:32)
    at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:62)
    at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:55)
    at org.gradle.initialization.DefaultGradleLauncher$6.run(DefaultGradleLauncher.java:174)
    at org.gradle.internal.Factories$1.create(Factories.java:22)
    at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:62)
    at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:47)
    at org.gradle.initialization.DefaultGradleLauncher.runBuildOperation(DefaultGradleLauncher.java:189)
    at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:171)
    at org.gradle.initialization.DefaultGradleLauncher.access$200(DefaultGradleLauncher.java:35)
    at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:104)
    at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:97)
    at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:62)
    at org.gradle.initialization.DefaultGradleLauncher.runRootBuildOperation(DefaultGradleLauncher.java:184)
    at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:97)
    at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLauncher.java:86)
    at org.gradle.launcher.exec.InProcessBuildActionExecuter$DefaultBuildController.run(InProcessBuildActionExecuter.java:93)
    at org.gradle.tooling.internal.provider.ExecuteBuildActionRunner.run(ExecuteBuildActionRunner.java:28)
    at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
    at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:43)
    at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:27)
    at org.gradle.launcher.exec.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:72)
    at org.gradle.launcher.exec.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:44)
    at org.gradle.launcher.exec.DaemonUsageSuggestingBuildActionExecuter.execute(DaemonUsageSuggestingBuildActionExecuter.java:50)
    at org.gradle.launcher.exec.DaemonUsageSuggestingBuildActionExecuter.execute(DaemonUsageSuggestingBuildActionExecuter.java:27)
    at org.gradle.launcher.cli.RunBuildAction.run(RunBuildAction.java:40)
    at org.gradle.internal.Actions$RunnableActionAdapter.execute(Actions.java:170)
    at org.gradle.launcher.cli.CommandLineActionFactory$ParseAndBuildAction.execute(CommandLineActionFactory.java:237)
    at org.gradle.launcher.cli.CommandLineActionFactory$ParseAndBuildAction.execute(CommandLineActionFactory.java:210)
    at org.gradle.launcher.cli.JavaRuntimeValidationAction.execute(JavaRuntimeValidationAction.java:35)
    at org.gradle.launcher.cli.JavaRuntimeValidationAction.execute(JavaRuntimeValidationAction.java:24)
    at org.gradle.launcher.cli.CommandLineActionFactory$WithLogging.execute(CommandLineActionFactory.java:206)
    at org.gradle.launcher.cli.CommandLineActionFactory$WithLogging.execute(CommandLineActionFactory.java:169)
    at org.gradle.launcher.cli.ExceptionReportingAction.execute(ExceptionReportingAction.java:33)
    at org.gradle.launcher.cli.ExceptionReportingAction.execute(ExceptionReportingAction.java:22)
    at org.gradle.launcher.Main.doAction(Main.java:33)
    at org.gradle.launcher.bootstrap.EntryPoint.run(EntryPoint.java:45)
    at org.gradle.launcher.bootstrap.ProcessBootstrap.runNoExit(ProcessBootstrap.java:54)
    at org.gradle.launcher.bootstrap.ProcessBootstrap.run(ProcessBootstrap.java:35)
    at org.gradle.launcher.GradleMain.main(GradleMain.java:23)
    at org.gradle.wrapper.BootstrapMainStarter.start(BootstrapMainStarter.java:30)
    at org.gradle.wrapper.WrapperExecutor.execute(WrapperExecutor.java:127)
    at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:61)
    Caused by: org.gradle.api.GradleException: Launch4J finished with non-zero exit value 1
    launch4j: Icon doesn't exist.

    at edu.sc.seis.launch4j.Launch4jPlugin$_addRunLaunch4jLibTask_closure35.doCall(Launch4jPlugin.groovy:238)
    at org.gradle.api.internal.AbstractTask$ClosureTaskAction.execute(AbstractTask.java:554)
    at org.gradle.api.internal.AbstractTask$ClosureTaskAction.execute(AbstractTask.java:535)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:80)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:61)
    ... 61 more

BUILD FAILED

Total time: 7.331 secs

Here is my project setup. I have tried to put my icon in different locations such as the parent project, next to the build.gradle etc, but I can not figure out where it looks for the .ico file.
launch4jproblem

Please tell me how to fix this. And perhaps print the file path where the plugin is trying to search for launch4j when this exception occurs, so it's easier for users to track down the problem.

Expose launch4j-generated outputs in `launch4j` task

I want to create a task that will copy the launch4j-generated outputs into a specific directory, e.g.

task deploy(type: Copy) {
  from launch4j
  into 'myoutputdir'
}

I've noticed that in Launch4JPlugin you already connect the inputs and outputs for some of the tasks, but it is not propagated from the internal tasks to the user visible ones, please add that.

Launch4j and FatJar

We build a fat jar using the fatJar gradle plugin. We would like to convert this jar into a single exe file with your plugin. How can I deactivate the copyL4jLib task? Because this is not required for my task - I am only interested in copying a single jar file over.

Classpath

Hi,

i have a question.
How is it possible to set the classpath.
The jar has no classpath configured in the manifest by dafeult.
How does launch4j handle the dependend jars?

Thanks

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.