Building OpenAFS on OmniOSCE r151036

There are three requirements:

  1. A suncc-flavored compiler, such as Sunstudio 12.1. I suspect this is required because OpenAFS largely targets commercial Solaris. Modern Illumos distributions have gone to some effort to no longer depend on this compiler, and as a result it’s generally not available in repositories.

  2. A patch/hack to work around a preprocessor issue in OmniosCE’s latest kerberos headers. A crude hack is available here:

  3. Installation of pkg:/developer/build-essential


Here are the steps I use, assuming a bourne-type shell:

$ ./
$ AS=/opt/sunstudio12.1/bin/sunas \
    CC=/opt/sunstudio12.1/bin/suncc \
    SOLARISCC=/opt/sunstudio12.1/bin/suncc \
    CFLAGS="-Wl,-rpath=/opt/openafs/lib " \
    ./configure --prefix=/opt/openafs i386-pc-solaris2.11
$ gmake -j4