Thanks to one of OpenSolaris’ sister communities — BeleniX, its founder Moinak Ghosh wrote one nice script and a blog post how to use it and build OpenSolaris from source. I’m glad to present his work and here is excerpt from his post:
The utility takes a workspace containing the OpenSolaris build snapshot tarballs and patches to apply and at the end delivers binary packages. It is also has the ability to check for pre-requisites for running the build. For eg. presence of proper version of SUN Studio 12, development and locale headers, assembler etc. It should work on both BeleniX and OpenSolaris though I have found time to only test it on BeleniX till date.
Getting it: Execute pkgadd –d http://www.belenix.org/binfiles/autobuilder.pkg
Setting up: Create a directory like say osol_ws. Now create osol_ws/downloads and osol_ws/patches. If you have patches for ON create another directory osol_ws/patches/on_patches and copy them into it. Copy your XEN patches if any into osol_ws/patches/xvm_patches. Now run osol_builder prereq while connected to the net. This will check for prerequisites for building OSOL on your distro and fix most of the requirements except for installing the proper SUN Studio 12 which you will have to do manually since it requires a login to download from SUN’s site.
Building: Now download all the requires build snapshot tarballs into osol_ws/downloads: on-src.tar.bz2, xvm-src.tar.bz2, SUNWonbld.i386.tar.bz2 or SUNWonbld.sparc.tar.bz2 ‚ on-closed-bins-nd.i386.tar.bz2 or on-closed-bins-nd.sparc.tar.bz2. Finally fire up the script: osol_builder build –R /path/to/osol_ws –d myosol
Running the utility without arguments prints a complete help text that will explain the subcommands and options.

Posts