pquiring / javaforce

JavaForce library for building powerful Apps and Services (Native Bindings for Camera, OpenGL, ffmpeg). Includes VoIP stack, PLC I/O and many apps.
http://pquiring.github.io/javaforce
GNU Lesser General Public License v3.0
55 stars 24 forks source link
camera controls ffmpeg java linux macos opengl voip windows

JavaForce SDK

Version 68.0

Description

JavaForce (JF) is a Java library featuring:

Includes many apps built around the library such as jfPhone, jfVideo Creator, jfAudio, jfMusic, etc.

JF is also the core library in jfLinux, a Java infused Linux Operating system: https://github.com/pquiring/javaforce/tree/master/linux

JF is also used to create jfCraft, a Minecraft clone: https://github.com/pquiring/jfcraft

Folders

/ - main folder (run ant here to build /src) /src - the javaforce source files /lib - generated and dependancies jar files /native - native loaders with JNI bindings for FFmpeg, OpenGL, OpenCL, Camera /projects - source for all sub-projects /iso - scripts to build jfLinux iso (outdated) /linux - scripts to install JavaForce repo for Linux /windows - scripts to install JavaForce repo for Windows /utils - utility apps (jnlp)

Getting Started

First get some tools installed, all projects are built with Apache Ant (http://ant.apache.org): debian:apt install git ant fedora:yum install git ant windows:install git, OpenJDK and ant from various sources (msys2, cygwin, oracle, etc.) Before checking out the source make sure to configure line endings: linux/mac : git config --global core.autocrlf input windows : git config --global core.autocrlf true Checkout Javaforce and a specific version: git clone http://github.com/pquiring/javaforce cd javaforce git checkout tags/68.0 ant Next build the native launchers.

Building native loaders with native API (FFmpeg, OpenGL, OpenCL, Camera)

Native loaders are in /native JavaForce does not use java.exe, instead a custom loader is built, which includes additional native API using JNI. See readme.txt in each platform folder for more info.

Building jfLinux

After building Javaforce and the native components you can run package.sh to package everything. Supported distros : Debian, Fedora, Arch. FreeBSD is currently not supported (open issue if you would like to see FreeBSD packager task and repo created) All packages are stored in /repo and can then be processed and uploaded to a repo server. Packages are hosted on sourceforge.net which can be installed thur the jfLinux install process.

JavaForce Ant tasks:

get-ffmpeg-win64-bin : Download ffmpeg libraries for Win64 get-ffmpeg-win64-src : Download ffmpeg sources for Win64 (to build native loader) jre-base : pre-link JRE for creating native packages (msi, dmg) jre-base-desktop : pre-link JRE with desktop support jre-base-javac : pre-link JRE with java compiler support

Common Ant tasks:

compile : compile projects java files jar : build the projects main jar file depjars : copy dependant jar files into project folder run : execute program from command line (with debugging support enabled) javadoc : build javadoc api files deploy : build maven deployment artifacts (requires pom.xml) executable : build native launcher

Maven

The Maven repo is used to download dependancies using ant tasks. The mvn tool is currently not required. A pom.xml is supplied for JF but is missing dependancies for now, the minimum is included to create deployment artifacts.

Graal Support

JavaForce includes some support for building AOT executables using GraalVM (http://www.graalvm.org) To build a project using Graal use the following Ant Tasks. graalagent

Debugging

The native loaders in /bin enable JMX debugging support on port 9010. These loaders are used when you run an app with "ant run". From VisualVM you can connect to the JMX as localhost:9010 You can also enable debug support by adding DEBUG=true to the project .cfg file to have it enabled in the generated executable. This should be removed for any public release.

Requirements

License

JavaForce is licensed under the LGPL license which can be read in license.txt. The MSI installers show the Common Public License 1.0 which is acceptable as well. All third party libraries and tools each have their own licenses.

Enjoy!

Peter Quiring pquiring@gmail.com

Web : pquiring.github.io/javaforce

Git : github.com/pquiring/javaforce