README-builds.html

Sat, 25 Apr 2009 21:34:45 +0400

author
peterz
date
Sat, 25 Apr 2009 21:34:45 +0400
changeset 74
caba6a812b19
parent 51
60aab86966e9
child 90
60b818e5e4f9
child 105
8ca3d95b1ea3
permissions
-rw-r--r--

6591875: Nimbus Swing Look and Feel
Reviewed-by: jasper, ohair

     1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
     2 <html>
     3     <head>
     4         <title>OpenJDK Build README</title>
     5     </head>
     6     <body style="background-color:lightcyan">
     7         <!-- ====================================================== -->
     8         <table width="100%">
     9             <tr>
    10                 <td align="center">
    11                     <img alt="OpenJDK" 
    12                          src="http://openjdk.java.net/images/openjdk.png" 
    13                          width=256 />
    14                 </td>
    15             </tr>
    16             <tr>
    17                 <td align=center>
    18                     <h1>OpenJDK Build README</h1>
    19                 </td>
    20             </tr>
    21         </table>
    22         <!-- ------------------------------------------------------ --> 
    23         <hr>
    24         <h2><a name="introduction">Introduction</a></h2>
    25         <blockquote>
    26             <p>
    27             This README file contains build instructions for the 
    28             <a href="http://openjdk.java.net"  target="_blank">OpenJDK</a>.
    29             Building the source code for the 
    30             OpenJDK
    31             requires
    32             a certain degree of technical expertise.
    33         </blockquote>
    34         <!-- ------------------------------------------------------ -->
    35         <hr>
    36         <h2><a name="contents">Contents</a></h2>
    37         <blockquote>
    38             <ul>
    39                 <li><a href="#introduction">Introduction</a></li>
    40                 <li><a href="#MBE">Minimum Build Environments</a></li>
    41                 <li><a href="#SDBE">Specific Developer Build Environments</a></li>
    42                     <ul>
    43                         <li><a href="#fedora">Fedora Linux</a> </li>
    44                         <li><a href="#centos">CentOS Linux</a> </li>
    45                         <li><a href="#ubuntu">Ubuntu Linux</a> </li>
    46                     </ul>
    47                 <li><a href="#directories">Source Directory Structure</a> </li>
    48                 <li><a href="#building">Build Information</a>
    49                     <ul>
    50                         <li><a href="#gmake">GNU Make (<tt><i>gmake</i></tt>)</a> </li>
    51                         <li><a href="#linux">Basic Linux System Setup</a> </li>
    52                         <li><a href="#solaris">Basic Solaris System Setup</a> </li>
    53                         <li><a href="#windows">Basic Windows System Setup</a> </li>
    54                         <li><a href="#dependencies">Build Dependencies</a> </li>
    55                         <ul>
    56                             <li><a href="#bootjdk">Bootstrap JDK</a> </li>
    57                             <li><a href="#binaryplugs">Binary Plugs</a> </li>
    58                             <li><a href="#importjdk">Optional Import JDK</a> </li>
    59                             <li><a href="#ant">Ant</a> </li>
    60                             <li><a href="#cacerts">Certificate Authority File (cacert)</a> </li>
    61                             <li><a href="#compilers">Compilers</a> 
    62                                 <ul>
    63                                     <li><a href="#msvc">Microsoft Visual Studio</a> </li>
    64                                     <li><a href="#mssdk">Microsoft Platform SDK</a> </li>
    65                                     <li><a href="#gcc">Linux gcc/binutils</a> </li>
    66                                     <li><a href="#studio">Sun Studio</a> </li>
    67                                 </ul>
    68                             </li>
    69                             <li><a href="#zip">Zip and Unzip</a> </li>
    70                             <li><a href="#freetype">FreeType2 Fonts</a> </li>
    71                             <li><a href="#jibx">JIBX Libraries</a> </li>
    72                             <li>Linux and Solaris:
    73                                 <ul>
    74                                     <li><a href="#cups">CUPS Include files</a> </li>
    75                                 </ul>
    76                             </li>
    77                             <li>Linux only:
    78                                 <ul>
    79                                     <li><a href="#alsa">ALSA files</a> </li>
    80                                 </ul>
    81                             </li>
    82                             <li>Windows only:
    83                                 <ul>
    84                                     <li>Unix Command Tools (<a href="#cygwin">CYGWIN</a>)</li>
    85                                     <li><a href="#dxsdk">DirectX 9.0 SDK</a> </li>
    86                                 </ul>
    87                             </li>
    88                         </ul>
    89                     </ul>
    90                 </li>
    91                 <li><a href="#creating">Creating the Build</a> </li>
    92                 <li><a href="#testing">Testing the Build</a> </li>
    93                 <li><a href="#variables">Environment/Make Variables</a></li>
    94                 <li><a href="#troubleshooting">Troubleshooting</a></li>
    95             </ul>
    96         </blockquote>
    97         <!-- ------------------------------------------------------ -->
    98         <hr>
    99         <h2><a name="MBE">Minimum Build Environments</a></h2>
   100         <blockquote>
   101             This file often describes specific requirements for what we call the
   102             "minimum build environments" (MBE) for this 
   103 	    specific release of the JDK,
   104             Building with the MBE will generate the most compatible
   105             bits that install on, and run correctly on, the most variations
   106             of the same base OS and hardware architecture.
   107             These usually represent what is often called the
   108             least common denominator platforms.
   109             It is understood that most developers will NOT be using these 
   110             specific platforms, and in fact creating these specific platforms
   111             may be difficult due to the age of some of this software.
   112             <p>
   113             The minimum OS and C/C++ compiler versions needed for building the
   114             OpenJDK:
   115             <p>
   116             <table border="1">
   117                 <thead>
   118                     <tr>
   119                         <th>Base OS and Architecture</th>
   120                         <th>OS</th>
   121                         <th>C/C++ Compiler</th>
   122                     </tr>
   123                 </thead>
   124                 <tbody>
   125                     <tr>
   126                         <td>Linux X86 (32-bit)</td>
   127                         <td>Fedora 9</td>
   128                         <td>gcc 4 </td>
   129                     </tr>
   130                     <tr>
   131                         <td>Linux X64 (64-bit)</td>
   132                         <td>Fedora 9</td>
   133                         <td>gcc 4 </td>
   134                     </tr>
   135                     <tr>
   136                         <td>Solaris SPARC (32-bit)</td>
   137                         <td>Solaris 10 + patches 
   138                             <br>
   139                             See <a href="http://sunsolve.sun.com/pub-cgi/show.pl?target=patches/JavaSE" target="_blank">
   140                             SunSolve</a> for patch downloads.
   141                         </td>
   142                         <td>Sun Studio 12</td>
   143                     </tr>
   144                     <tr>
   145                         <td>Solaris SPARCV9 (64-bit)</td>
   146                         <td>Solaris 10 + patches
   147                             <br>
   148                             See <a href="http://sunsolve.sun.com/pub-cgi/show.pl?target=patches/JavaSE" target="_blank">
   149                             SunSolve</a> for patch downloads.
   150                         </td>
   151                         <td>Sun Studio 12</td>
   152                     </tr>
   153                     <tr>
   154                         <td>Solaris X86 (32-bit)</td>
   155                         <td>Solaris 10 + patches
   156                             <br>
   157                             See <a href="http://sunsolve.sun.com/pub-cgi/show.pl?target=patches/JavaSE" target="_blank">
   158                             SunSolve</a> for patch downloads.
   159                         </td>
   160                         <td>Sun Studio 12</td>
   161                     </tr>
   162                     <tr>
   163                         <td>Solaris X64 (64-bit)</td>
   164                         <td>Solaris 10 + patches
   165                             <br>
   166                             See <a href="http://sunsolve.sun.com/pub-cgi/show.pl?target=patches/JavaSE" target="_blank">
   167                             SunSolve</a> for patch downloads.
   168                         </td>
   169                         <td>Sun Studio 12</td>
   170                     </tr>
   171                     <tr>
   172                         <td>Windows X86 (32-bit)</td>
   173                         <td>Windows XP</td>
   174                         <td>Microsoft Visual Studio C++ 2008 Standard Edition</td>
   175                     </tr>
   176                     <tr>
   177                         <td>Windows X64 (64-bit)</td>
   178                         <td>Windows Server 2003 - Enterprise x64 Edition</td>
   179                         <td>Microsoft Platform SDK - April 2005</td>
   180                     </tr>
   181                 </tbody>
   182             </table>
   183 	    <p>
   184 	    These same sources do indeed build on many more systems than the
   185 	    above older generation systems, again the above is just a minimum.
   186 	    <p>
   187 	    Compilation problems with newer or different C/C++ compilers is a
   188 	    common problem.
   189 	    Similarly, compilation problems related to changes to the
   190 	    <tt>/usr/include</tt> or system header files is also a
   191 	    common problem with newer or unreleased OS versions.
   192 	    Please report these types of problems as bugs so that they
   193 	    can be dealt with accordingly.
   194         </blockquote>
   195         <!-- ------------------------------------------------------ -->
   196         <hr>
   197         <h2><a name="SDBE">Specific Developer Build Environments</a></h2>
   198         <blockquote>
   199             We won't be listing all the possible environments, but
   200             we will try to provide what information we have available to us.
   201         </blockquote>
   202         <!-- ------------------------------------------------------ -->
   203         <h3><a name="fedora">Fedora 9</a></h3>
   204         <blockquote>
   205             After installing
   206             <a href="http://www.fedoraproject.org/">Fedora 9</a>
   207             you need to make sure you have
   208             the "Software Development" bundle installed, plus the
   209             following packages:
   210             <blockquote>
   211                 <ul>
   212                     <li>cups devel: Cups Development Package</li>
   213                     <li>freetype 2.3+ devel: Freetype 2.3 Development Package</li>
   214                     <li>hg: Mercurial, if you need to clone or manage source repositories</li>
   215                     <li>ksh: May be needed when using <tt>webrev</tt></li>
   216                 </ul>
   217             </blockquote>
   218             <p>
   219             Always a good idea to do a complete Software Update/Refresh
   220             after you get all the packages installed.
   221         </blockquote>
   222         <!-- ------------------------------------------------------ -->
   223         <h3><a name="centos">CentOS 5.2</a></h3>
   224         <blockquote>
   225             After installing
   226             <a href="http://www.centos.org/">CentOS 5.2</a>
   227             you need to make sure you have
   228             the following Development bundles installed:
   229             <blockquote>
   230                 <ul>
   231                     <li>Development Libraries</li>
   232                     <li>Development Tools</li>
   233                     <li>Java Development</li>
   234                     <li>X Software Development</li>
   235                 </ul>
   236             </blockquote>
   237             <p>
   238             Plus the following packages:
   239             <blockquote>
   240                 <ul>
   241                     <li>cups devel: Cups Development Package</li>
   242                     <li>alsa devel: Alsa Development Package</li>
   243                     <li>ant: Ant Package</li>
   244                     <li>Xi devel: libXi.so Development Package</li>
   245                 </ul>
   246             </blockquote>
   247             <p>
   248             The freetype 2.3 packages don't seem to be available,
   249             but the freetype 2.3 sources can be downloaded, built,
   250             and installed easily enough from
   251             <a href="http://downloads.sourceforge.net/freetype">
   252             the freetype site</a>.
   253             Build and install with something like:
   254             <blockquote>
   255                 <tt>./configure && make && sudo -u root make install</tt>
   256             </blockquote>
   257             <p>
   258             Mercurial packages could not be found easily, but a Google
   259             search should find ones, and they usually include Python if
   260             it's needed.
   261         </blockquote>
   262         <!-- ------------------------------------------------------ -->
   263         <h3><a name="ubuntu">Ubuntu</a></h3>
   264         <blockquote>
   265             In addition to needing the Bootstrap JDK and the Binary Plugs, 
   266             when building on Ubuntu you will need to
   267             make sure certain packages are installed.
   268             In particular, certain X11 packages, make, m4, gawk, gcc 4, 
   269             binutils, cups, freetype
   270             and alsa.
   271             <!-- ------------------------------------------------------ -->
   272             <h4>Ubuntu 6.06</h4>
   273             <p>
   274             The following list of packages for Ubuntu 6.06 is a working set that
   275             does appear to work. 
   276             <p>
   277             <b>Note that it's quite possible that some of these
   278                 packages are not required, so anyone discovering that some of the
   279                 packages listed below are NOT required,
   280                 please let the
   281                 OpenJDK
   282             team know.</b>
   283             <p>
   284             All the packages below can be installed with the
   285             Synaptic Package manager provided with the base Ubuntu 6.06 release.
   286             <blockquote>
   287                 <ul>
   288                     <li>binutils (2.16.1cvs20060117-1ubuntu2.1)</li>
   289                     <li>cpp (4:4.0.3-1)</li>
   290                     <li>cpp-4.0 (4.0.3-1ubuntu5)</li>
   291                     <li>libfreetype6-dev</li>
   292                     <li>g++ (4:4.0.3-1)</li>
   293                     <li>g++-4.0 (4.0.3-1ubuntu5)</li>
   294                     <li>gawk (1:3.1.5-2build1)</li>
   295                     <li>gcc (4:4.0.3-1)</li>
   296                     <li>gcc-4.0 (4.0.3-1ubuntu5)</li>
   297                     <li>libasound2-dev (1.0.10-2ubuntu4)</li>
   298                     <li>libc6 (2.3.6-0ubuntu20) to 2.3.6-0ubuntu20.4</li>
   299                     <li>libc6-dev (2.3.6-0ubuntu20.4)</li>
   300                     <li>libc6-i686 (2.3.6-0ubuntu20) to 2.3.6-0ubuntu20.4</li>
   301                     <li>libcupsys2-dev (1.2.2-0ubuntu0.6.06)</li>
   302                     <li>libgcrypt11-dev (1.2.2-1)</li>
   303                     <li>libgnutls-dev (1.2.9-2ubuntu1.1)</li>
   304                     <li>libgnutls12 (1.2.9-2ubuntu1) to 1.2.9-2ubuntu1.1</li>
   305                     <li>libgpg-error-dev (1.1-4)</li>
   306                     <li>libice-dev (2:1.0.0-0ubuntu2)</li>
   307                     <li>liblockfile1 (1.06.1)</li>
   308                     <li>libopencdk8-dev (0.5.7-2)</li>
   309                     <li>libpopt-dev (1.7-5)</li>
   310                     <li>libsm-dev (2:1.0.0-0ubuntu2)</li>
   311                     <li>libstdc++6-4.0-dev (4.0.3-1ubuntu5)</li>
   312                     <li>libtasn1-2-dev (0.2.17-1ubuntu1)</li>
   313                     <li>libx11-dev (2:1.0.0-0ubuntu9)</li>
   314                     <li>libxau-dev (1:1.0.0-0ubuntu4)</li>
   315                     <li>libxaw-headers (2:1.0.1-0ubuntu3)</li>
   316                     <li>libxaw7-dev (2:1.0.1-0ubuntu3)</li>
   317                     <li>libxdmcp-dev (1:1.0.0-0ubuntu2)</li>
   318                     <li>libxext-dev (2:1.0.0-0ubuntu4)</li>
   319                     <li>libxi-dev (2:1.0.0-0ubuntu3) </li>
   320                     <li>libxmu-dev (2:1.0.0-0ubuntu3)</li>
   321                     <li>libxmu-headers (2:1.0.0-0ubuntu3)</li>
   322                     <li>libxmuu-dev (2:1.0.0-0ubuntu3)</li>
   323                     <li>libxp-dev (6.8.2-11ubuntu2)</li>
   324                     <li>libxpm-dev (1:3.5.4.2-0ubuntu3)</li>
   325                     <li>libxrandr-dev (1:1.1.0.2-0ubuntu4)</li>
   326                     <li>libxt-dev (1:1.0.0-0ubuntu3)</li>
   327                     <li>libxtrap-dev (2:1.0.0-0ubuntu2)</li>
   328                     <li>libxtst-dev (2:1.0.1-0ubuntu2)</li>
   329                     <li>libxv-dev (2:1.0.1-0ubuntu3)</li>
   330                     <li>linux-kernel-headers (2.6.11.2-0ubuntu18)</li>
   331                     <li>m4 (1.4.4-1)</li>
   332                     <li>make (3.80+3.81.b4-1)</li>
   333                     <li>ssl-cert (1.0.13)</li>
   334                     <li>x-dev (7.0.4-0ubuntu2)</li>
   335                     <li>x11proto-core-dev (7.0.4-0ubuntu2)</li>
   336                     <li>x11proto-input-dev (1.3.2-0ubuntu2)</li>
   337                     <li>x11proto-kb-dev (1.0.2-0ubuntu2)</li>
   338                     <li>x11proto-randr-dev (1.1.2-0ubuntu2)</li>
   339                     <li>x11proto-record-dev (1.13.2-0ubuntu2)</li>
   340                     <li>x11proto-trap-dev (3.4.3-0ubuntu2)</li>
   341                     <li>x11proto-video-dev (2.2.2-0ubuntu2)</li>
   342                     <li>x11proto-xext-dev (7.0.2-0ubuntu2)</li>
   343                     <li>xlibs-dev (7.0.0-0ubuntu45)</li>
   344                     <li>zlib1g-dev (1:1.2.3-6ubuntu4)</li>
   345                 </ul>
   346             </blockquote>
   347             <!-- ------------------------------------------------------ -->
   348             <h4>Ubuntu 7.04</h4>
   349             <p>
   350             Using the Synaptic Package Manager, download the following
   351             packages (double indented packages are automatically aquired
   352             due to package dependencies):
   353             <blockquote>
   354                 <ul>
   355                     <li>build-essential</li>
   356                     <ul>
   357                         <li>dpkg-dev</li>
   358                         <li>g++</li>
   359                         <li>g++-4.1</li>
   360                         <li>libc6-dev</li>
   361                         <li>libstdc++6.4.1-dev</li>
   362                         <li>linux-libc-dev</li>
   363                     </ul>
   364                     <li>gawk</li>
   365                     <li>m4</li>
   366                     <li>libasound2-dev</li>
   367                     <li>libcupsys2-dev</li>
   368                     <ul>
   369                         <li>libgcrypt11-dev</li>
   370                         <li>lgnutls-dev</li>
   371                         <li>libgpg-error-dev</li>
   372                         <li>liblzo-dev</li>
   373                         <li>libopencdk8-dev</li>
   374                         <li>libpopt-dev</li>
   375                         <li>libtasn1-3-dev</li>
   376                         <li>zlib1g-dev</li>
   377                     </ul>
   378                     <li>sun-java6-jdk</li>
   379                     <ul>
   380                         <li>java-common</li>
   381                         <li>libltdl3</li>
   382                         <li>odbcinst1debian1</li>
   383                         <li>sun-java6-bin</li>
   384                         <li>sun-java6-jre</li>
   385                         <li>unixodbc</li>
   386                     </ul>
   387                     <li>xlibs-dev</li>
   388                     <ul>
   389                         <li>(many)</li>
   390                     </ul>
   391                     <li>x11proto-print-dev</li>
   392                     <li>libxaw7-dev</li>
   393                     <ul>
   394                         <li>libxaw-headers</li>
   395                     </ul>
   396                     <li>libxp-dev</li>
   397                     <li>libfreetype6-dev</li>
   398                 </ul>
   399             </blockquote>
   400         </blockquote>
   401         <!-- ------------------------------------------------------ -->
   402         <hr>
   403         <h2><a name="directories">Source Directory Structure</a></h2>
   404         <blockquote>
   405             <p>
   406             The source code for the OpenJDK is delivered in a set of
   407             directories:
   408             <tt>hotspot</tt>, 
   409             <tt>langtools</tt>, 
   410             <tt>corba</tt>, 
   411             <tt>jaxws</tt>, 
   412             <tt>jaxp</tt>, 
   413             and
   414             <tt>jdk</tt>.
   415             The <tt>hotspot</tt> directory contains the source code and make
   416             files for building the OpenJDK Hotspot Virtual Machine. 
   417             The <tt>langtools</tt> directory contains the source code and make
   418             files for building the OpenJDK javac and language tools.
   419             The <tt>corba</tt> directory contains the source code and make
   420             files for building the OpenJDK Corba files.
   421             The <tt>jaxws</tt> directory contains the source code and make
   422             files for building the OpenJDK JAXWS files.
   423             The <tt>jaxp</tt> directory contains the source code and make
   424             files for building the OpenJDK JAXP files.
   425             The <tt>jdk</tt> directory contains the source code and make files for
   426             building the OpenJDK runtime libraries and misc files.
   427             The top level <tt>Makefile</tt>
   428             is used to build the entire OpenJDK.
   429         </blockquote>
   430         <!-- ------------------------------------------------------ -->
   431         <hr>
   432         <h2><a name="building">Build Information</a></h2>
   433         <blockquote>
   434             Building the OpenJDK
   435             is done with a <tt><i>gmake</i></tt>
   436             command line and various
   437             environment or make variable settings that direct the make rules
   438             to where various components have been installed.
   439             Where possible the makefiles will attempt to located the various
   440             components in the default locations or any component specific 
   441             variable settings.
   442             When the normal defaults fail or components cannot be found,
   443             the various
   444             <tt>ALT_*</tt> variables (alternates)
   445             can be used to help the makefiles locate components.
   446             <p>
   447             Refer to the bash/sh/ksh setup file
   448             <tt>jdk/make/jdk_generic_profile.sh</tt>
   449             if you need help in setting up your environment variables.
   450             A build could be as simple as:
   451             <blockquote>
   452                 <pre><tt>
   453                 bash
   454                 . jdk/make/jdk_generic_profile.sh
   455                 <i>gmake</i> sanity &amp;&amp; <i>gmake</i>
   456                 </tt></pre>
   457             </blockquote>
   458             <p>
   459             Of course ksh or sh would work too.
   460             But some customization will probably be necessary.
   461             The <tt>sanity</tt> rule will make some basic checks on build
   462             dependencies and generate appropriate warning messages
   463             regarding missing, out of date, or newer than expected components
   464             found on your system.
   465         </blockquote>
   466         <!-- ------------------------------------------------------ -->
   467         <hr>
   468         <h3><a name="gmake">GNU make (<tt><i>gmake</i></tt>)</a></h3>
   469         <blockquote>
   470             The Makefiles in the OpenJDK are only valid when used with the 
   471             GNU version of the utility command <tt>make</tt>
   472             (<tt><i>gmake</i></tt>).
   473             A few notes about using GNU make:
   474             <ul>
   475                 <li>
   476                     In general, you need GNU make version 3.78.1 or newer.
   477                 </li>
   478                 <li>
   479                     Place the location of the GNU make binary in the <tt>PATH</tt>. 
   480                 </li>
   481                 <li>
   482                     <strong>Linux:</strong>
   483                     The <tt>/usr/bin/make</tt> command should work fine for you.
   484                 </li>
   485                 <li>
   486                     <strong>Solaris:</strong>
   487                     Do NOT use <tt>/usr/bin/make</tt> on Solaris.
   488                     If your Solaris system has the software
   489                     from the Solaris Companion CD installed, 
   490                     you should use <tt>gmake</tt>
   491                     which will be located in either the <tt>/opt/sfw/bin</tt> or 
   492                     <tt>/usr/sfw/bin</tt> directory.
   493                     In more recent versions of Solaris GNU make can be found
   494                     at <tt>/usr/bin/gmake</tt>. 
   495                 </li>
   496                 <li>
   497                     <strong>Windows:</strong>
   498                     Make sure you start your build inside a bash/sh/ksh shell.
   499                     <br>
   500                     <b>WARNING:</b> Watch out for make version 3.81, it may
   501                     not work due to a lack of support for MS-DOS drive letter paths
   502                     like <tt>C:/</tt> or <tt>C:\</tt>.
   503                     Use a 3.80 version, or find a newer
   504                     version that has this problem fixed.
   505                     The older 3.80 version of make.exe can be downloaded with this
   506                     <a href="http://cygwin.paracoda.com/release/make/make-3.80-1.tar.bz2" target="_blank">
   507                     link</a>.
   508                     Use of this older 3.80 make.exe may require that you install the
   509                     libintl2.dll library or libintl2 cygwin package which is
   510                     no longer installed by default by the cygwin installer.
   511                     <br>
   512                     Also see the
   513                     <a href="http://developer.mozilla.org/en/docs/Windows_build_prerequisites_using_cygwin#make" target="_blank">
   514                     mozilla developer center</a>
   515                     on this topic.
   516                     <br>
   517                     It's hoped that when make 3.82 starts shipping in a future cygwin
   518                     release that this MS-DOS path issue will be fixed.
   519                     In addition to the above 3.80 make.exe you can download 
   520                     this
   521                     <a href="http://www.cmake.org/files/cygwin/make.exe">
   522                     www.cmake.org make.exe</a> which will not have a libintl2.dll
   523                     dependency.
   524                 </li>
   525             </ul>
   526             <p>
   527             Information on GNU make, and access to ftp download sites, are
   528             available on the
   529             <a href="http://www.gnu.org/software/make/make.html" target="_blank">
   530                 GNU make web site
   531             </a>.
   532             The latest source to GNU make is available at
   533             <a href="http://ftp.gnu.org/pub/gnu/make/" target="_blank">
   534             ftp.gnu.org/pub/gnu/make/</a>.
   535         </blockquote>
   536         <!-- ------------------------------------------------------ -->
   537         <hr>
   538         <h3><a name="linux">Basic Linux System Setup</a></h3>
   539         <blockquote>
   540             <strong>i586 only:</strong>
   541             The minimum recommended hardware for building the Linux version
   542             is a Pentium class processor or better, at least 256 MB of RAM, and
   543             approximately 1.5 GB of free disk space.
   544             <p> 
   545             <strong>X64 only:</strong>
   546             The minimum recommended hardware for building the Linux
   547             version is an AMD Opteron class processor, at least 512 MB of RAM, and
   548             approximately 4 GB of free disk space.
   549             <p> 
   550             The build will use the tools contained in 
   551             <tt>/bin</tt> and 
   552             <tt>/usr/bin</tt>
   553             of a standard installation of the Linux operating environment. 
   554             You should ensure that these directories are in your 
   555             <tt>PATH</tt>.
   556             <p>
   557             Note that some Linux systems have a habit of pre-populating
   558             your environment variables for you, for example <tt>JAVA_HOME</tt>
   559             might get pre-defined for you to refer to the JDK installed on
   560             your Linux system. 
   561             You will need to unset <tt>JAVA_HOME</tt>.
   562             It's a good idea to run <tt>env</tt> and verify the
   563             environment variables you are getting from the default system
   564             settings make sense for building the 
   565             OpenJDK.
   566         </blockquote>
   567         <!-- ------------------------------------------------------ -->
   568         <h4><a name="linux_checklist">Basic Linux Check List</a></h4>
   569         <blockquote>
   570             <ol>
   571                 <li>
   572                     Install the
   573                     <a href="#bootjdk">Bootstrap JDK</a>, set
   574                     <tt><a href="#ALT_BOOTDIR">ALT_BOOTDIR</a></tt>.
   575                 </li>
   576                 <li>
   577                     Install the
   578                     <a href="#binaryplugs">Binary Plugs</a>, set
   579                     <tt><a href="#ALT_BINARY_PLUGS_PATH">ALT_BINARY_PLUGS_PATH</a></tt>.
   580                 </li>
   581                 <li>
   582                     <a href="#importjdk">Optional Import JDK</a>, set
   583                     <tt><a href="#ALT_JDK_IMPORT_PATH">ALT_JDK_IMPORT_PATH</a></tt>.
   584                 </li>
   585                 <li>
   586                     Install or upgrade the <a href="#freetype">FreeType development
   587                     package</a>.
   588                 </li>
   589                 <li>
   590                     Install the
   591                     <a href="#jibx">JIBX Libraries</a>, set
   592                     <tt><a href="#ALT_JIBX_LIBS_PATH">ALT_JIBX_LIBS_PATH</a></tt>.
   593                 </li>
   594                 <li>
   595                     Install
   596                     <a href="#ant">Ant</a>, 
   597                     make sure it is in your PATH.
   598                 </li>
   599             </ol>
   600         </blockquote>
   601         <!-- ------------------------------------------------------ -->
   602         <hr>
   603         <h3><a name="solaris">Basic Solaris System Setup</a></h3>
   604         <blockquote>
   605             The minimum recommended hardware for building the
   606             Solaris SPARC version is an UltraSPARC with 512 MB of RAM. 
   607             For building
   608             the Solaris x86 version, a Pentium class processor or better and at
   609             least 512 MB of RAM are recommended. 
   610             Approximately 1.4 GB of free disk
   611             space is needed for a 32-bit build.
   612             <p>
   613             If you are building the 64-bit version, you should
   614             run the command "isainfo -v" to verify that you have a
   615             64-bit installation, it should say <tt>sparcv9</tt> or
   616             <tt>amd64</tt>.
   617             An additional 7 GB of free disk space is needed
   618             for a 64-bit build.
   619             <p> 
   620             The build uses the tools contained in <tt>/usr/ccs/bin</tt>
   621             and <tt>/usr/bin</tt> of a standard developer or full installation of
   622             the Solaris operating environment.
   623             <p> 
   624             Solaris patches specific to the JDK can be downloaded from the 
   625             <a href="http://sunsolve.sun.com/show.do?target=patches/JavaSE" target="_blank">
   626             SunSolve JDK Solaris patches download page</a>.
   627             You should ensure that the latest patch cluster for
   628             your version of the Solaris operating environment has also
   629             been installed.
   630         </blockquote>
   631         <!-- ------------------------------------------------------ -->
   632         <h4><a name="solaris_checklist">Basic Solaris Check List</a></h4>
   633         <blockquote>
   634             <ol>
   635                 <li>
   636                     Install the
   637                     <a href="#bootjdk">Bootstrap JDK</a>, set
   638                     <tt><a href="#ALT_BOOTDIR">ALT_BOOTDIR</a></tt>.
   639                 </li>
   640                 <li>
   641                     Install the
   642                     <a href="#binaryplugs">Binary Plugs</a>, set
   643                     <tt><a href="#ALT_BINARY_PLUGS_PATH">ALT_BINARY_PLUGS_PATH</a></tt>.
   644                 </li>
   645                 <li>
   646                     <a href="#importjdk">Optional Import JDK</a>, set
   647                     <tt><a href="#ALT_JDK_IMPORT_PATH">ALT_JDK_IMPORT_PATH</a></tt>.
   648                 </li>
   649                 <li>
   650                     Install the
   651                     <a href="#studio">Sun Studio Compilers</a>, set
   652                     <a href="#ALT_COMPILER_PATH"><tt>ALT_COMPILER_PATH</tt></a>.
   653                 </li>
   654                 <li>
   655                     Install the
   656                     <a href="#cups">CUPS Include files</a>, set
   657                     <tt><a href="#ALT_CUPS_HEADERS_PATH">ALT_CUPS_HEADERS_PATH</a></tt>.
   658                 </li>
   659                 <li>
   660                     Install the
   661                     <a href="#jibx">JIBX Libraries</a>, set
   662                     <tt><a href="#ALT_JIBX_LIBS_PATH">ALT_JIBX_LIBS_PATH</a></tt>.
   663                 </li>
   664                 <li>
   665                     Install
   666                     <a href="#ant">Ant</a>, 
   667                     make sure it is in your PATH.
   668                 </li>
   669             </ol>
   670         </blockquote>
   671         <!-- ------------------------------------------------------ -->
   672         <hr>
   673         <h3><a name="windows">Basic Windows System Setup</a></h3>
   674         <blockquote> 
   675             <strong>i586 only:</strong>
   676             The minimum recommended hardware for building the 32-bit or X86
   677             Windows version is an Pentium class processor or better, at least
   678             512 MB of RAM, and approximately 600 MB of free disk space.
   679             <strong>
   680                 NOTE: The Windows build machines need to use the
   681                 file system NTFS. 
   682                 Build machines formatted to FAT32 will not work 
   683                 because FAT32 doesn't support case-sensitivity in file names.
   684             </strong>
   685             <p> 
   686             <strong>X64 only:</strong>
   687             The minimum recommended hardware for building
   688             the Windows X64 version is an AMD Opteron class processor, at least 1
   689             GB of RAM, and approximately 10 GB of free disk space.
   690         </blockquote>
   691         <!-- ------------------------------------------------------ -->
   692         <h4><a name="paths">Windows Paths</a></h4>
   693         <blockquote>
   694             <strong>Windows:</strong>
   695             Note that GNU make is a historic utility and is based very
   696             heavily on shell scripting, so it does not tolerate the Windows habit
   697             of having spaces in pathnames or the use of the <tt>\</tt>characters in pathnames.
   698             Luckily on most Windows systems, you can use <tt>/</tt>instead of \, and
   699             there is always a 'short' pathname without spaces for any path that 
   700             contains spaces.
   701             Unfortunately, this short pathname can be somewhat dynamic and the
   702             formula is difficult to explain.
   703             You can use <tt>cygpath</tt> utility to map pathnames with spaces
   704             or the <tt>\</tt>character into the <tt>C:/</tt> style of pathname
   705             (called 'mixed'), e.g.
   706             <tt>cygpath -s -m "<i>path</i>"</tt>.
   707             <p>
   708             The makefiles will try to translate any pathnames supplied
   709             to it into the <tt>C:/</tt> style automatically.
   710             <p>
   711             Note that use of CYGWIN creates a unique problem with regards to
   712             setting <a href="#path"><tt>PATH</tt></a>. Normally on Windows
   713             the <tt>PATH</tt> variable contains directories
   714             separated with the ";" character (Solaris and Linux uses ":").
   715             With CYGWIN, it uses ":", but that means that paths like "C:/path"
   716             cannot be placed in the CYGWIN version  of <tt>PATH</tt> and
   717             instead CYGWIN uses something like <tt>/cygdrive/c/path</tt>
   718             which CYGWIN understands, but only CYGWIN understands.
   719             So be careful with paths on Windows.
   720         </blockquote>
   721         <!-- ------------------------------------------------------ -->
   722         <h4><a name="windows_checklist">Basic Windows Check List</a></h4>
   723         <blockquote>
   724             <ol>
   725                 <li>
   726                     Install the
   727                     <a href="#cygwin">CYGWIN product</a>. 
   728                 </li>
   729                 <li>
   730                     Install the 
   731                     <a href="#bootjdk">Bootstrap JDK</a>, set
   732                     <tt><a href="#ALT_BOOTDIR">ALT_BOOTDIR</a></tt>.
   733                 </li>
   734                 <li>
   735                     Install the
   736                     <a href="#binaryplugs">Binary Plugs</a>, set
   737                     <tt><a href="#ALT_BINARY_PLUGS_PATH">ALT_BINARY_PLUGS_PATH</a></tt>..
   738                 </li>
   739                 <li>
   740                     <a href="#importjdk">Optional Import JDK</a>, set
   741                     <tt><a href="#ALT_JDK_IMPORT_PATH">ALT_JDK_IMPORT_PATH</a></tt>.
   742                 </li>
   743                 <li>
   744                     Install the
   745                     <a href="#msvc">Microsoft Visual Studio Compilers</a> (32-bit).
   746                 </li>
   747                 <li>
   748                     Install the
   749                     <a href="#mssdk">Microsoft Platform SDK</a>.
   750                 </li>
   751                 <li>
   752                     Setup all environment variables for compilers 
   753                     (see <a href="#msvc">compilers</a>).
   754                 </li>
   755                 <li>
   756                     Install 
   757                     <a href="#dxsdk">Microsoft DirectX SDK</a>.
   758                 </li>
   759                 <li>
   760                     Install the
   761                     <a href="#jibx">JIBX Libraries</a>, set
   762                     <tt><a href="#ALT_JIBX_LIBS_PATH">ALT_JIBX_LIBS_PATH</a></tt>.
   763                 </li>
   764                 <li>
   765                     Install
   766                     <a href="#ant">Ant</a>, 
   767                     make sure it is in your PATH and set
   768                     <tt><a href="#ANT_HOME">ANT_HOME</a></tt>.
   769                 </li>
   770             </ol>
   771         </blockquote>
   772         <!-- ------------------------------------------------------ -->
   773         <hr>
   774         <h3><a name="dependencies">Build Dependencies</a></h3>
   775         <blockquote>
   776             Depending on the platform, the OpenJDK build process has some basic
   777             dependencies on components not part of the OpenJDK sources.
   778             Some of these are specific to a platform, some even specific to
   779             an architecture.
   780             Each dependency will have a set of ALT variables that can be set
   781             to tell the makefiles where to locate the component.
   782             In most cases setting these ALT variables may not be necessary
   783             and the makefiles will find defaults on the system in standard
   784             install locations or through component specific variables.
   785             <!-- ------------------------------------------------------ -->
   786             <h4><a name="bootjdk">Bootstrap JDK</a></h4>
   787             <blockquote>
   788                 All OpenJDK builds require access to the previously released 
   789                 JDK 6, this is often called a bootstrap JDK.
   790                 The JDK 6 binaries can be downloaded from Sun's 
   791                 <a href="http://java.sun.com/javase/1.6.0/download.html" target="_blank">JDK 6 download site</a>.
   792                 For build performance reasons
   793                 is very important that this bootstrap JDK be made available on the
   794                 local disk of the machine doing the build.
   795                 You should always set 
   796                 <tt><a href="#ALT_BOOTDIR">ALT_BOOTDIR</a></tt>
   797                 to point to the location of
   798                 the bootstrap JDK installation, this is the directory pathname
   799                 that contains a <tt>bin, lib, and include</tt>
   800                 It's also a good idea to also place its <tt>bin</tt> directory
   801                 in the <tt>PATH</tt> environment variable, although it's
   802                 not required.
   803                 <p>
   804                 <strong>Solaris:</strong>
   805                 Some pre-installed JDK images may be available to you in the
   806                 directory <tt>/usr/jdk/instances</tt>.
   807                 If you don't set
   808                 <tt><a href="#ALT_BOOTDIR">ALT_BOOTDIR</a></tt>
   809                 the makefiles will look in that location for a JDK it can use.
   810             </blockquote>
   811             <!-- ------------------------------------------------------ -->
   812             <h4><a name="binaryplugs">Binary Plugs</a></h4>
   813             <blockquote>
   814                 Not all of the source code that makes up the JDK is available
   815                 under an open-source license.
   816                 This is a temporary situation and these binary plugs will be
   817                 replaced with fully open source replacements as soon as possible.
   818                 So currently, in order to build a complete OpenJDK image,
   819                 you must first download and install the appropriate
   820                 binary plug bundles for the OpenJDK, go to the
   821                 <a href="http://openjdk.java.net" target="_blank">OpenJDK</a> site and select
   822                 the 
   823                 "<b>Bundles(7)</b>"
   824                 link and download the binaryplugs for
   825                 your particular platform.
   826                 The file downloaded is a jar file that must be extracted by running
   827                 the jar file with:
   828                 <blockquote>
   829                     <pre>
   830             <tt><b>java -jar jdk-7-ea-plug-b<i>nn</i>-<i>os</i>-<i>arch</i>-<i>dd</i>_<i>month</i>_<i>year</i>.jar</b></tt>
   831                     </pre>
   832                 </blockquote>
   833                 A prompt will be issued for acceptance of these binary plug files.
   834                 During the OpenJDK build process these "binary plugs"
   835                 for the encumbered components will be copied into your
   836                 resulting OpenJDK binary build image.
   837                 These binary plug files are only for the purpose of
   838                 building an OpenJDK binary.
   839                 Make sure you set
   840                 <tt><a href="#ALT_BINARY_PLUGS_PATH">ALT_BINARY_PLUGS_PATH</a></tt>
   841                 to the root of this installation.
   842             </blockquote>
   843             <!-- ------------------------------------------------------ -->
   844             <h4><a name="importjdk">Optional Import JDK</a></h4>
   845             <blockquote>
   846                 The <tt><a href="#ALT_JDK_IMPORT_PATH">ALT_JDK_IMPORT_PATH</a></tt>
   847                 setting is only needed if you are not building the entire
   848                 JDK. For example, if you have built the entire JDK once, and
   849                 wanted to avoid repeatedly building the Hotspot VM, you could
   850                 set this to the location of the previous JDK install image
   851                 and the build will copy the needed files from this import area.
   852             </blockquote>
   853             <!-- ------------------------------------------------------ -->
   854             <h4><a name="ant">Ant</a></h4>
   855             <blockquote>
   856                 All OpenJDK builds require access to least Ant 1.6.5.
   857                 The Ant tool is available from the 
   858                 <a href="http://ant.apache.org" target="_blank">
   859                 Ant download site</a>.
   860                 You should always make sure <tt>ant</tt> is in your PATH, and
   861                 on Windows you may also need to set 
   862                 <tt><a href="#ANT_HOME">ANT_HOME</a></tt>
   863                 to point to the location of
   864                 the Ant installation, this is the directory pathname
   865                 that contains a <tt>bin and lib</tt>.
   866             </blockquote>
   867             <!-- ------------------------------------------------------ -->
   868             <h4><a name="cacerts">Certificate Authority File (cacert)</a></h4>
   869             <blockquote>
   870                 See <a href="http://en.wikipedia.org/wiki/Certificate_Authority" target="_blank">
   871                 http://en.wikipedia.org/wiki/Certificate_Authority</a>
   872                 for a better understanding of the Certificate Authority (CA).
   873                 A certificates file named "cacerts"
   874                 represents a system-wide keystore with CA certificates. 
   875                 In JDK and JRE
   876                 binary bundles, the "cacerts" file contains root CA certificates from
   877                 several public CAs (e.g., VeriSign, Thawte, and Baltimore).
   878                 The source contain a cacerts file
   879                 without CA root certificates. 
   880                 Formal JDK builders will need to secure
   881                 permission from each public CA and include the certificates into their
   882                 own custom cacerts file. 
   883                 Failure to provide a populated cacerts file
   884                 will result in verification errors of a certificate chain during runtime.
   885                 The variable 
   886                 <tt><a href="#ALT_CACERTS_FILE">ALT_CACERTS_FILE</a></tt>
   887                 can be used to override the default location of the
   888                 cacerts file that will get placed in your build.
   889                 By default an empty cacerts file is provided and that should be
   890                 fine for most JDK developers.
   891             </blockquote>
   892             <!-- ------------------------------------------------------ -->
   893             <h4><a name="jibx">JIBX</a></h4>
   894             <blockquote>
   895                 JIBX libraries version 1.1.5 is required for building the OpenJDK.
   896                 Namely, the following JAR files from the JIBX distribution package
   897                 are required:
   898                 <ul>
   899                     <li>bcel.jar
   900                     <li>jibx-bind.jar
   901                     <li>jibx-run.jar
   902                     <li>xpp3.jar
   903                 </ul>
   904                 <p>
   905                 You can download the package from the
   906                 <a href="http://jibx.sourceforge.net" target="_blank">JIBX site</a>.
   907                 <p>
   908                 You will need to set the
   909                 <tt><a href="#ALT_JIBX_LIBS_PATH">ALT_JIBX_LIBS_PATH</a></tt>
   910                 environment variable to refer to place where the JAR files,
   911                 above, are located.
   912             </blockquote>
   913             <!-- ------------------------------------------------------ -->
   914             <h4><a name="compilers">Compilers</a></h4>
   915             <blockquote>
   916                 <strong><a name="gcc">Linux gcc/binutils</a></strong>
   917                 <blockquote>
   918                     The GNU gcc compiler version should be 4 or newer.
   919                     The compiler used should be the default compiler installed
   920                     in <tt>/usr/bin</tt>.
   921                 </blockquote>
   922                 <strong><a name="studio">Solaris: Sun Studio</a></strong>
   923                 <blockquote>
   924                     At a minimum, the
   925                     <a href="http://developers.sun.com/sunstudio/index.jsp" target="_blank">
   926                     Sun Studio 12 Compilers</a>
   927                     (containing version 5.9 of the C and C++ compilers) is required,
   928                     with patches from the
   929                     <a href="http://sunsolve.sun.com/pub-cgi/show.pl?target=patches/patch-access" target="_blank">
   930                     SunSolve web site</a>.
   931                     <p> 
   932                     Set 
   933                     <a href="#ALT_COMPILER_PATH"><tt>ALT_COMPILER_PATH</tt></a>
   934                     to point to the location of
   935                     the compiler binaries, and place this location in the <tt>PATH</tt>.
   936                     <p>
   937                     The Sun Studio Express compilers at:
   938                     <a href="http://developers.sun.com/sunstudio/downloads/express.jsp" target="_blank">
   939                     Sun Studio Express Download site</a>
   940                     are also an option, although these compilers have not
   941                     been extensively used yet.
   942                 </blockquote>
   943                 <strong><a name="msvc">Windows i586: Microsoft Visual Studio Compilers</a></strong>
   944                 <blockquote>
   945                     The 32-bit OpenJDK Windows build
   946                     requires 
   947                     Microsoft Visual Studio C++ 2008 (VS2008) Standard
   948                     Edition compiler. 
   949                     The compiler and other tools are expected to reside
   950                     in the location defined by the variable 
   951                     <tt>VS90COMNTOOLS</tt> which
   952                     is set by the Microsoft Visual Studio installer.
   953                     <p> 
   954                     Once the compiler is installed, 
   955                     it is recommended that you run <tt>VCVARS32.BAT</tt> 
   956                     to set the compiler environment variables
   957                     <tt>INCLUDE</tt>,
   958                     <tt>LIB</tt>, and
   959                     <tt>PATH</tt> 
   960                     prior to building the 
   961                     OpenJDK.
   962                     The above environment variables <b>MUST</b> be set.
   963                     <p>
   964                     <b>WARNING:</b> Make sure you check out the
   965                     <a href="#cygwin">CYGWIN link.exe WARNING</a>.
   966                     The path <tt>/usr/bin</tt> must be after the path to the
   967                     Visual Studio product.
   968                 </blockquote>
   969                 <strong><a name="mssdk">Windows: Microsoft Platform SDK</a></strong>
   970                 <blockquote>
   971                     On <b>X64</b>, the Microsoft Platform Software
   972                     Development Kit (SDK), April 2005 Edition compiler,
   973                     is required for building the OpenJDK
   974                     because it contains the C/C++ compiler. 
   975                     You will need to minimally install the Core SDK and
   976                     the MDAC SDK features of this compiler.
   977                     <p>
   978                     Once the Platform SDK is installed,
   979                     it is recommended that you run <tt>SetEnv.Cmd /X64</tt> 
   980                     to set the compiler environment variables
   981                     <tt>MSSDK</tt>, 
   982                     <tt>MSTOOLS</tt>,
   983                     <tt>INCLUDE</tt>,
   984                     <tt>LIB</tt>, and
   985                     <tt>PATH</tt> 
   986                     prior to building the 
   987                     OpenJDK.
   988                     The above environment variables <b>MUST</b> be set.
   989                     <p>
   990                     This Platform SDK compiler is only used on X64 builds
   991                     but other parts of the Platform SDK may be used 
   992                     for the X86 builds.
   993                 </blockquote>
   994             </blockquote>
   995             <!-- ------------------------------------------------------ --> 
   996             <h4><a name="zip">Zip and Unzip</a></h4>
   997             <blockquote>
   998                 Version 2.2 (November 3rd 1997) or newer of the zip utility 
   999                 and version 5.12 or newer of the unzip utility is needed 
  1000                 to build the JDK.
  1001                 With Solaris, Linux, and Windows CYGWIN, the zip and unzip
  1002                 utilities installed on the system should be fine.
  1003                 Information and the source code for
  1004                 ZIP.EXE and UNZIP.EXE is available on the
  1005                 <a href="http://www.info-zip.org" 
  1006                    target="_blank">info-zip web site</a>.
  1007             </blockquote>
  1008             <!-- ------------------------------------------------------ -->
  1009             <h4><a name="cups">Common UNIX Printing System (CUPS) Headers (Solaris &amp; Linux)</a></h4>
  1010             <blockquote>
  1011                 <strong>Solaris:</strong>
  1012                 CUPS header files are required for building the 
  1013                 OpenJDK on Solaris.
  1014                 The Solaris header files can be obtained by installing 
  1015                 the package <strong>SFWcups</strong> from the Solaris Software
  1016                 Companion CD/DVD, these often will be installed into 
  1017                 <tt>/opt/sfw/cups</tt>.
  1018                 <p>
  1019                 <strong>Linux:</strong>
  1020                 CUPS header files are required for building the 
  1021                 OpenJDK on Linux.
  1022                 The Linux header files are usually available from a "cups"
  1023                 development package, it's recommended that you try and use
  1024                 the package provided by the particular version of Linux that
  1025                 you are using.
  1026                 <p>
  1027                 The CUPS header files can always be downloaded from 
  1028                 <a href="http://www.cups.org" target="_blank">www.cups.org</a>.
  1029                 The variable 
  1030                 <tt><a href="#ALT_CUPS_HEADERS_PATH">ALT_CUPS_HEADERS_PATH</a></tt>
  1031                 can be used to override the default location of the
  1032                 CUPS Header files.
  1033             </blockquote>
  1034             <!-- ------------------------------------------------------ -->
  1035             <h4><a name="freetype">FreeType 2</a></h4>
  1036             <blockquote>
  1037                 Version 2.3 or newer of FreeType is required for building the OpenJDK.
  1038                 On Unix systems required files can be available as part of your
  1039                 distribution (while you still may need to upgrade them).
  1040                 Note that you need development version of package that 
  1041                 includes both FreeType library and header files.
  1042                 <p>
  1043                 You can always download latest FreeType version from the
  1044                 <a href="http://www.freetype.org" target="_blank">FreeType website</a>.
  1045                 <p>
  1046                 Makefiles will try to pick FreeType from /usr/lib and /usr/include.
  1047                 In case it is installed elsewhere you will need to set environment
  1048                 variables 
  1049                 <tt><a href="#ALT_FREETYPE_LIB_PATH">ALT_FREETYPE_LIB_PATH</a></tt>
  1050                 and 
  1051                 <tt><a href="#ALT_FREETYPE_HEADERS_PATH">ALT_FREETYPE_HEADERS_PATH</a></tt>
  1052                 to refer to place where library and header files are installed.
  1053                 <p>
  1054                 Building the freetype 2 libraries from scratch is also possible,
  1055                 however on Windows refer to the
  1056                 <a href="http://freetype.freedesktop.org/wiki/FreeType_DLL">
  1057                 Windows FreeType DLL build instructions</a>.
  1058                 <p>
  1059                 Note that by default FreeType is built with byte code hinting
  1060                 support disabled due to licensing restrictions.
  1061                 In this case, text appearance and metrics are expected to
  1062                 differ from Sun's official JDK build.
  1063                 See
  1064                 <a href="http://freetype.sourceforge.net/freetype2/index.html">
  1065                     the SourceForge FreeType2 Home Page
  1066                 </a>
  1067                 for more information.
  1068             </blockquote>    
  1069             <!-- ------------------------------------------------------ -->
  1070             <h4><a name="alsa">Advanced Linux Sound Architecture (ALSA) (Linux only)</a></h4>
  1071             <blockquote>
  1072                 <strong>Linux only:</strong>
  1073                 Version 0.9.1 or newer of the ALSA files are
  1074                 required for building the OpenJDK on Linux.
  1075                 These Linux files are usually available from an "alsa"
  1076                 of "libasound"
  1077                 development package, it's highly recommended that you try and use
  1078                 the package provided by the particular version of Linux that
  1079                 you are using.
  1080                 The makefiles will check this emit a sanity error if it is
  1081                 missing or the wrong version.
  1082                 <p>
  1083                 In particular, older Linux systems will likely not have the
  1084                 right version of ALSA installed, for example
  1085                 Redhat AS 2.1 U2 and SuSE 8.1 do not include a sufficiently 
  1086                 recent ALSA distribution.
  1087                 On rpm-based systems, you can see if ALSA is installed by 
  1088                 running this command:
  1089                 <pre>
  1090                     <tt>rpm -qa | grep alsa</tt>
  1091                 </pre>
  1092                 Both <tt>alsa</tt> and <tt>alsa-devel</tt> packages are needed.
  1093                 <p> 
  1094                 If your distribution does not come with ALSA, and you can't
  1095                 find ALSA packages built for your particular system,
  1096                 you can try to install the pre-built ALSA rpm packages from
  1097                 <a href="http://www.freshrpms.net/" target="_blank">
  1098                 <tt>www.freshrpms.net</tt></a>. 
  1099                 Note that installing a newer ALSA could
  1100                 break sound output if an older version of ALSA was previously
  1101                 installed on the system, but it will enable JDK compilation.
  1102                 <blockquote>
  1103                     Installation: execute as root<br>
  1104                     [i586]: <code>rpm -Uv --force alsa-lib-devel-0.9.1-rh61.i386.rpm</code><br>
  1105                     [x64]: <code>rpm -Uv --force alsa-lib-devel-0.9.8-amd64.x86_64.rpm</code><br>
  1106                     Uninstallation:<br>
  1107                     [i586]: <code>rpm -ev alsa-lib-devel-0.9.1-rh61</code><br>
  1108                     [x64]:<code>rpm -ev alsa-lib-devel-0.9.8-amd64</code><br>
  1109                     Make sure that you do not link to the static library
  1110                     (<tt>libasound.a</tt>),
  1111                     by verifying that the dynamic library (<tt>libasound.so</tt>) is
  1112                     correctly installed in <tt>/usr/lib</tt>.
  1113                 </blockquote>
  1114                 As a last resort you can go to the
  1115                 <a href="http://www.alsa-project.org" target="_blank">
  1116                 Advanced Linux Sound Architecture Site</a> and build it from
  1117                 source.
  1118                 <blockquote>
  1119                     Download driver and library
  1120                     source tarballs from 
  1121                     <a href="http://www.alsa-project.org" target="_blank">ALSA's homepage</a>. 
  1122                     As root, execute the following
  1123                     commands (you may need to adapt the version number):
  1124                     <pre>
  1125                         <tt>
  1126                             $ tar xjf alsa-driver-0.9.1.tar.bz2
  1127                             $ cd alsa-driver-0.9.1
  1128                             $ ./configure
  1129                             $ make install
  1130                             $ cd ..
  1131                             $ tar xjf alsa-lib-0.9.1.tar.bz2
  1132                             $ cd alsa-lib-0.9.1
  1133                             $ ./configure
  1134                             $ make install
  1135                         </tt>
  1136                     </pre>
  1137                     Should one of the above steps fail, refer to the documentation on
  1138                     ALSA's home page.
  1139                 </blockquote>
  1140                 Note that this is a minimum install that enables
  1141                 building the JDK platform. To actually use ALSA sound drivers, more
  1142                 steps are necessary as outlined in the documentation on ALSA's homepage.
  1143                 <p>
  1144                 ALSA can be uninstalled by executing <tt>make uninstall</tt> first in
  1145                 the <tt>alsa-lib-0.9.1</tt> directory and then in 
  1146                 <tt>alsa-driver-0.9.1</tt>.
  1147             </blockquote>
  1148             There are no ALT* variables to change the assumed locations of ALSA,
  1149             the makefiles will expect to find the ALSA include files and library at:
  1150             <tt>/usr/include/alsa</tt> and <tt>/usr/lib/libasound.so</tt>.
  1151         </blockquote>
  1152         <!-- ------------------------------------------------------ -->
  1153         <h4>Windows Specific Dependencies</h4>
  1154         <blockquote>
  1155             <strong>Unix Command Tools (<a name="cygwin">CYGWIN</a>)</strong>
  1156             <blockquote> 
  1157                 The OpenJDK requires access to a set of unix command tools
  1158                 on Windows which can be supplied by 
  1159                 <a href="http://www.cygwin.com" target="_blank">CYGWIN</a>. 
  1160                 <p>
  1161                 The OpenJDK build requires CYGWIN version 1.5.12 or newer. 
  1162                 Information about CYGWIN can
  1163                 be obtained from the CYGWIN website at 
  1164                 <a href="http://www.cygwin.com" target="_blank">www.cygwin.com</a>. 
  1165                 <p>
  1166                 By default CYGWIN doesn't install all the tools required for building
  1167                 the OpenJDK.
  1168                 Along with the default installation, you need to install
  1169                 the following tools.
  1170                 <blockquote>
  1171                     <table border="1">
  1172                         <thead>
  1173                             <tr>
  1174                                 <td>Binary Name</td>
  1175                                 <td>Category</td>
  1176                                 <td>Package</td>
  1177                                 <td>Description</td>
  1178                             </tr>
  1179                         </thead>
  1180                         <tbody>
  1181                             <tr>
  1182                                 <td>ar.exe</td>
  1183                                 <td>Devel</td>
  1184                                 <td>binutils</td>
  1185                                 <td>The GNU assembler, linker and binary
  1186                                 utilities</td>
  1187                             </tr>
  1188                             <tr>
  1189                                 <td>make.exe</td>
  1190                                 <td>Devel</td>
  1191                                 <td>make</td>
  1192                                 <td>The GNU version of the 'make' utility built for CYGWIN.<br>
  1193                                 <b>NOTE</b>: See <a href="#gmake">the GNU make section</a></td>
  1194                             </tr>
  1195                             <tr>
  1196                                 <td>m4.exe</td>
  1197                                 <td>Interpreters</td>
  1198                                 <td>m4</td>
  1199                                 <td>GNU implementation of the traditional Unix macro
  1200                                 processor</td>
  1201                             </tr>
  1202                             <tr>
  1203                                 <td>cpio.exe</td>
  1204                                 <td>Utils</td>
  1205                                 <td>cpio</td>
  1206                                 <td>A program to manage archives of files</td>
  1207                             </tr>
  1208                             <tr>
  1209                                 <td>gawk.exe</td>
  1210                                 <td>Utils</td>
  1211                                 <td>awk</td>
  1212                                 <td>Pattern-directed scanning and processing language</td>
  1213                             </tr>
  1214                             <tr>
  1215                                 <td>file.exe</td>
  1216                                 <td>Utils</td>
  1217                                 <td>file</td>
  1218                                 <td>Determines file type using 'magic' numbers</td>
  1219                             </tr>
  1220                             <tr>
  1221                                 <td>zip.exe</td>
  1222                                 <td>Archive</td>
  1223                                 <td>zip</td>
  1224                                 <td>Package and compress (archive) files</td>
  1225                             </tr>
  1226                             <tr>
  1227                                 <td>unzip.exe</td>
  1228                                 <td>Archive</td>
  1229                                 <td>unzip</td>
  1230                                 <td>Extract compressed files in a ZIP archive</td>
  1231                             </tr>
  1232                             <tr>
  1233                                 <td>free.exe</td>
  1234                                 <td>System</td>
  1235                                 <td>procps</td>
  1236                                 <td>Display amount of free and used memory in the system</td>
  1237                             </tr>
  1238                         </tbody>
  1239                     </table>
  1240                 </blockquote>
  1241                 <p>
  1242                 Note that the CYGWIN software can conflict with other non-CYGWIN
  1243                 software on your Windows system.
  1244                 CYGWIN provides a
  1245                 <a href="http://cygwin.com/faq/faq.using.html" target="_blank">FAQ</a> for
  1246                 known issues and problems, of particular interest is the
  1247                 section on
  1248                 <a href="http://cygwin.com/faq/faq.using.html#faq.using.bloda" target="_blank">
  1249                 BLODA (applications that interfere with CYGWIN)</a>.
  1250                 <p>
  1251                 <b>WARNING:</b>
  1252                 Be very careful with <b><tt>link.exe</tt></b>, it will conflict
  1253                 with the Visual Studio version. You need the Visual Studio
  1254                 version of <tt>link.exe</tt>, not the CYGWIN one.
  1255                 So it's important that the Visual Studio paths in PATH preceed
  1256                 the CYGWIN path <tt>/usr/bin</tt>.
  1257             </blockquote>
  1258             <strong><a name="dxsdk">Microsoft DirectX 9.0 SDK header files and libraries</a></strong>
  1259             <blockquote>
  1260                 Microsoft DirectX 9.0 SDK (Summer 2004)
  1261                 headers are required for building
  1262                 OpenJDK.
  1263                 This SDK can be downloaded from 
  1264                 <a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=FD044A42-9912-42A3-9A9E-D857199F888E&amp;displaylang=en" target="_blank">
  1265                 Microsoft DirectX 9.0 SDK (Summer 2004)</a>.
  1266                 If the link above becomes obsolete, the SDK can be found from 
  1267                 <a href="http://download.microsoft.com" target="_blank">the Microsoft Download Site</a>
  1268                 (search with "DirectX 9.0 SDK Update Summer 2004"). 
  1269                 The location of this SDK can be set with 
  1270                 <tt><a href="#ALT_DXSDK_PATH">ALT_DXSDK_PATH</a></tt>
  1271                 but it's normally found via the DirectX environment variable
  1272                 <tt>DXSDK_DIR</tt>.
  1273             </blockquote>
  1274             <strong><a name="msvcrt"><tt>MSVCRT.DLL</tt></a></strong>
  1275             <blockquote> 
  1276                 <strong>i586 only:</strong>
  1277                 The OpenJDK 32-bit build requires access to a redistributable
  1278                 <tt>MSVCRT.DLL</tt>.
  1279                 If the <tt>MSVCRT.DLL</tt> is not installed in 
  1280                 the system32 directory set the 
  1281                 <a href="#ALT_MSVCRT_DLL_PATH"><tt>ALT_MSVCRT_DLL_PATH</tt></a>
  1282                 variable to the location of this file.
  1283                 <p> 
  1284                 <strong>X64 only:</strong>
  1285                 The OpenJDK 64-bit build requires access to a redistributable
  1286                 <tt>MSVCRT.DLL</tt>, which is
  1287                 usually supplied by the
  1288                 <a href="#mssdk">Platform SDK</a>.
  1289                 If it is not available from the Platform SDK,
  1290                 set the 
  1291                 <a href="#ALT_MSVCRT_DLL_PATH"><tt>ALT_MSVCRT_DLL_PATH</tt></a>
  1292                 variable to the location of this file.
  1293             </blockquote>
  1294             <strong><tt><a name="msvcr90">MSVCR90.DLL</a></tt></strong>
  1295             <blockquote>
  1296                 <strong>i586 only:</strong>
  1297                 The 
  1298                 OpenJDK
  1299                 build requires access to a redistributable
  1300                 <tt>MSVCR90.DLL</tt> which should be
  1301                 supplied by the
  1302                 <a href="#msvc">Visual Studio product</a>.
  1303                 If the <tt>MSVCR90.DLL</tt> is not available from the
  1304                 Visual Studio product
  1305                 set the 
  1306                 <a href="#ALT_MSVCR90_DLL_PATH"><tt>ALT_MSVCR90_DLL_PATH</tt></a>
  1307                 variable to the location of this file.
  1308             </blockquote>
  1309         </blockquote>
  1310         <!-- ------------------------------------------------------ -->
  1311         <hr>
  1312         <h2><a name="creating">Creating the Build</a></h2>
  1313         <blockquote>
  1314             Once a machine is setup to build the OpenJDK,
  1315             the steps to create the build are fairly simple.
  1316             The various ALT settings can either be made into  variables
  1317             or can be supplied on the 
  1318             <a href="#gmake"><tt><i>gmake</i></tt></a> 
  1319             command.
  1320             <ol>
  1321                 <li>Use the sanity rule to double check all the ALT settings:
  1322                     <blockquote>
  1323                         <tt>
  1324                             <i>gmake</i> 
  1325                             sanity
  1326                             [ARCH_DATA_MODEL=<i>32 or 64</i>]
  1327                             [other "ALT_" overrides]
  1328                         </tt>
  1329                     </blockquote>
  1330                 </li>
  1331                 <li>Start the build with the command:
  1332                     <blockquote>
  1333                         <tt>
  1334                             <i>gmake</i> 
  1335                             [ARCH_DATA_MODEL=<i>32 or 64</i>]
  1336                             [ALT_OUTPUTDIR=<i>output_directory</i>] 
  1337                             [other "ALT_" overrides] 
  1338                         </tt>
  1339                     </blockquote>
  1340                 </li>
  1341             </ol>
  1342             <p>
  1343             <strong>Solaris:</strong>
  1344             Note that ARCH_DATA_MODEL is really only needed on Solaris to
  1345             indicate you want to built the 64-bit version.
  1346             And before the Solaris 64-bit binaries can be used, they
  1347             must be merged with the binaries from a separate 32-bit build. 
  1348             The merged binaries may then be used in either 32-bit or 64-bit mode, with
  1349             the selection occurring at runtime 
  1350             with the <tt>-d32</tt> or <tt>-d64</tt> options. 
  1351         </blockquote>
  1352         <!-- ------------------------------------------------------ -->
  1353         <hr>
  1354         <h2><a name="testing">Testing the Build</a></h2>
  1355         <blockquote>
  1356             When the build is completed, you should see the generated
  1357             binaries and associated files in the <tt>j2sdk-image</tt> 
  1358             directory in the output directory. 
  1359             The default output directory is
  1360             <tt>build/<i>platform</i></tt>,
  1361             where <tt><i>platform</i></tt> is one of
  1362             <tt><ul>
  1363                     <li>solaris-sparc</li>
  1364                     <li>solaris-sparcv9</li>
  1365                     <li>solaris-i586</li>
  1366                     <li>solaris-amd64</li>
  1367                     <li>linux-i586</li>
  1368                     <li>linux-amd64</li>
  1369                     <li>windows-i586</li>
  1370                     <li>windows-amd64</li>
  1371             </ul></tt>
  1372             In particular, the 
  1373             <tt>build/<i>platform</i>/j2sdk-image/bin</tt>
  1374             directory should contain executables for the 
  1375             OpenJDK tools and utilities.
  1376             <p>
  1377             You can test that the build completed properly by using the build
  1378             to run the various demos that you will find in the 
  1379             <tt>build/<i>platform</i>/j2sdk-image/demo</tt>
  1380             directory.
  1381             <p>
  1382             The provided regression tests can be run with the <tt>jtreg</tt>
  1383             utility from 
  1384             <a href="http://openjdk.java.net/jtreg/" target="_blank">the jtreg site</a>.
  1385         </blockquote>
  1386         <!-- ------------------------------------------------------ -->
  1387         <hr>
  1388         <h2><a name="variables">Environment/Make Variables</a></h2>
  1389         <p>
  1390         Some of the
  1391         environment or make variables (just called <b>variables</b> in this
  1392         document) that can impact the build are:
  1393         <blockquote>
  1394             <dl>
  1395                 <dt><a name="path"><tt>PATH</tt></a> </dt>
  1396                 <dd>Typically you want to set the <tt>PATH</tt> to include:
  1397                     <ul>
  1398                         <li>The location of the GNU make binary</li>
  1399                         <li>The location of the Bootstrap JDK <tt>java</tt> 
  1400                         (see <a href="#bootjdk">Bootstrap JDK</a>)</li>
  1401                         <li>The location of the C/C++ compilers 
  1402                         (see <a href="#compilers"><tt>compilers</tt></a>)</li>
  1403                         <li>The location or locations for the Unix command utilities
  1404                         (e.g. <tt>/usr/bin</tt>)</li>
  1405                     </ul>
  1406                 </dd>
  1407                 <dt><tt>MILESTONE</tt> </dt>
  1408                 <dd>
  1409                     The milestone name for the build (<i>e.g.</i>"beta"). 
  1410                     The default value is "internal".
  1411                 </dd>
  1412                 <dt><tt>BUILD_NUMBER</tt> </dt>
  1413                 <dd>
  1414                     The build number for the build (<i>e.g.</i> "b27"). 
  1415                     The default value is "b00".
  1416                 </dd>
  1417                 <dt><a name="arch_data_model"><tt>ARCH_DATA_MODEL</tt></a></dt>
  1418                 <dd>The <tt>ARCH_DATA_MODEL</tt> variable
  1419                     is used to specify whether the build is to generate 32-bit or 64-bit
  1420                     binaries. 
  1421                     The Solaris build supports either 32-bit or 64-bit builds, but
  1422                     Windows and Linux will support only one, depending on the specific
  1423                     OS being used.
  1424                     Normally, setting this variable is only necessary on Solaris.
  1425                     Set <tt>ARCH_DATA_MODEL</tt> to <tt>32</tt> for generating 32-bit binaries, 
  1426                     or to <tt>64</tt> for generating 64-bit binaries.
  1427                 </dd>
  1428                 <dt><a name="ALT_BOOTDIR"><tt>ALT_BOOTDIR</tt></a></dt>
  1429                 <dd>
  1430                     The location of the bootstrap JDK installation. 
  1431                     See <a href="#bootjdk">Bootstrap JDK</a> for more information.
  1432                     You should always install your own local Bootstrap JDK and
  1433                     always set <tt>ALT_BOOTDIR</tt> explicitly.
  1434                 </dd>
  1435                 <dt><a name="ALT_BINARY_PLUGS_PATH"><tt>ALT_BINARY_PLUGS_PATH</tt></a></dt>
  1436                 <dd>
  1437                     The location of the binary plugs installation.
  1438                     See <a href="#binaryplugs">Binary Plugs</a> for more information.
  1439                     You should always have a local copy of a
  1440                     recent Binary Plugs install image
  1441                     and set this variable to that location.
  1442                 </dd>
  1443                 <dt><a name="ALT_JDK_IMPORT_PATH"><tt>ALT_JDK_IMPORT_PATH</tt></a></dt>
  1444                 <dd>
  1445                     The location of a previously built JDK installation. 
  1446                     See <a href="#importjdk">Optional Import JDK</a> for more information.
  1447                 </dd>
  1448                 <dt><a name="ALT_OUTPUTDIR"><tt>ALT_OUTPUTDIR</tt></a> </dt>
  1449                 <dd>
  1450                     An override for specifying the (absolute) path of where the
  1451                     build output is to go.
  1452                     The default output directory will be build/<i>platform</i>.
  1453                 </dd>
  1454                 <dt><a name="ALT_COMPILER_PATH"><tt>ALT_COMPILER_PATH</tt></a> </dt>
  1455                 <dd>
  1456                     The location of the C/C++ compiler.
  1457                     The default varies depending on the platform. 
  1458                 </dd>
  1459                 <dt><tt><a name="ALT_CACERTS_FILE">ALT_CACERTS_FILE</a></tt></dt>
  1460                 <dd>
  1461                     The location of the <a href="#cacerts">cacerts</a> file.
  1462                     The default will refer to 
  1463                     <tt>jdk/src/share/lib/security/cacerts</tt>.
  1464                 </dd>
  1465                 <dt><tt><a name="ALT_JIBX_LIBS_PATH">ALT_JIBX_LIBS_PATH</a></tt></dt>
  1466                 <dd>
  1467                     The location of the <a href="#jibx">JIBX libraries</a> file.
  1468                     The default value is
  1469                     <tt>$(ALT_SLASH_JAVA)/devtools/share/jibx/lib</tt>.
  1470                 </dd>
  1471                 <dt><a name="ALT_CUPS_HEADERS_PATH"><tt>ALT_CUPS_HEADERS_PATH</tt></a> </dt>
  1472                 <dd>
  1473                     The location of the CUPS header files.
  1474                     See <a href="#cups">CUPS information</a> for more information.
  1475                     If this path does not exist the fallback path is 
  1476                     <tt>/usr/include</tt>.
  1477                 </dd>
  1478                 <dt><a name="ALT_FREETYPE_LIB_PATH"><tt>ALT_FREETYPE_LIB_PATH</tt></a></dt>
  1479                 <dd>
  1480                     The location of the FreeType shared library. 
  1481                     See <a href="#freetype">FreeType information</a> for details. 
  1482                 </dd>
  1483                 <dt><a name="ALT_FREETYPE_HEADERS_PATH"><tt>ALT_FREETYPE_HEADERS_PATH</tt></a></dt>
  1484                 <dd>
  1485                     The location of the FreeType header files.
  1486                     See <a href="#freetype">FreeType information</a> for details. 
  1487                 </dd>
  1488                 <dt><a name="ALT_JDK_DEVTOOLS_PATH"><tt>ALT_JDK_DEVTOOLS_PATH</tt></a></dt>
  1489                 <dd>
  1490                     The default root location of the devtools.
  1491                     The default value is 
  1492                     <tt>$(ALT_SLASH_JAVA)/devtools</tt>.
  1493                 </dd>
  1494                 <dt><tt><a name="ALT_DEVTOOLS_PATH">ALT_DEVTOOLS_PATH</a></tt> </dt>
  1495                 <dd>
  1496                     The location of tools like the 
  1497                     <a href="#zip"><tt>zip</tt> and <tt>unzip</tt></a>
  1498                     binaries, but might also contain the GNU make utility
  1499                     (<tt><i>gmake</i></tt>).
  1500                     So this area is a bit of a grab bag, especially on Windows.
  1501                     The default value depends on the platform and
  1502                     Unix Commands being used.
  1503                     On Linux the default will be 
  1504                     <tt>$(ALT_JDK_DEVTOOLS_PATH)/linux/bin</tt>, 
  1505                     on Solaris
  1506                     <tt>$(ALT_JDK_DEVTOOLS_PATH)/<i>{sparc,i386}</i>/bin</tt>, 
  1507                     and on Windows with CYGWIN
  1508                     <tt>/usr/bin</tt>.
  1509                 </dd>
  1510                 <dt><a name="ALT_UNIXCCS_PATH"><tt>ALT_UNIXCCS_PATH</tt></a></dt>
  1511                 <dd>
  1512                     <strong>Solaris only:</strong>
  1513                     An override for specifying where the Unix CCS
  1514                     command set are located.
  1515                     The default location is <tt>/usr/ccs/bin</tt> 
  1516                 </dd>
  1517                 <dt><a name="ALT_SLASH_JAVA"><tt>ALT_SLASH_JAVA</tt></a></dt>
  1518                 <dd>
  1519                     The default root location for many of the ALT path locations
  1520                     of the following ALT variables.
  1521                     The default value is 
  1522                     <tt>"/java"</tt> on Solaris and Linux, 
  1523                     <tt>"J:"</tt> on Windows.
  1524                 </dd>
  1525                 <dt><a name="ALT_BUILD_JDK_IMPORT_PATH"><tt>ALT_BUILD_JDK_IMPORT_PATH</tt></a></dt>
  1526                 <dd>
  1527                     These are useful in managing builds on multiple platforms.
  1528                     The default network location for all of the import JDK images
  1529                     for all platforms. 
  1530                     If <tt><a href="#ALT_JDK_IMPORT_PATH">ALT_JDK_IMPORT_PATH</a></tt>
  1531                     is not set, this directory will be used and should contain 
  1532                     the following directories:
  1533                     <tt>solaris-sparc</tt>,
  1534                     <tt>solaris-i586</tt>,
  1535                     <tt>solaris-sparcv9</tt>,
  1536                     <tt>solaris-amd64</tt>,
  1537                     <tt>linux-i586</tt>,
  1538                     <tt>linux-amd64</tt>,
  1539                     <tt>windows-i586</tt>,
  1540                     and
  1541                     <tt>windows-amd64</tt>.
  1542                     Where each of these directories contain the import JDK image
  1543                     for that platform.
  1544                 </dd>
  1545                 <dt><a name="ALT_BUILD_BINARY_PLUGS_PATH"><tt>ALT_BUILD_BINARY_PLUGS_PATH</tt></a></dt>
  1546                 <dd>
  1547                     These are useful in managing builds on multiple platforms.
  1548                     The default network location for all of the binary plug images
  1549                     for all platforms. 
  1550                     If <tt><a href="#ALT_BINARY_PLUGS_PATH">ALT_BINARY_PLUGS_PATH</a></tt>
  1551                     is not set, this directory will be used and should contain 
  1552                     the following directories:
  1553                     <tt>solaris-sparc</tt>,
  1554                     <tt>solaris-i586</tt>,
  1555                     <tt>solaris-sparcv9</tt>,
  1556                     <tt>solaris-amd64</tt>,
  1557                     <tt>linux-i586</tt>,
  1558                     <tt>linux-amd64</tt>,
  1559                     <tt>windows-i586</tt>,
  1560                     and
  1561                     <tt>windows-amd64</tt>.
  1562                     Where each of these directories contain the binary plugs image
  1563                     for that platform.
  1564                 </dd>
  1565                 <dt><strong>Windows specific:</strong></dt>
  1566                 <dd>
  1567                     <dl>
  1568                         <dt><a name="ALT_MSDEVTOOLS_PATH"><tt>ALT_MSDEVTOOLS_PATH</tt></a> </dt>
  1569                         <dd>
  1570                             The location of the 
  1571                             Microsoft Visual Studio
  1572                             tools 'bin' directory.
  1573                             The default is usually derived from
  1574                             <a href="#ALT_COMPILER_PATH"><tt>ALT_COMPILER_PATH</tt></a>.
  1575                         </dd>
  1576                         <dt><tt><a name="ALT_DXSDK_PATH">ALT_DXSDK_PATH</a></tt> </dt>
  1577                         <dd>
  1578                             The location of the 
  1579                             <a href="#dxsdk">Microsoft DirectX 9 SDK</a>.
  1580                             The default will be to try and use the DirectX environment
  1581                             variable <tt>DXSDK_DIR</tt>,
  1582                             failing that, look in <tt>C:/DXSDK</tt>.
  1583                         </dd>
  1584                         <dt><tt><a name="ALT_MSVCRT_DLL_PATH">ALT_MSVCRT_DLL_PATH</a></tt> </dt>
  1585                         <dd>
  1586                             The location of the 
  1587                             <a href="#msvcrt"><tt>MSVCRT.DLL</tt></a>. 
  1588                         </dd>
  1589                         <dt><tt><a name="ALT_MSVCR90_DLL_PATH">ALT_MSVCR90_DLL_PATH</a></tt> </dt>
  1590                         <dd>
  1591                             <strong>i586 only:</strong>
  1592                             The location of the 
  1593                             <a href="#msvcr90"><tt>MSVCR90.DLL</tt></a>. 
  1594                         </dd>
  1595                     </dl>
  1596                 </dd>
  1597             </dl>
  1598         </blockquote>
  1599         <!-- ------------------------------------------------------ -->
  1600         <hr>
  1601         <h2><a name="troubleshooting">Troubleshooting</a></h2>
  1602         <blockquote>
  1603             A build can fail for any number of reasons. 
  1604             Most failures
  1605             are a result of trying to build in an environment in which all the
  1606             pre-build requirements have not been met. 
  1607             The first step in
  1608             troubleshooting a build failure is to recheck that you have satisfied
  1609             all the pre-build requirements for your platform.
  1610             Look for the check list of the platform you are building on in the
  1611             <a href="#contents">Table of Contents</a>.
  1612             <p>
  1613             You can validate your build environment by using the <tt>sanity</tt>
  1614             target.
  1615             Any errors listed
  1616             will stop the build from starting, and any warnings may result in
  1617             a flawed product build.
  1618             We strongly encourage you to evaluate every
  1619             sanity check warning and fix it if required, before you proceed
  1620             further with your build.
  1621             <p>
  1622             Some of the more common problems with builds are briefly described
  1623             below, with suggestions for remedies.
  1624             <ul>
  1625                 <li>
  1626                     <b>Slow Builds:</b>
  1627                     <blockquote>
  1628                         If your build machine seems to be overloaded from too many
  1629                         simultaneous C++ compiles, try setting the <tt>HOTSPOT_BUILD_JOBS</tt>
  1630                         variable to <tt>1</tt> (if you're using a multiple CPU
  1631                         machine, setting it to more than the the number of CPUs is probably
  1632                         not a good idea).
  1633                         <p>
  1634                         Creating the javadocs can be very slow, if you are running
  1635                         javadoc, consider skipping that step.
  1636                         <p>
  1637                         Faster hardware and more RAM always helps too.
  1638                         The VM build tends to be CPU intensive (many C++ compiles),
  1639                         and the rest of the JDK will often be disk intensive.
  1640                         <p>
  1641                         Faster compiles are possible using a tool called
  1642                         <a href="http://ccache.samba.org/" target="_blank">ccache</a>.
  1643                     </blockquote>
  1644                 </li>
  1645                 <li>
  1646                     <b>File time issues:</b>
  1647                     <blockquote>
  1648                         If you see warnings that refer to file time stamps, e.g.
  1649                         <blockquote>
  1650                             <i>Warning message:</i><tt> File `xxx' has modification time in
  1651                             the future.</tt>
  1652                             <br>
  1653                             <i>Warning message:</i> <tt> Clock skew detected. Your build may
  1654                             be incomplete.</tt> 
  1655                         </blockquote>
  1656                         These warnings can occur when the clock on the build machine is out of
  1657                         sync with the timestamps on the source files. Other errors, apparently
  1658                         unrelated but in fact caused by the clock skew, can occur along with
  1659                         the clock skew warnings. These secondary errors may tend to obscure the
  1660                         fact that the true root cause of the problem is an out-of-sync clock.
  1661                         For example, an out-of-sync clock has been known to cause an old
  1662                         version of javac to be used to compile some files, resulting in errors
  1663                         when the pre-1.4 compiler ran across the new <tt>assert</tt> keyword
  1664                         in the 1.4 source code.
  1665                         <p>
  1666                         If you see these warnings, reset the clock on the build
  1667                         machine, run "<tt><i>gmake</i> clobber</tt>" or delete the directory
  1668                         containing the build output, and restart the build from the beginning.
  1669                     </blockquote>
  1670                 </li>
  1671                 <li>
  1672                     <b>Error message: <tt>Trouble writing out table to disk</tt></b>
  1673                     <blockquote>
  1674                         Increase the amount of swap space on your build machine.
  1675                     </blockquote>
  1676                 </li>
  1677                 <li>
  1678                     <b>Error Message: <tt>libstdc++ not found:</tt></b>
  1679                     <blockquote>
  1680                         This is caused by a missing libstdc++.a library.
  1681                         This is installed as part of a specific package
  1682                         (e.g. libstdc++.so.devel.386).
  1683                         By default some 64-bit Linux versions (e.g. Fedora)
  1684                         only install the 64-bit version of the libstdc++ package.
  1685                         Various parts of the JDK build require a static
  1686                         link of the C++ runtime libraries to allow for maximum
  1687                         portability of the built images.
  1688                     </blockquote>
  1689                 </li>
  1690                 <li>
  1691                     <b>Error Message: <tt>cannot restore segment prot after reloc</tt></b>
  1692                     <blockquote>
  1693                         This is probably an issue with SELinux (See
  1694                         <a href="http://en.wikipedia.org/wiki/SELinux" target="_blank">
  1695                         http://en.wikipedia.org/wiki/SELinux</a>).
  1696                         Parts of the VM is built without the <tt>-fPIC</tt> for
  1697                         performance reasons.
  1698                         <p>
  1699                         To completely disable SELinux:
  1700                         <tt>
  1701                             <ol>
  1702                                 <li>$ su root</li>
  1703                                 <li># system-config-securitylevel</li>
  1704                                 <li>In the window that appears, select the SELinux tab</li>
  1705                                 <li>Disable SELinux</li>
  1706                             </ol>
  1707                         </tt>
  1708                         <p>
  1709                         Alternatively, instead of completely disabling it you could
  1710                         disable just this one check.
  1711                         <tt>
  1712                             <ol>
  1713                                 <li>Select System->Administration->SELinux Management</li>
  1714                                 <li>In the SELinux Management Tool which appears, 
  1715                                 select "Boolean" from the menu on the left</li>
  1716                                 <li>Expand the "Memory Protection" group</li>
  1717                                 <li>Check the first item, labeled
  1718                                 "Allow all unconfined executables to use libraries requiring text relocation ..."</li>
  1719                             </ol>
  1720                         </tt>
  1721                     </blockquote>
  1722                 </li>
  1723                 <li>
  1724                     <b>Windows Error Message: <tt>*** fatal error - couldn't allocate heap, ... </tt></b>
  1725                     <blockquote>
  1726                         The CYGWIN software can conflict with other non-CYGWIN
  1727                         software. See the CYGWIN FAQ section on
  1728                         <a href="http://cygwin.com/faq/faq.using.html#faq.using.bloda" target="_blank">
  1729                         BLODA (applications that interfere with CYGWIN)</a>.
  1730                     </blockquote>
  1731                 </li>
  1732                 <li>
  1733                     <b>Windows Error Message: <tt>*** multiple target patterns.  Stop.</tt></b>
  1734                     <blockquote>
  1735                         The CYGWIN make version 3.81 may not like the Windows <tt>C:/</tt>
  1736                         style paths, it may not like the ':' character in the path
  1737                         when used in a makefile target definition.
  1738                         See the <a href="#gmake"><tt><i>gmake</i></tt></a> section.
  1739                     </blockquote>
  1740                 </li>
  1741             </ul>
  1742         </blockquote>
  1743         <hr>
  1744     </body>
  1745 </html>

mercurial