1
votes

We just switched to 6.1.1 from 5, built our install and it is failing to launch. I'm running a unix install on a Mac. Also tried the a dmg install with the same problem. I haven't tried the windows or on Linux yet.

I'm running the latest jdk 1.8 to build and install.

java.lang.RuntimeException: java.lang.ClassCastException: com.install4j.runtime.beans.screens.StartupScreen cannot be cast to com.install4j.api.beans.Bean at com.install4j.runtime.installer.frontend.GUIHelper.invokeOnEDT(GUIHelper.java:668) at com.install4j.runtime.installer.config.AbstractBeanConfig.finishBatch(AbstractBeanConfig.java:47) at com.install4j.runtime.installer.ContextImpl.registerScreens(ContextImpl.java:681) at com.install4j.runtime.installer.controller.Controller.start(Controller.java:66) at com.install4j.runtime.installer.Installer.runInProcess(Installer.java:59) at com.install4j.runtime.installer.Installer.main(Installer.java:46) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at com.exe4j.runtime.LauncherEngine.launch(LauncherEngine.java:62) at com.install4j.runtime.launcher.UnixLauncher.main(UnixLauncher.java:57) Caused by: java.lang.ClassCastException: com.install4j.runtime.beans.screens.StartupScreen cannot be cast to com.install4j.api.beans.Bean

3

3 Answers

0
votes

Ok seems to be the display of a PDF. We used that task to show a short PDF document. It's not critical for us to do so, so I took it out of the installer. Perhaps support for PDF display has been removed from install4j?

0
votes

This is a regression in install4j 6.1 and will be fixed in install4j 6.1.2. If you need a build where this is already fixed, contact [email protected]

0
votes

If window create a bat file, for MAC shellscript .sh could come in handly

To Launch it, create a bat file in place of installation [mostly in bin folder]

inside the Bat file [Launcher.bat(any name you prefer)]:

  • set IBM_JAVA_OPTIONS=
  • set _JAVA_OPTIONS=
  • set JAVA_TOOL_OPTIONS=
  • [your executable file] xxx.exe/jar/...etc,.

and save it. every time you can launch the application via BAT file.

For Example I had issue while launching Jmeter The solution was:

I created a Bat file : JMeterLauncher.bat with below content.

  • set IBM_JAVA_OPTIONS=
  • set _JAVA_OPTIONS=
  • set JAVA_TOOL_OPTIONS=
  • ApacheJMeter.jar

and started launching the Jmeter with it. Had the same issue with SOAPUI, I added

  • set IBM_JAVA_OPTIONS=
  • set _JAVA_OPTIONS=
  • set JAVA_TOOL_OPTIONS=
  • SoapUI-5.5.0.exe

and worked again :)

This is because JVM is taken by other existing application that are already running their process in your machine. You can check it in your environmental variables

  • IBM_JAVA_OPTIONS=
  • _JAVA_OPTIONS=
  • JAVA_TOOL_OPTIONS=