Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Info

This page contains instructions for building OpenJFX 8u-dev for JDK 8u, as well as gradle examples, and is somewhat out of date.

If you are looking to build OpenJFX 9 or later, please see the main Building OpenJFX page.

Building a UI toolkit for many different platforms is a complex and challenging endeavorendeavour. It requires platform specific tools such as C compilers as well as portable tools like Gradle. Which tools must be installed differs from platform to platform. While the OpenJFX build system was designed to remove as many build hurdles as possible, it is often necessary to build native code and have the requisite compilers and toolchains installed. On Mac and Linux this is fairly easy, but setting up Windows is more difficult.

 


toc
Table of Contents
excludeThis page contains

Before you start

Do you really want to build OpenJFX? We would like you to, but there are some great community builds that may work for you too. JavaFX is bundled by default in desktop editions of JDK 8uNNN (and also in JDK 9).

...

  • Cygwin. Some packages to make sure are installed are:
    • openssh
    • bison
    • flex
    • g++
    • gperf
    • make
    • makedepend
    • mercurial
    • perl
    • zip
    • unzip
  • DirectX SDK June 2010. Microsoft DirectX SDK (June 2010) headers are required for building the JavaFX SDK. This DirectX SDK can be downloaded from Microsoft DirectX SDK (June 2010). If the link above becomes obsolete, the SDK can be found from the Microsoft Download Site (search with "DirectX SDK June 2010"). The location of this SDK will normally be set with the environment variable DXSDK_DIR at installation time. The default location is normally "C:/Program Files/Microsoft DirectX SDK (June 2010)/". If DXSDK_DIR is not set, the build process may look for it in the default location or "C:/DXSDK/".
  • Microsoft Visual Studio 10 SP1 (express edition works). The compiler and other tools are expected to reside in the location defined by the variableVS100COMNTOOLS which variable VS100COMNTOOLS which is set by the Microsoft Visual Studio installer.

...

To configure your Mac, make sure you have at least version 10.7 installed. Install the latest version of Xcode and that you have the developer tools installed. You can install them by using the menus within Xcode: XCode -> Preferences -> Downloads -> Components. Install the latest JDK 8 build. In order to build WebKit, you will also need to install QT 5CMake 3.2 (because WebKit uses QMake8(or higher).

 


Anchor
LinuxDesktopBuild
LinuxDesktopBuild
Linux

...

You will also need to install QT 5.2 cmake 3.8 (or higher) in order to build WebKit (because WebKit uses QmakeCMake). With Ubuntu 16, this will satisfy the requirements:

...

You must also install Gradle. We use Gradle 14.8 for the older 8-dev, although it is known to work with Gradle 3.1 (which is what we use to build FX for JDK 9). 

Note: gradle is available as a Ubuntu package, but check the version. This command should work after you set JAVA_HOME:

...

  • set JAVA_HOME and JDK_HOME to point to the top of the JDK 8 installation (that has jfxrt.jar removed).
  • set gradle 2.11 4.8(or higher) in your path
  • ensure Ant 1.8.2 is in your path

...

As zip bundles do not always preserve permissions, sometimes it is necessary to modify the file permissions to match the others in the JRE. In particular, check the permissions on the extracted native libraries.