Looking for the latest version? Download Tech Guide (19.8 kB)
Home / Toolkit / Windows
Name Modified Size Downloads / Week Status
Parent folder
Totals: 1 Item  
Application Build 2013-07-21 11 weekly downloads
1 Build a free-form project with sf3jswing-jigaxtended 1.1 Prerequisites 1.2 System Requirements 1.2.1 Windows configuration 1.2.2 Mac configuration 1.2.3 Linux configuration 1.2.4 Additional requirements 1.3 Download and extract jigaxtended and jxakernel 1.3.1 Get the stable version 1.3.2 To get the most recent version 1.4 Compile the kernel library with the ant default task (DO-lib) 1.5 Copy and paste sf3jswing-jxakernel/dist/YOUROS/unsigned/lib/lib-sf3jswing-jxakernel-YOUROS-YOURARCH.jar to lib/YOUROS/YOURARCH/. in sf3jswing-jigaxtended project 1.6 Edit build-YOUROS-YOURARCH.xml. 1.7 Configure template/build-extended-template.xml 1.8 Open a new "free-form project" (e.g. in Netbeans) 1.9 Configure the project for the IDE 1.9.1 Classpath .jar's 1.9.2 Resources files (natives, .properties list, animations, sounds, etc.) 1.10 Readme and License files locations and edition 2 JXA Free-Form projects "built-in" ant tasks 2.1 build.xml or build-osfamily-arch.xml 2.2 list of built-in targets in JXA Free-Form projects 2.2.1 compile 2.2.2 jar 2.2.3 run(*) 2.2.4 run-applet(*) 2.2.5 clean 2.2.6 DO-clean-root 2.2.7 javadoc 2.2.8 DO-src-pack 2.2.9 install 2.2.10 update-template (available from the JIGAXtended project) 2.2.11 DO-lib (available from the JXA Kernel project) 3 Test Units 3.1 sf3jswing-jxatest-unit 4 (*) NOTES 4.1 JXA Debugging System Properties 5 Developing JXA projects with Netbeans 5.1 Using the keytool 5.2 IMPORTANT NOTE about Applets 5.3 About code error checking and completion 5.4 Activating Netbeans Debugger within projects [edit] Build a free-form project with sf3jswing-jigaxtended [edit] Prerequisites If you want to go through this short summary, we strongly recommend to have a sample knowledge of the POSIX commands, JDK 1.5 or any higher, and compiling Java applications with the Ant tool (build.xml). [edit] System Requirements [edit]Windows configuration AMD or Intel 32 or 64 bits processors Microsoft Windows XP/Vista/7/8 or some more recent edition of the OS Java JDK 1.5 (1.6 or above is recommended) [edit]Mac configuration Intel (32 or 64 bits it doesn't matter) processors Mac OS X 10.5 (Leopard) or later Mac OS X includes the JDK by default (1.5 with Leopard, where 1.6 is on Snow Leopard and 1.7 on Lion) [edit]Linux configuration AMD64 or i386 processors: Some Linux OpenSuse or Ubuntu distribution (other builds are untested). The latest JDK package (or manually with correct PATH) must be installed [edit] Additional requirements Latest graphics drivers for AMD, Intel, Nvidia or any OpenGL capable devices. The Open JDK or any other open Java Development Kit may be compatible with the JigaXtended projects. All commands can be run from the command line (DOS or BASH). Android, iOS and other mobile devices are not supported. [edit] Download and extract jigaxtended and jxakernel [edit] Get the stable version download the sf3jswing-jigaxtended release 4.3.0 or higher download the latest sf3jswing-jxakernel release 1.1.2+ choose a folder where you have all read&write permissions extract sf3jswing packages there you should have in the same folder : - sf3jswing-jigaxtended-4.3.0/ build.xml among other files - sf3jswing-jxakernel-1.1.2/ build.xml among other files [edit] To get the most recent version Read about how to download from the git repository [edit] Compile the kernel library with the ant default task (DO-lib) browse to kernel folder cd sf3jswing-jxakernel-1.1.2 run the ant task DO-lib if you want to have a fresh build, do it so ant clean DO-lib if you cannot find the ant command, maybe Ant is not installed (especially on Linux systems). On Windows, it is packed with the IDE. generally this is enough, with DO-lib as the default task ant it should log a bit of java ant builder messages you should see at the bottom end before to get back the input control DO-lib: [mkdir] Created dir: /sf3jswing-jxakernel-1.1.2/dist/Mac/unsigned/lib [jar] Building jar: /sf3jswing-jxakernel-1.1.2/dist/Mac/unsigned/lib/lib-sf3jswing-jxakernel-Mac-ppc.jar BUILD SUCCESSFUL Total time: 30 seconds [edit] Copy and paste sf3jswing-jxakernel/dist/YOUROS/unsigned/lib/lib-sf3jswing-jxakernel-YOUROS-YOURARCH.jar to lib/YOUROS/YOURARCH/. in sf3jswing-jigaxtended project copy lib cd sf3jswing-jigaxtended-4.3.0 cp ../sf3jswing-jxakernel-1.1.2/dist/Mac/unsigned/lib/lib-sf3jswing-jxakernel-Mac-ppc.jar lib/Mac/ppc/. [edit] Edit build-YOUROS-YOURARCH.xml. Section below EXTENSIONS FILES AND *** NATIVE INSTALLER *** CONFIGURE HERE THE EXTENSIONS INSTALLER (USEFUL ON OPERATING SYSTEM RUNNING THE PLUGIN V. 1 (E.G. MAC OS X AND JAVA 5, OR SAFARI ON WINDOWS) you must specify the location on the web where your -might- upload the sf3jswing-jigaxtended-ext-...jar's you must specify ALL native libraries that you want the kernel to install before to launch your JApplet-or-JFrame app copy the necessary natives in the resources/properties/YOUROS/YOURARCH/natives/ folder as they will be merged into the file sf3jswing-jigaxtended-YOUROS-YOURARCH-ext-native...jar. [edit] Configure template/build-extended-template.xml EITHER IF YOU WANT A NEW PROJECT Section below CREATE NEW JXA PROJECT (THAT MAY BE A FRAME APPLICATION OR AN APPLET) THIS WILL OUTPUT TO THE PARENT FOLDER OF YOUR COPY OF JIGAXTENDED PROJECT <property name="new.project.template.name" value="a-new-project"/> EDIT HERE (see above) WITH THE NEW PROJECT NAME YOU WANT and use build.xml or build-YOUROS-YOURARCH.xml (no matter if you run another OS or arch) to run DO-new-jxa-project OR Section below UPDATE EXTERNAL EXISTING JXA PROJECT(S) EDIT HERE THE FOREACH LIST TO DO AUTOMATICALLY COPY THE EXTENSIONS.JARS INTO THE APPROPRIATE FOLDERS LOCATED IN THE LIST <property name="target-path" location=".."/> <target name="update-template" depends="DO-jar-extension" description="Will perform build of the extension and update the targeted template projects"> <foreach LIST HERE THE PROJECT NAMES YOU ARE UPDATING THEY MUST BE LOCATED AT THE PARENT FOLDER OF YOUR COPY OF JIGAXTENDED PROJECT list="some-projects,separated-by-commas-and,no-space" target="_update-template-task" param="template-project.name"> </foreach> </target> and use build.xml or build-YOUROS-YOURARCH.xml (no matter if you run another OS or arch) to run update-template [edit] Open a new "free-form project" (e.g. in Netbeans) you might edit the src/all/jxa/ package to begin [edit] Configure the project for the IDE [edit] Classpath .jar's It may be useful to configure the editor project Java classpath to look into resources/YOUROS/YOURARCH/*ext_signed.jar files and lib/YOUROS/YOURARCH/lib-sf3jswing-jxakernel-...jar. [edit] Resources files (natives, .properties list, animations, sounds, etc.) You can make the whole resources tree be visible in the project navigator by adding the resources/properties/ folder to the IDE project Java packages folders set. [edit] Readme and License files locations and edition Open the project base README and HOWTO text files for more information about build.xml's in JXA Free-form Projects. Open and edit resources/all/LICENSE and resources/all/NOTICE to include your own copyright. see that a tag of annotations like Copyright @PROJECTYEARS@ @COMPANYNAME@ includes your company name for the values you have specified in the build-jars.xml file. Run task DO-src-pack to obtain the distributing tarball (GZip compressed) and the final license files. [edit] JXA Free-Form projects "built-in" ant tasks [edit] build.xml or build-osfamily-arch.xml If you're familiar with ant, then you can skip to the list of tasks available to jxa free-form projects. When a JXA Free-form project is made by DO-new-jxa-project, the ant builder makes a project file structure that entirely relies on a set of XML files. Those XML files are the ANT build configuration files. As in any other configuration files, there are properties set to values and targets defining tasks that the ant tool can execute. On the command line, ant is very easy to invoke : ant jar or ant -f myProject/build.xml DO-clean-root for more infos see ant manual; also, there is a extension pack for ant called [ant-contrib.sourceforge.net/|ant-contrib] (it provides easy access to script with ant targets). With the help of an IDE you can see all tasks available when browsing around any of the build.xml's. See Running ANT targets from NetBeans IDE for instance ! [edit] list of built-in targets in JXA Free-Form projects [edit] compile compiles all source files (src/all + src/osfamily) into binaries (bin/) [edit] jar packs all binaries (bin/*.class) and resources into .jar zipped packages (dist/osfamily/unsigned) before to sign them (dist/osfamily/applet). [edit] run(*) runs the .jar with the AntFrame you specified as the -antframe argument in the build-os-arch.xml application.run.params. [edit] run-applet(*) runs the .jar with the AntApplet in Appletviewer you specified as the -antapplet argument in the build-os-arch.xml applet.run.params. (notice : if you need access to some more Security Permissions, edit the JavaSecurityPolicy file !) [edit] clean erases all files in dist/osfamily/ and bin/ folders. [edit] DO-clean-root erases all files in dist/ folder (all os builds) [edit] javadoc performs a validation of /** documentation in .java files */ and builds the JavaDoc for the current project (dist/doc/) [edit] DO-src-pack gathers all files excepting dist/ and bin/ folders to compress them into a tarball (dist/tarball) there are also some files added aside the tarball : *.spec *.changes *.dsc debian.*, these files are used by the RPM-DEB package builders (e.g. OpenSuSE.org Build Service). [edit] install platform specific bundle linux users will have the project unsigned jar's copied into /usr/share/games/nameoftheproject and an executable into /usr/games named as the project name. NOTICE : the project name MUST BE low-capitalized (debian rules) in order to be used by the linux systems. mac os users will have a nameoftheproject.app application bundle built in the dist/Mac/applet folder. windows users will have a nameoftheproject.exe and nameoftheproject_debug.exe in the dist/Windows/applet folder that MUST STAY IN THE SAME FOLDER AS THE JAR's to run properly (classpath issues). [edit] update-template (available from the JIGAXtended project) cleans, builds and copies *signed.jar and lib-sf3jswing-jxakernel-...jar to the corresponding operating system project resources and lib folders in the projects listed in sf3jswing-jigaxtended/template/build-extended-template.xml . Use it when you update the JIGAXtended API source code, resources or lib folder. [edit] DO-lib (available from the JXA Kernel project) cleans, builds the lib-sf3jswing-jxakernel-...jar (unsigned) into the sf3jswing-jxakernel/dist/.../unsigned folder. Use it if you updated the sf3jswing-jxakernel sources, resources or lib folder. Then copy the dist/.../unsigned/lib-...jar to the lib/yourOS/yourArch folder of your project or JIGAxtended lib/yourOS/yourArch for further updating the templates. [edit] Test Units [edit] sf3jswing-jxatest-unit This is a JXA free-form project, that is made to test the whole JXA API engine (Swing UI, I/O processes, multi-threading, Open GL (through LWJGL),...) on targeted systems. It has TestAntFrame and TestAntApplet to make test on both JFrame and JApplet release of Free-Form projects. It has been built with the DO-new-jxa-project sf3jswing-jigaxtended's target. The RenderingScene should run on everw compatible system. [edit] (*) NOTES [edit] JXA Debugging System Properties For using with run and run-applet applet edit build-jars.xml below target for the corresponding system : For target run : <target name="run" ....> <exec ... os.... > <arg line="-Dorg.lwjgl.util.Debug=true"/><!-- LWJGL debug //> <arg line="-Djxa.debugSys=true"/><!-- jxa kernel //> <arg line="-Djxa.debug=true"/><!-- global jxa api debug (casual info)//> <arg line="-Djxa.debugRender=true"/><!-- rendering (sprite, models,anims,..) //> <arg line="-Djxa.debugSPM=true"/> <!-- cache debug de/serialization //> <arg line="-Djxa.debugECL=true"/> <!-- Extensions classloader debug //> ... </exec> ...</target> For target run-applet it uses the -J-D options, for AppletViewer is running : <target name="run-applet" ....> <exec ... os.... > <arg line="-J-Dorg.lwjgl.util.Debug=true"/> <!-- LWJGL debug //> <arg line="-J-Djxa.debugSys=true"/> <!-- jxa kernel : USE IT FOR ANY ISSUE THAT CAN OCCUR AT THE FIRST STEPS OF LAUNCHING YOUR APP//> <arg line="-J-Djxa.debug=true"/> <!-- global jxa api debug (casual info and deep field dbugers)//> <arg line="-J-Djxa.debugRender=true"/> <!-- rendering (sprite, models,anims,..) (USE IT TO FIX UNWANTED GRAPHICS ERRORS)//> <arg line="-J-Djxa.debugSPM=true"/> <!-- cache debug de/serialization (USE IT TO FIX JAR SPRITES RESOURCES LOADING ISSUES)//> <arg line="-J-Djxa.debugECL=true"/> <!-- Extensions classloader debug (USE IT TO FIX CLASSPATH ISSUES) //> ... </exec> ...</target> Applets on the web also read parameters from the yourProjectName.html file : <APPLET archive="api/@PROJECTOSKERNELJAR@" code="@PROJECTAPPLETMAIN@" width=@PROJECTAPPLETWIDTH@ height=@PROJECTAPPLETHEIGHT@> Your browser does not support Java, so nothing is displayed.<!-- VOID DOUBLE RESOURCE LOADING, NOT USED WITH EXTENSION MECHANISM param name="jnlp_href" value="@PROJECTAPPLETJNLPHREF@"/--> <param name="jxa.debug" value="true"/> <param name="jxa.debugSys" value="true"/> <param name="jxa.debugOps" value="true"/> <param name="jxa.debugRender" value="true"/> <param name="jxa.debugVoid" value="false"/> <!-- some of deleted lines of debugging //> <param name="jxa.debugSPM" value="true"/> <param name="jxa.debugECL" value="true"/> <param name="antapplet" value="@PROJECTAPPLETANTAPPLET@"/> <!-- edit build-yourOS-arch.xml //> <param name="applet.classpath" value="@PROJECTAPPLETCLASSPATH@"/> <!-- edit build-yourOS-arch.xml //> <param name="antargs" value="@PROJECTAPPLETARGS@"/> <!-- edit build-yourOS-arch.xml //> <PARAM name="java_arguments" value="@PROJECTAPPLETARGS@"/> <!-- edit build-yourOS-arch.xml //> <param name="separate_jvm" value="true"/> [edit] Developing JXA projects with Netbeans [edit] Using the keytool To solve any "jarsigner error: java.lang.RuntimeException" when using building SF3JSWING : The file build-jars.xml contains the following first lines : <property name="username" value="b23prodtm"/> ...="keystore" location="../.keystore"/> ...="keystore-type" value="jks"/> ... ...="storepass" value="password"/> Something went wrong with the .keystore file that had to be found at two parent folders upside of your project. Run the Keytool of the JDK from the two-up parent folder "../../" : :\>keytool (to see if it is available, if not, you must set up the JDK properly again (easy), or adjust you PATH settings) Then use the Keytool to choose an alias/password (in that case you have to change the build-jars.xml properties) :\>keytool -anycommand -keystore .keystore Run :\>keytool -storepasswd -keystore .keystore -new yourpassword to change the password to yourpassword :\>keytool -anycommand -keystore .keystore -list You should see b23prodtm (SHA1) : TH:E:KE:Y:... [edit] IMPORTANT NOTE about Applets You may experience problem with the Signing Certificate if you are using various .keystore's among your machines. Please make copy of the .keystore you created to ensure the same private/public key is used to sign your .jars ! If you run a JFCApplet locally , you must manually enable the jxa.localApplet property (-Djxa.localApplet=true), otherwise you may experience some Class cast error with serialization. [edit] About code error checking and completion Netbeans provides a powerful code error checking and completion integrated tool, which is worth to get used to it. It's fast and pretty easy to detect source paths, even if you have multiple project instances opened at the same time. For example, by editing the project properties / source classpaths option panel, you will make the Java Editor look into each of the specified .jar for known classes that your project imports in .java files. You can also edit the Tools / Java Platforms option panel to add JDK or any other Sources paths to the Java IDE. E.g. you want to specify a global API Documentation folder, that helps you find the correct API function when you type in new lines of code. Note : sometimes the Java Editor doesn't refresh its classpaths or even don't find the API you have specified previously. To force a cache refresh, Close the project, restart Netbeans and re-open the project from the recently used project File menu. [edit] Activating Netbeans Debugger within projects Netbeans IDE provides a powerful debugger that can help developers to find/solve many bugs and issues. It's able to recognize breakpoints, VM Heap usage, variable monitoring, etc. But you'll have to make some changes in the JXA free-form project ide-file-targets.xml that is generated when you first run the debug interface [press Ctrl+F5 in Netbeans or try to run once the debug targets]. Set output classpath to target the bin/ project folder. Here's a sample of the sf3jswing-jxatest-unit project file : rename the first line project name to the actual name for your project (without -IDE), as in build-jars.xml : <project basedir=".." name="yourProjectName"> the following imports JXA build files; <import file="../build-${os.name}-${os.arch}.xml"/> <import file="../build-jars.xml"/> add clean and jar dependencies to the target, so that debugging ensures a fresh revision to be run : <target depends="-jdk-init, clean, jar" name="debug-nb"> this reads jar files from the JXA project dist/os.name folder (note the ${dist} ant-variable that was imported from build-${os.name}-${os.arch}.xml); <path id="cp"> <!-- TODO configure the runtime classpath for your project here: --> <fileset dir="${dist}"><include name="**/*.jar"/></fileset> </path> and provide specific parameters here for your project to run in the debugger. Refer to the file build-jars.xml,<target name=run>, of your current running project for specific parameters. <nbjpdastart addressproperty="jpda.address" name="sf3jswing-jxatest-unit" transport="dt_socket"> <classpath refid="cp"/> </nbjpdastart> <!-- TODO configure the main class for your project here: --> <java dir="${dist}" classname="${company.project.os.application.run.main}" fork="true"> <classpath refid="cp"/> <arg line="${company.project.os.application.run.args}"/> <jvmarg value="-ea"/> <jvmarg value="-Xdebug"/> <jvmarg value="-Xrunjdwp:transport=dt_socket,address=${jpda.address}"/> </java> For a JXA project that uses the AntApplet as main class you must copy the classpath parameter since the HTML file is not read from java executable for debugging and it looks like the following : Refer to the file build-jars.xml,<target name=run-applet>, of your current running project and the file yourProject.html file for specific parameters. Thanks to Netbeans for this tool.
Source: README, updated 2014-02-16