Skip to main content
This revision made March 12, 2013 00:47, by Alan Coopersmith
« earlier revision revert to this « later revision

Building the XNV gate

These instructions cover the older “Nevada” gate used during OpenSolaris and Solaris 11 development, and are left as historical reference for anyone still building that gate for a distro based on the OpenSolaris sources. See Build Instructions for the instructions for building the current Solaris X11 sources.


To get the X gate, clone the Mercurial repostory by running:

 hg clone

After cloning the X gate repository, you will need to download the original open source packages they modify.

The sources include a script named download-tarballs that you can run to do this. It assumes running /usr/bin/wget can connect to Internet websites. If you need to set it to use web proxies, run "man wget" for instructions.

To download all needed sources:


To delete all current tarballs and re-download all needed sources:

 ./download-tarballs -c

(c for “clobber”)

To see what it will do without connecting to any sites:

 ./download-tarballs -n

Build requirements & preparation

  • Solaris 11 or OpenSolaris, recent build (at least build 121)
  • Studio 12 Update 1
  • GNU autotools, gettext, and make
  • lynx (for converting docs from DocBook -> html -> text)

The recommended source for most the GNU tools needed to build the X consolidation are the packages included in the Solaris Userland consolidation, installed from the Solaris IPS repository.

To build 64-bit software, you will need to be running in 64-bit mode (which on x86 requires an AMD64 or Intel EM64T capable CPU).

Starting with X build 144, the X consolidation generates packages in IPS format instead of SVR4. This requires at least build 142 of the IPS software be installed in order to build the packages.

Building the software

To build the software, simply cd into the top level directory and run


To build the software and create packages, add the -p flag to buildit:

 ./buildit -p

Output of various stages is stored into log files which you can check for errors with the included open-src/util/build-tools/find-build-errors script:

build file under log/buildit-XW
SVR4 packaging proto-packages/logs/package_build
IPS packaging proto-packages/logs/make-pkgs proto-packages/logs/check-pkgs

The built binaries are found after the build in a proto area:

Builds before 144:

SPARC proto-sun4-svr4/
x86/x64 proto-i386-svr4/

Builds 144 and later:

SPARC proto/root_sparc/
x86/x64 proto/root_i386/

Installing SVR4 packages

The built packages will be found in the directory:


To install the packages from proto-packages/installdir, run the included ./upgrade-X script.

Installing IPS packages

The built packages will be found in a repository in the directory proto/pkg_sparc or proto/pkg_i386 as appropriate.

Builds made by individual developers default to using the publisher name xnv-devel but that can be overridden via flags to the buildit or make_release_packages scripts. They will depend on the versions of packages from other consolidations that were installed on the system they built them on.

The recommended mechanism for installing any of these builds is the onu tool provided by ON. You can install the pkg:/developer/build/onbld package from build 136 or later of ON to get a local copy installed as /opt/onbld/bin/onu .

onu will create a new boot environment and install the packages there - you will then need to reboot into that BE to use them. Since none of the X packages have the reboot required flag, it is possible to use pkg to directly install them to the live BE, but then you have more work to do if you need to switch back to the previous versions.

Note that onu uses pkg image-update , which means there are two important things to remember:

  1. It will upgrade all of your packages and not just the X packages.
  2. It will normally only upgrade the X packages you already have installed on the system, though it will leave the BE mounted so that you can add other packages via pkg -R /tmp/onu.* install package-name. To install all the packages provided by the X consolidation for the build in your BE, you can install the group package pkg:/consolidation/X/X-all.

Example: Install to a new BE named "X144" that is cloned from the current BE:

 # onu -O -u file://`pwd`/proto/pkgs_i386 -U xnv-devel -t X144
Please Confirm