<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Sand2Silicon &#187; CBE</title>
	<atom:link href="http://guardiansrealm.net/sand2silicon/tag/cbe/feed/" rel="self" type="application/rss+xml" />
	<link>http://guardiansrealm.net/sand2silicon</link>
	<description>Hacking the world, one line at a time!</description>
	<lastBuildDate>Wed, 02 Mar 2011 18:02:13 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1</generator>
		<item>
		<title>Configuring OpenSolaris:  Installing SFE  (Spec Files Extras)</title>
		<link>http://guardiansrealm.net/sand2silicon/2009/06/configuring-opensolaris-installing-sfe-spec-files-extras/</link>
		<comments>http://guardiansrealm.net/sand2silicon/2009/06/configuring-opensolaris-installing-sfe-spec-files-extras/#comments</comments>
		<pubDate>Sat, 20 Jun 2009 04:30:26 +0000</pubDate>
		<dc:creator>RavenSlay3r</dc:creator>
				<category><![CDATA[2009.06]]></category>
		<category><![CDATA[OpenSolaris]]></category>
		<category><![CDATA[CBE]]></category>
		<category><![CDATA[JDS]]></category>
		<category><![CDATA[OSD]]></category>
		<category><![CDATA[SFE]]></category>
		<category><![CDATA[Spec File Extra]]></category>

		<guid isPermaLink="false">http://guardiansrealm.net/sand2silicon/?p=28</guid>
		<description><![CDATA[SFE is a repository of RPM-like spec files for building Solaris SVr4 packages from various Open Source modules. While the existing 'getting-started' docs are somewhat scattered and outdated, fear not! This tutorial will have you installing SFE packages into the latest OpenSolaris in no time!]]></description>
			<content:encoded><![CDATA[<h2>What are SFEs?</h2>
<blockquote><p>What is spec-files-extra? SFE is a repository of RPM-like spec files for building Solaris SVr4 packages from various Open Source modules. ~ <a href="http://pkgbuild.sourceforge.net/spec-files-extra/">The SFE Site</a></p></blockquote>
<p>And if you follow the installation instructions closely-enough, without getting too bogged down in the details, you can probably be up and running <em>SFE Enabled</em> faster than I can write this blog. <em>However</em> those instructions are slightly dated, and even as a Sophomore to the OSol world, I hit a few bumps along the way, so here&#8217;s the short-list to get you going quickly!</p>
<h2>JDS -&gt; OSD</h2>
<p>As it happens I started following the original instruction-set, returned a few hours later and someone had done a bit of &#8220;Find &amp; Replace&#8221; re-branding; just to mess with my head I believe&#8230; So &#8211; just to clear up some confusion:</p>
<ul>
<li><strong>JDS-CBE </strong>- <em>(Java Desktop Source &#8211; Common Build Environment (?))</em></li>
<li><strong>OSD-CBE</strong>- <em>(OpenSolaris Desktop &#8211; Common Build Environment(?)) </em></li>
</ul>
<p style="text-align: right;"><em>Old Name</em>, <em>New Name</em>, respectively.</p>
<p>Currently, they are the same thing and you will need the underlying &#8220;CBE&#8221; portion of them, even if you don&#8217;t intend to do further OSol Desktop Development. Careful not to follow the original instruction sheets blindly though, or your in for a world of trouble &#8211; instead, keep reading here!</p>
<h2>Installing the Common Build Environment (CBE)</h2>
<h3>Reference Links</h3>
<p>All of the information on this page was pulled-from and relates back to the following links. Hopefully, however, this blogpost will save you from dredging through them for the insight you need. Hopefully&#8230;</p>
<p>Useful Links (for now)</p>
<ol>
<li><a title="SFE Installation Guide" href="http://pkgbuild.sourceforge.net/spec-files-extra/" target="_blank">Spec File Extra </a>- Main Site</li>
<li><a title="Building OSD on OpenSolaris" href="http://www.opensolaris.org/os/project/jds/contributing/building/" target="_blank">JDS / OSD / CBE Installation Guide</a></li>
<li><a title="JDS / OSD Download Center" href="http://dlc.sun.com/osol/jds/downloads/cbe/" target="_blank">OSD Download Center</a> on <em>Sun</em></li>
<li><a title="SFE Package Index" href="http://pkgbuild.svn.sourceforge.net/viewvc/pkgbuild/spec-files-extra/trunk/" target="_blank">SFE Index</a> on SourceForge</li>
</ol>
<p>Less Relevant Extra&#8217;s</p>
<ol>
<li><a title="OSD Source Code Tour" href="http://www.opensolaris.org/os/project/jds/documents/source_code_tour/" target="_blank">OSD Source Code Tour</a></li>
<li><a title="OSD Sources" href="http://cvs.opensolaris.org/source/xref/jds/" target="_blank">JDS / OSD Source Location</a></li>
<li><a title="pkgBuild Home on SourceForge" href="http://pkgbuild.sourceforge.net/" target="_blank"><span style="text-decoration: none;"><span style="font-family: arial,sans; color: #4444aa;"><strong>pkg</strong><span style="color: #000000;">build</span></span></span> Home on SourceForge<br />
</a></li>
</ol>
<h3>(Do Not) Build CBE from Source</h3>
<p><em>(Rant: Feel free to skip to next section!)</em><br />
Given my Sun AMD_X64 system, I was unusually motivated to build something from source. Unfortunately, after a great  effort it was not to be. After downloading <strong>jds-cbe-1.6.2-src.tar</strong>, one should be able to run the <em>cbe-install</em> script and things will be happy.</p>
<p>The CBE appeared to build and install the first several tools correctly including v.1.9 and v.1.10 of AutoMake (or was it AutoConf ?), disregarding that they both already exist. When the script got to building: <strong>libtool-1.5.22</strong> it demanded <em>AutoMake-1.9a</em> and some other weird tool (also v.1.9.a). If I went to the directory under <em>$HOME/PACKAGES</em>, found <em>libtool-1.5.22</em> I could &#8220;configure, make, make install&#8221; just fine. However, the &#8220;cbe-install&#8221; script was still not happy and would never complete. No luck with the <strong>jds-cbe-1.6.2-src.tar</strong> either&#8230;</p>
<h3>Install From Binaries</h3>
<ol>
<li>(As stated elsewhere) <em>&#8220;You don&#8217;t need root access for installing the CBE or building GNOME, but the build-user needs to have the &#8216;Software Installation&#8217; profile for installing the packages that the CBE creates,&#8221;&#8230;</em> Of course, giving yourself said permissions <em>may</em> require ROOT access (on a one-time basis). That said, from the desktop:
<pre>- Click: System | Administration | Users &amp; Groups
- Select your userName and click: Properties
- Click the 'User Profiles' Tab and check 'Software Installation'
- Click 'OK' (twice).</pre>
</li>
<li> Install <em>SunStudio Express</em> from the IPS package manager. Building SFE packages requires a compiler and now&#8217;s a good time to grab it.
<pre>- Select the 'OpenSolaris.org' repository
- Select 'All Categories'
- Search for: studio
- Check and Install: sunstudioexpress
- Search for: sfwhea
- Check and Install: SUNWsfwhea</pre>
</li>
<li>Visit the <a title="JDS / OSD Download Center" href="http://dlc.sun.com/osol/jds/downloads/cbe/" target="_blank">OSD Download Center</a> (Link #3) and grab the: <strong>jds-cbe-1.6.2-i386.tar.bz2</strong> binary package.<br />
<em>Warning:</em> The <strong>_src_</strong> does NOT build cleanly on OSol 2009.06, so for now don&#8217;t even waste your time!</li>
<li> <code>athena: 453$ bunzip2 jds-cbe-1.6.2-i386.tar.bz2<br />
athena: 454$ tar -xvf jds-cbe-1.6.2-i386.tar<br />
athena: 456$ cd jds-cbe-1.6.2<br />
athena: 459$ ./cbe-install</code></li>
<li>Follow the scripts instructions, mostly you want the defaults.
<ul>
<li>Specifically confirm your compiler is: <strong>/usr/bin/cc</strong></li>
<li>The install script will complain, as your compiler is NEWER than the script, and doesn&#8217;t provide the expected version-output. This is OK!</li>
</ul>
</li>
<li>Now you need to download the SFE Spec-Files, which as I understand it, are essentially header-files of meta-data for each SFE package. Thus when you tell the system to install one it has all the install info it needs on hand.<br />
<code><br />
athena: 460$ cd ~<br />
athena: 461$ svn co https://pkgbuild.svn.sourceforge.net/svnroot/pkgbuild/spec-files-extra/trunk SFE</code></li>
<li>At this point you will want to add to your<em> ~/.bashrc</em> file:
<pre>PATH=$PATH:/opt/jdsbld/bin          # JDS-CBE   - packages we installed</pre>
</li>
<li>Now source the ~/.bashrc, and then run the env.sh in the /opt/jdsbld/bin &#8230;<br />
<code>athena: 466$ source ~/.bashrc<br />
athena: 467$ . /opt/jdsbld/bin/env.sh</code></li>
</ol>
<p>Congratulations! At this point you have installed the CBE, downloaded the SFE spec files from subversion, and configured your environment to start building SFE spec-file packages! Every time you want to install SFE packages you should run the second console line from &#8216;step 8&#8242; above, and of course running the first line &#8220;source ~/.bashrc&#8221; will always revert you to your normal working shell-environment.</p>
<h2>Installing a SFE Package</h2>
<p><code><br />
athena: 468$ . /opt/jdsbld/bin/env.sh<br />
athena: 468$ pkgtool build --download SFEfoo.spec<br />
</code></p>
<p>Or, while not bullet-proof, you can often use the dependency-checking option.<br />
<code><br />
pkgtool build --download SFEfoo.spec --autodeps<br />
</code></p>
<h2>Other Approaches</h2>
<p>Unknown to me, there was already a well written article to this effect. If you found my post unclear or unhelpful you may have better luck reading this: <a title="SourceForge Wiki: OpenSolaris - PkgBuild" href="http://pkgbuild.wiki.sourceforge.net/pkgbuild+on+OpenSolaris" target="_blank">pkgbuild on OpenSolaris</a></p>
<p>As a final and entirely different method you may want to search for the <em>sfe-bootstrap-latest</em> script. Supposedly it is an all inclusive script to get you running. I believe it was originally published in THIS forum thread: <a title="SFE BootStrap Script" href="http://opensolaris.org/jive/thread.jspa?threadID=91341&amp;tstart=0">sfe-bootstrap-latest script</a></p>
]]></content:encoded>
			<wfw:commentRss>http://guardiansrealm.net/sand2silicon/2009/06/configuring-opensolaris-installing-sfe-spec-files-extras/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

