Nagios/build/Solaris

Install gcc
get the gcc package form sunfreeware


 * 1) wget ftp://ftp.sunfreeware.com/pub/freeware/sparc/10/gcc-3.4.6-sol10-sparc-local.gz


 * 1) gunzip gcc-3.4.6-sol10-sparc-local.gz


 * 1) pkgadd -d gcc-3.4.6-sol10-sparc-local

you then need to set up the environment (you can add this to /etc/profile or some enlivenment =)


 * 1) export CC ; CC=gcc
 * 1) export LD_LIBRARY_PATH;  LD_LIBRARY_PATH=/usr/sfw/lib:/usr/local/ssl/lib
 * 1) export PATH ; PATH=/usr/local/bin:/usr/sfw/bin:/usr/sbin:/usr/bin:/usr/ccs/bin

install ligiconv
gcc needs libiconv

wget ftp://ftp.sunfreeware.com/pub/freeware/sparc/10/libiconv-1.11-sol10-sparc-local.gz
 * 1) gunzip libiconv-1.11-sol10-sparc-local.gz
 * 2) pkgadd -d libiconv-1.11-sol10-sparc-local

Install Lib gd
Get the source form www.libgd.org


 * 1) wget http://www.libgd.org/releases/gd-2.0.35.tar.gz

... ... ...
 * 1) gunzip -dc gd-2.0.35.tar.gz | tar -xf -
 * 1) cd gd-2.0.35
 * 1) ./configure --prefix=/opt/libgd
 * 1) make
 * 1) make install

Build Nagios server
get the nagios source from www.nagios.org


 * 1) gunzip -dc nagios-3.0.6.tar.gz | tar -xf -


 * 1) cd nagios-3.0.6


 * 1) groupadd -g 510 nagios
 * 2) useradd -u 510 -g nagios nagios

Refer to the Read Only Webaccount Patch below


 * 1) ./configure --prefix=/opt/nagios-3.0.6 --with-nagios-user=nagios --with-nagios-group=nagios --with-gd-lib=/opt/libgd/lib   --with-gd-inc=/opt/libgd/include


 * 1) gmake

Read Only Web account patch
get the patch from http://www.nagios3book.com/

in the directory you have extracted the nagios source code:


 * 1) wget http://www.nagios3book.com/nagios-3-enm/patches/readonly.tar

in the cgi/ dir and in the include/ dir
 * 1) tar xvf readonly.tar
 * 1) patch -r cgiauth.c < cgiauth.diff
 * 2) patch -r extinfo.c < extinfo.diff
 * 1) patch -r cgiauth.h < cgiauth.h.diff

Install gcc
get the gcc package form sunfreeware


 * 1) wget ftp://ftp.sunfreeware.com/pub/freeware/intel/10/gcc-3.4.6-sol10-x86-local.gz


 * 1) gunzip gcc-3.4.6-sol10-x86-local.gz


 * 1) pkgadd -d gcc-3.4.6-sol10-x86-local

you then need to set up the enviroment (you can add this to /etc/profile or some eqilivent =)


 * 1) export CC ; CC=gcc
 * 1) export LD_LIBRARY_PATH;  LD_LIBRARY_PATH=/usr/sfw/lib:/usr/local/ssl/lib
 * 1) export PATH ; PATH=/usr/local/bin:/usr/sfw/bin:/usr/sbin:/usr/bin:/usr/ccs/bin

install ligiconv
gcc need libiconv

wget ftp://ftp.sunfreeware.com/pub/freeware/intel/10/libiconv-1.11-sol10-x86-local.gz
 * 1) gunzip libiconv-1.11-sol10-x86-local.gz
 * 2) pkgadd -d libiconv-1.11-sol10-x86-local

Install Lib gd
Get the source form www.libgd.org


 * 1) wget http://www.libgd.org/releases/gd-2.0.35.tar.gz

... ... ...
 * 1) gunzip -dc gd-2.0.35.tar.gz | tar -xf -
 * 1) cd gd-2.0.35
 * 1) ./configure --prefix=/opt/libgd
 * 1) make
 * 1) make install

Build Nagios server
get the nagios source from www.nagios.org


 * 1) gunzip -dc nagios-3.0.3.tar.gz | tar -xf -


 * 1) cd nagios-3.0.3


 * 1) groupadd -g 510 nagios
 * 2) useradd -u 510 -g nagios nagios

Referee to the Read Only Webaccount Patch below


 * 1) ./configure --prefix=/opt/nagios-3.0.3 --with-nagios-user=nagios --with-nagios-group=nagios --with-gd-lib=/opt/libgd/lib   --with-gd-inc=/opt/libgd/include


 * 1) gmake

Read Only Web account patch
get the patch from http://www.nagios3book.com/

in the directory you have extracted the nagios source code:


 * 1) wget http://www.nagios3book.com/nagios-3-enm/patches/readonly.tar

in the cgi/ dir and in the include/ dir
 * 1) tar xvf readonly.tar
 * 1) patch -r cgiauth.c < cgiauth.diff
 * 2) patch -r extinfo.c < extinfo.diff
 * 1) patch -r cgiauth.h < cgiauth.h.diff