< prev index next >

doc/building.html

Print this page
rev 52921 : 8233383: Various minor fixes
Reviewed-by: mbalao

*** 367,380 **** <h3 id="getting-jdk-binaries">Getting JDK binaries</h3> <p>JDK binaries for Linux, Windows and macOS can be downloaded from <a href="http://jdk.java.net">jdk.java.net</a>. An alternative is to download the <a href="http://www.oracle.com/technetwork/java/javase/downloads">Oracle JDK</a>. Another is the <a href="https://adoptopenjdk.net/">Adopt OpenJDK Project</a>, which publishes experimental prebuilt binaries for various platforms.</p> <p>On Linux you can also get a JDK from the Linux distribution. On apt-based distros (like Debian and Ubuntu), <code>sudo apt-get install openjdk-&lt;VERSION&gt;-jdk</code> is typically enough to install a JDK &lt;VERSION&gt;. On rpm-based distros (like Fedora and Red Hat), try <code>sudo yum install java-&lt;VERSION&gt;-openjdk-devel</code>.</p> <h2 id="external-library-requirements">External Library Requirements</h2> <p>Different platforms require different external libraries. In general, libraries are not optional - that is, they are either required or not used.</p> ! <p>If a required library is not detected by <code>configure</code>, you need to provide the path to it. There are two forms of the <code>configure</code> arguments to point to an external library: <code>--with-&lt;LIB&gt;=&lt;path&gt;</code> or <code>--with-&lt;LIB&gt;-include=&lt;path to include&gt; --with-&lt;LIB&gt;-lib=&lt;path to lib&gt;</code>. The first variant is more concise, but require the include files an library files to reside in a default hierarchy under this directory. In most cases, it works fine.</p> <p>As a fallback, the second version allows you to point to the include directory and the lib directory separately.</p> <h3 id="freetype">FreeType</h3> ! <p>FreeType2 from <a href="http://www.freetype.org/">The FreeType Project</a> is not required on any platform. The exception is on Unix-based platforms when configuring such that the build artifacts will reference a system installed library, rather than bundling the JDK’s own copy.</p> <ul> <li>To install on an apt-based Linux, try running <code>sudo apt-get install libfreetype6-dev</code>.</li> <li>To install on an rpm-based Linux, try running <code>sudo yum install freetype-devel</code>.</li> <li>To install on Solaris, try running <code>pkg install system/library/freetype-2</code>.</li> </ul> --- 367,380 ---- <h3 id="getting-jdk-binaries">Getting JDK binaries</h3> <p>JDK binaries for Linux, Windows and macOS can be downloaded from <a href="http://jdk.java.net">jdk.java.net</a>. An alternative is to download the <a href="http://www.oracle.com/technetwork/java/javase/downloads">Oracle JDK</a>. Another is the <a href="https://adoptopenjdk.net/">Adopt OpenJDK Project</a>, which publishes experimental prebuilt binaries for various platforms.</p> <p>On Linux you can also get a JDK from the Linux distribution. On apt-based distros (like Debian and Ubuntu), <code>sudo apt-get install openjdk-&lt;VERSION&gt;-jdk</code> is typically enough to install a JDK &lt;VERSION&gt;. On rpm-based distros (like Fedora and Red Hat), try <code>sudo yum install java-&lt;VERSION&gt;-openjdk-devel</code>.</p> <h2 id="external-library-requirements">External Library Requirements</h2> <p>Different platforms require different external libraries. In general, libraries are not optional - that is, they are either required or not used.</p> ! <p>If a required library is not detected by <code>configure</code>, you need to provide the path to it. There are two forms of the <code>configure</code> arguments to point to an external library: <code>--with-&lt;LIB&gt;=&lt;path&gt;</code> or <code>--with-&lt;LIB&gt;-include=&lt;path to include&gt; --with-&lt;LIB&gt;-lib=&lt;path to lib&gt;</code>. The first variant is more concise, but require the include files and library files to reside in a default hierarchy under this directory. In most cases, it works fine.</p> <p>As a fallback, the second version allows you to point to the include directory and the lib directory separately.</p> <h3 id="freetype">FreeType</h3> ! <p>FreeType2 from <a href="http://www.freetype.org/">The FreeType Project</a> is not required on any platform. The exception is on Unix-based platforms when configuring such that the build artifacts will reference a system installed library, rather than bundling the JDK's own copy.</p> <ul> <li>To install on an apt-based Linux, try running <code>sudo apt-get install libfreetype6-dev</code>.</li> <li>To install on an rpm-based Linux, try running <code>sudo yum install freetype-devel</code>.</li> <li>To install on Solaris, try running <code>pkg install system/library/freetype-2</code>.</li> </ul>
*** 431,441 **** <p>At least version 3.2 of GNU Bash must be used.</p> <h2 id="running-configure">Running Configure</h2> <p>To build the JDK, you need a &quot;configuration&quot;, which consists of a directory where to store the build output, coupled with information about the platform, the specific build machine, and choices that affect how the JDK is built.</p> <p>The configuration is created by the <code>configure</code> script. The basic invocation of the <code>configure</code> script looks like this:</p> <pre><code>bash configure [options]</code></pre> ! <p>This will create an output directory containing the configuration and setup an area for the build result. This directory typically looks like <code>build/linux-x64-normal-server-release</code>, but the actual name depends on your specific configuration. (It can also be set directly, see <a href="#using-multiple-configurations">Using Multiple Configurations</a>). This directory is referred to as <code>$BUILD</code> in this documentation.</p> <p><code>configure</code> will try to figure out what system you are running on and where all necessary build components are. If you have all prerequisites for building installed, it should find everything. If it fails to detect any component automatically, it will exit and inform you about the problem.</p> <p>Some command line examples:</p> <ul> <li><p>Create a 32-bit build for Windows with FreeType2 in <code>C:\freetype-i586</code>:</p> <pre><code>bash configure --with-freetype=/cygdrive/c/freetype-i586 --with-target-bits=32</code></pre></li> --- 431,441 ---- <p>At least version 3.2 of GNU Bash must be used.</p> <h2 id="running-configure">Running Configure</h2> <p>To build the JDK, you need a &quot;configuration&quot;, which consists of a directory where to store the build output, coupled with information about the platform, the specific build machine, and choices that affect how the JDK is built.</p> <p>The configuration is created by the <code>configure</code> script. The basic invocation of the <code>configure</code> script looks like this:</p> <pre><code>bash configure [options]</code></pre> ! <p>This will create an output directory containing the configuration and setup an area for the build result. This directory typically looks like <code>build/linux-x64-server-release</code>, but the actual name depends on your specific configuration. (It can also be set directly, see <a href="#using-multiple-configurations">Using Multiple Configurations</a>). This directory is referred to as <code>$BUILD</code> in this documentation.</p> <p><code>configure</code> will try to figure out what system you are running on and where all necessary build components are. If you have all prerequisites for building installed, it should find everything. If it fails to detect any component automatically, it will exit and inform you about the problem.</p> <p>Some command line examples:</p> <ul> <li><p>Create a 32-bit build for Windows with FreeType2 in <code>C:\freetype-i586</code>:</p> <pre><code>bash configure --with-freetype=/cygdrive/c/freetype-i586 --with-target-bits=32</code></pre></li>
< prev index next >