X-Git-Url: https://git.octo.it/?p=rrdtool.git;a=blobdiff_plain;f=doc%2Frrdbuild.pod;h=1ce19f4f806265a5b73fc384249a538e3aba4394;hp=2d72f0fdb608b21330c894c4a2430f4772265307;hb=54aae6c831630630319db51ac97fd14d1ab8bd87;hpb=074aa84b2d837ae1af91661e82333ffee2f60a2d diff --git a/doc/rrdbuild.pod b/doc/rrdbuild.pod index 2d72f0f..1ce19f4 100644 --- a/doc/rrdbuild.pod +++ b/doc/rrdbuild.pod @@ -41,7 +41,7 @@ Where you want to install the software. Once you have decided. Save the two locations into environment variables. BUILD_DIR=/tmp/rrdbuild - INSTALL_DIR=/usr/local/rrdtool-1.3rc7 + INSTALL_DIR=/usr/local/rrdtool-1.3.2 If your F is mounted with the option noexec (RHEL seems todo that) you have to choose @@ -55,9 +55,9 @@ Now make sure the BUILD_DIR exists and go there: Lets first assume you already have all the necessary libraries pre-installed. - wget http://oss.oetiker.ch/rrdtool/pub/rrdtool-1.3rc7.tar.gz - gunzip -c rrdtool-1.3rc7.tar.gz | tar xf - - cd rrdtool-1.3rc7 + wget http://oss.oetiker.ch/rrdtool/pub/rrdtool-1.3.2.tar.gz + gunzip -c rrdtool-1.3.2.tar.gz | tar xf - + cd rrdtool-1.3.2 ./configure --prefix=$INSTALL_DIR && make && make install Ok, this was very optimistic. This try will probably have ended with @@ -86,6 +86,17 @@ fix this: perl -i~ -p -e 's/(Requires.*?)\s*xrender.*/$1/' /usr/lib/pkgconfig/cairo.pc +Make sure rrdtool finds your new compiler + + export PATH=/opt/SunStudioExpress/bin + +Since there does not seem to ba a viable msgfmt tool on opensolaris (short +of installing it yourself). You have to call configure with the + + --disable-libintl + +option. + =head2 Debian / Ubuntu Use apt-get to make sure you have all that is required. A number @@ -126,7 +137,7 @@ system anyway. Freetype, Fontinst, Cairo, Pango may be installed, but it is possible that they are pretty old and thus don't live up to our expectations, so you may want to compile their latest versions. -=head3 Build Tips for AIX +=head2 General build tips for AIX If you are working with AIX, you may find the the B<--disable-shared> option will cause things to break for you. In that case you may have to install the @@ -140,22 +151,7 @@ Another hint to get rrdtool working on AIX is to use the IBM XL C Compiler: (Better instructions for AIX welcome!) -=head2 Building Libraries - -In order to build the libraries you need a compiler on your system. -Unfortunately compilers are not all alike. This has an effect on the CFLAGS -you want to set. The examples below are for the popular GCC compiler suite. -If you have an other compilers here are some ides: - -=over - -=item Sun Forte - - CFLAGS="-xO3 -kPIC" - -=back - -=over +=head2 Build Instructions Some libraries want to know where other libraries are. For this to work, set the following environment variable @@ -163,12 +159,12 @@ set the following environment variable export PKG_CONFIG_PATH=${INSTALL_DIR}/lib/pkgconfig export PATH=$INSTALL_DIR/bin:$PATH -This relies on the presence of the F program. Below you find instructions -on how to compile pkgconfig as well. +The above relies on the presence of the F program. Below you find instructions +on how to compile pkgconfig. -Since we are compiling libraries dynamically, they must know -where to find each other. This is done by setting an appropriate LDFLAGS. -Unfortunately, the syntax again differs from system to system: +Since we are compiling libraries dynamically, they must know where to find +each other. This is done by setting an appropriate LDFLAGS. Unfortunately, +the syntax again differs from system to system: =over @@ -176,12 +172,16 @@ Unfortunately, the syntax again differs from system to system: export LDFLAGS=-R${INSTALL_DIR}/lib +if you are using the Sun Studio/Forte compiler, you may also want to set + + CFLAGS="-xO3 -kPIC" + =item Linux export LDFLAGS="-Wl,--rpath -Wl,${INSTALL_DIR}/lib" =item HPUX - + export LDFLAGS="+b${INSTALL_DIR}/lib" =item AIX @@ -200,7 +200,7 @@ otherwise just do export MAKE=make -=item Building pkgconfig +=head3 Building pkgconfig As mentioned above, without pkgconfig the whole build process will be lots of pain and suffering, so make sure you have a copy on your system. If it is @@ -213,7 +213,7 @@ not available natively, here is how to compile it. $MAKE $MAKE install -=item Building zlib +=head3 Building zlib Chances are very high that you already have that on your system ... @@ -225,7 +225,7 @@ Chances are very high that you already have that on your system ... $MAKE $MAKE install -=item Building libpng +=head3 Building libpng Libpng itself requires zlib to build, so we need to help a bit. If you already have a copy of zlib on your system (which is very likely) you can @@ -240,7 +240,7 @@ the end of line 4 means that line 4 and line 5 are on one line. $MAKE $MAKE install -=item Building freetype +=head3 Building freetype cd $BUILD_DIR wget http://oss.oetiker.ch/rrdtool/pub/libs/freetype-2.3.5.tar.gz @@ -255,17 +255,17 @@ add the following at the start the configure line: env EGREP=egrep -=item Building LibXML2 +=head3 Building LibXML2 cd $BUILD_DIR wget http://oss.oetiker.ch/rrdtool/pub/libs/libxml2-sources-2.6.31.tar.gz - gunzip -c libxml2-sources-2.6.32.tar.gz | tar xf - - cd libxml2-sources-2.6.32 + gunzip -c libxml2-sources-2.6.31.tar.gz | tar xf - + cd libxml2-sources-2.6.31 ./configure --prefix=$INSTALL_DIR CFLAGS="-O3 -fPIC" $MAKE $MAKE install -=item Building fontconfig +=head3 Building fontconfig Note that fontconfig has a run time configuration file in INSTALL_DIR/etc you may want to adjust that so that fontconfig finds the fonts on your system. @@ -280,7 +280,7 @@ config file. $MAKE $MAKE install -=item Building Pixman +=head3 Building Pixman cd $BUILD_DIR wget http://oss.oetiker.ch/rrdtool/pub/libs/pixman-0.10.0.tar.gz @@ -290,11 +290,11 @@ config file. $MAKE $MAKE install -=item Building Cairo +=head3 Building Cairo cd $BUILD_DIR wget http://oss.oetiker.ch/rrdtool/pub/libs/cairo-1.6.4.tar.gz - gunzip -c cairo-1.4.10.tar.gz | tar xf - + gunzip -c cairo-1.6.4.tar.gz | tar xf - cd cairo-1.4.10 ./configure --prefix=$INSTALL_DIR \ --enable-xlib=no \ @@ -304,17 +304,17 @@ config file. $MAKE $MAKE install -=item Building Glib +=head3 Building Glib cd $BUILD_DIR wget http://oss.oetiker.ch/rrdtool/pub/libs/glib-2.15.4.tar.gz - gunzip -c glib-2.12.13.tar.gz | tar xf - - cd glib-2.12.13 + gunzip -c glib-2.15.4.tar.gz | tar xf - + cd glib-2.15.4 ./configure --prefix=$INSTALL_DIR CFLAGS="-O3 -fPIC" $MAKE $MAKE install -=item Building Pango +=head3 Building Pango cd $BUILD_DIR wget http://oss.oetiker.ch/rrdtool/pub/libs/pango-1.21.1.tar.gz @@ -324,7 +324,7 @@ config file. $MAKE $MAKE install -=back +=head2 Building rrdtool (second try) Now all the dependent libraries are built and you can try again. This time you tell configure where it should be looking for libraries and include @@ -336,14 +336,14 @@ because it seems that a fair number of people have ill configured python and tcl setups that would prevent rrdtool from building if they are included in their current state. - cd $BUILD_DIR/rrdtool-1.3rc7 + cd $BUILD_DIR/rrdtool-1.3.2 ./configure --prefix=$INSTALL_DIR --disable-tcl --disable-python $MAKE clean $MAKE $MAKE install SOLARIS HINT: if you want to build the perl module for the native perl (the -one shipping with Solaris) you will need the sun forte compiler installed on +one shipping with Solaris) you will need the Sun Forte compiler installed on your box or you have to hand-tune bindings/perl-shared/Makefile while building!