After you've set all the options in the other panels, then use the Build panel to create your installers, autoupdaters, and distribute your files to the web.
If a JVM file isn't installed: If any of the installers that can include the JVM are grayed out, then follow these instructions.
JExpress performs only the functions with a check mark next to them when you click the Build button. If there are any errors during the Build, look up each error number for suggestions and work arounds. After JExpress builds your installer, learn more about testing your system and the location of your distribution files. Click on the jump point or just page down to learn more about each setting on this panel.
Version
Project Type
If you'd like JExpress to layout your files in a directory tree, but not build an installer for those files, then select Subproject. Creating a subproject allows you to find classes for a program and then include those files in your installer project.
Subprojects are very useful when you have custom classes for JExpress. You can create a subproject that finds all the classes your custom classes use and then include the build directory of the subproject in the appropriate Custom directory.
If you simply want to jar your application, with a full manifest, then select JAR. If you create a JAR project that also finds classes automatically the JAR file's manifest will include the "Main-class" specification.
Whenever you select Subproject or Jar only you won't be able to select the type of installer or be able to upload the build directory's content online. JExpress builds the subproject and jar file locally on your system and then you can simply include the build directory in the installer project.
Be sure to build subprojects and jar only projects before you build the installer project. To learn more about building subprojects, review the tips on Multiple Related Projects or follow the step-by-step instructions.
Sign files
If you have a secure environment, you can configure JExpress to automatically sign the Windows native installers, cross platform installer, Java Web Start jar files, and launchers created for your java apps. You must supply a command which accepts the full pathname of the file to be signed on the command line and requires no user interaction.
Click on the Sign files button and enter a command that can run on the system where JExpress is running which signs the files. The full path to the file to be signed will be appended to the end of the command that you enter.
The commands must not need any user input. The commands should sign the files "in place". In other words, the signed file should have the same full path as the one provided to the script/batch file. You can learn more about signing EXE files from Microsoft.
Here's an example of the contents of a batch file that would sign Windows files using Microsoft's SignTool:
Note: SignCertFile specifies the signing certificate in a file.
There are many options so you should review Microsoft's docs to see which bet fit your situation.
Java Web Start jar files Java Web Start requires that all jar files be signed. Whatever command you enter in the "Cross platform/JWS" field be executed for each of the Java Web Start jar files.
Here's an example of the contents of a batch file that would sign a jar file:
You would store this command in a script or batch file and then enter the full path to the script/batch file as the Cross platform/JWS field.
Build directory
JExpress defaults the Build directory to a subdirectory in your JExpress directory that matches your project's name. You can leave this field blank if you want to use the default, and JExpress will name and create the directory when you name the project.
Learn more about where JExpress stores your distribution files after it builds your installer.
Erase all of the Build directory before using
IMPORTANT: If you check this box, then JExpress will delete all subdirectories. On Unix, be very careful about linking to other directories to the Build directory. For example, if you'd link the root to the Build directory and then check this field, JExpress could delete all files on the drive.
IMPORTANT: Regardless if this box is checked or not, JExpress deletes the standard subdirectories created under the Build directory (e.g., installers, howto).
Installers
If JExpress doesn't currently support a native installer for one of your desired platforms, then you can purchase a JExpress Installer Source license and adapt the native installer to the target OS.
When you add a check mark to the Windows checkbox that includes the JVM, then an EXE file is created which automatically detects whether the correct JVM is on your customers' systems, installs it if it is not, and then installs your application.
If you add a check mark to the Windows checkbox with no JVM, then an EXE file is created which verifies that the correct JVM is installed on your customers' systems, but only reports to the user if it isn't. If the installer finds the correct version of the JVM, then it proceeds to install your application.
Apple does not allow you to distribute the JVM, but all Mac OS's since 10.2 include the JVM.
If you add a check mark to the Mac checkbox with no JVM, then a gzip file is created which includes the Mac application inside. Your customers simply double click on the gzip file and if they don't have StuffIt configured to launch the app inside, they simply click on the icon to start the installer.
If you prefer to distribute a DMG file, you create your installers on a Mac, and you create your installers as an administrator, then you can create an ant target which takes the following steps after JExpress creates the Mac native installer.
When you add a check mark to the Linux checkbox that includes the JVM, then a binary file is created which automatically detects whether the correct JVM is on your customers' systems, installs it if it is not, and then installs your application.
If you add a check mark to the Linux checkbox with no JVM, then a binary file is created which verifies that the correct JVM is installed on your customers' systems, but only reports to the user if it isn't. If the installer finds the correct version of the JVM, then it proceeds to install your application.
When you add a check mark to the Solaris checkbox that includes the JVM, then a binary file is created which automatically detects whether the correct JVM is on your customers' systems, installs it if it is not, and then installs your application.
If you add a check mark to the Solaris checkbox with no JVM, then a binary file is created which verifies that the correct JVM is installed on your customers' systems, but only reports to the user if it isn't. If the installer finds the correct version of the JVM, then it proceeds to install your application.
You must use the Advanced interface for JExpress to create this type of installer. Use the Java Web Start sub-tab on the JVM panel to set the required JRE and the distribution URL.
All distributed jar files must be signed for the Java Web Start installer to work. You can configure JExpress to automatically sign your jar files with your key if 1) you have a key and 2) you have a script or batch file which takes the full path to the jar file on the command line and does not require any user input. Fill in the command in the Java Web Start sub-tab on the JVM panel.
Warning: Java Web Start has serious security risks and Sun appears to be abandoning it. We're not sure whether JExpress will continue to create a Java Web Start installer in the future.
Upload to web or ftp site
We recommend that you leave this field blank until you are successfully building your project. You might even want to test your installer offline before you add a check mark to this field to distribute it.
If you don't have any of the installer check boxes checked, and you do have this distribute box checked, then JExpress will simply verify that it's ready to build, and then upload all the files and subdirectories you have in your build directory to your ftp site.
Build
If there are any errors during the Build, look up each error number for suggestions and work arounds. After JExpress builds your installer, learn more about testing your system and the location of your distribution files.