<html>
<head>
-<title>graphviz build notes</title>
+<title>Graphviz build notes</title>
</head>
<body bgcolor=#ffffff>
<h1>graphviz build notes</h1>
and configure will build graphviz with reduced functionality
if an external library is not found. Newer versions of these
libraries should be fine - if not, please let us know.
+<p>
+A list of these external libraries can be found on the Graphviz
+<A HREF="http://www.graphviz.org/Download_source.php">source download page</A>.
+<h3>Notes:</h2>
<ul>
-<li>GD (generic raster graphics driver for PNG, GIF, JPEG)
-<a href="http://www.boutell.com/gd/http/gd-2.0.28.tar.gz">
-http://www.boutell.com/gd/http/gd-2.0.28.tar.gz</a>
-<br>Graphviz also contains a copy of GD 2.0.4, but we will
+<li>GD (generic raster graphics driver for PNG, GIF, JPEG)<br>
+Graphviz contains a copy of libgd, but we hope to
remove it eventually so the external library is preferred.
-<li>ZLIB (raster image compression)
-<a href="http://www.zlib.net/zlib-1.2.3.tar.gz">
-http://www.zlib.net/zlib-1.2.3.tar.gz</a>
-<br>
+<li>ZLIB (raster image compression)<br>
NB: Use "./configure -s" to build shared libraries. (See notes in zlib-1.2.3/Makefile)
-<li>FREETYPE (renders text in raster graphics formats)
-<a href="http://prdownloads.sourceforge.net/freetype/freetype-2.1.3.tar.gz">
-http://prdownloads.sourceforge.net/freetype/freetype-2.1.3.tar.gz</a>
-<li>PNG (driver for Portable Network Graphics raster format)
-<a href="http://prdownloads.sourceforge.net/libpng/libpng-1.2.5.tar.gz">
-http://prdownloads.sourceforge.net/libpng/libpng-1.2.5.tar.gz</a>
-<li>JPEG (a popular raster format with lossy compression, not critical here)
-<a href="ftp://ftp.uu.net/graphics/jpeg/jpegsrc.v6b.tar.gz">
-ftp://ftp.uu.net/graphics/jpeg/jpegsrc.v6b.tar.gz</a>
-<li>EXPAT (XML parser)
-<a href="http://prdownloads.sourceforge.net/expat/expat-1.95.5.tar.gz">
-http://prdownloads.sourceforge.net/expat/expat-1.95.5.tar.gz</a>
-<li>GETTEXT (gcc compatibility library)
-<a href="http://ftp.gnu.org/gnu/gettext/gettext-0.11.5.tar.gz">
-http://ftp.gnu.org/gnu/gettext/gettext-0.11.5.tar.gz</a>
-<li>ICONV (string converstion for text internationalization)
-(Many systems already provide iconv in glibc. Check to see if you already
-have a working /usr/bin/iconv before installing this extra package.)
-<br>
-<a href="http://ftp.gnu.org/gnu/libiconv/libiconv-1.8.tar.gz">
-http://ftp.gnu.org/gnu/libiconv/libiconv-1.8.tar.gz</a>
-<li>TCL (a command interpreter for the tcldot GUI)
-<a href="http://prdownloads.sourceforge.net/tcl/tcl8.3.5-src.tar.gz">
-http://prdownloads.sourceforge.net/tcl/tcl8.3.5-src.tar.gz</a>
-<li>LIBTOOL (generic library support)
-<a href="ftp://ftp.gnu.org/pub/gnu/libtool/libtool-1.5.22.tar.gz">
-ftp://ftp.gnu.org/pub/gnu/libtool/libtool-1.5.22.tar.gz
-</a>
</ul>
<P>
These libraries (either static or dynamic) and their
or installable from packages included in the distribution.
You might need to install some -devel packages to get the include
header files.
+Also, some of these packages require other packages, so for sanity,
+you should use some automated install mechanism such as rpms or macports,
+or look for complete packages.
-<h2>Abbreviated Build Instructions (GNU tools)</h2>
+<h2>Abbreviated Build Instructions</h2>
-<p>If you are using GNU tools, the recommended method for building
-graphviz is the usual:
+<p>The recommended method for building graphviz from a downloaded
+source package is the usual:
<pre>
./configure
make
make install
</pre>
-
<p>If you are building from CVS sources, then you must have
recent versions of "libtool", "automake", and "autoconf".
Build with:
<h2>Detailed Build Instructions</h2>
-<P>
-There are a handful of preprocessor defines that control the
-image driver configuration. These preprocessor defines need to
-agree with the libraries used in the Makefile.
+<p>
+The preferred image renderer is cairo, with support from pango
+for fonts. This handles various bitmap formats as well as svg,
+pdf and PostScript.
<p>
The generic raster driver is <tt>gd</tt> and it can be configured to
generate GIF (no compression), PNG (lossless compression), JPEG
(lossy compression), and wireless bitmap (WBMP) files.
-The compressors all need <tt>zlib</tt>. In the current build we
-have a top-level config.h file that defines various symbols, such as:
+The compressors all need <tt>zlib</tt>. In the current build, we
+use a top-level config.h file that defines various symbols, such as:
<P>
HAVE_JPEG<br>
HAVE_PNG<br>
<P>
+This file is typically generated by configure based on how you
+invoke it and what it finds on your system.
If you don't enable the <tt>gd</tt> based drivers, graphviz will
-still have the <tt>printf</tt> style drivers for Postscript and SVG.
+still have the <tt>printf</tt> style drivers for PostScript and SVG.
(However, even these benefit from better text size estimation via
Freetype, when it is available.)
<P>
<h2>Build tools for Unix</h2>
You have several choices.
<P>
-1. (Recommended for Linux) Use configure generated by GNU autoconf.
+1. (Recommended - requires gmake) Use configure generated by GNU autoconf.
+This comes with the source packages.
This often works well on a vanilla Linux distribution with
Tcl/Tk, freetype-devel and libjpeg already installed by root
-under /usr. Probably works OK with Solaris, too.
-Otherwise some adjusting of command line arguments
-to <tt>configure</tt> will be needed.
+under /usr. It works OK with other versions of Unix, but
+some adjusting of command line arguments
+to <tt>configure</tt> may be needed.
For Linux you can also just pick up the source tarball
-or RPMs <A HREF="http://www.graphviz.org/pub/graphviz/">here</A>.
+or RPMs <A HREF="http://www.graphviz.org/Download..php/">here</A>.
<P>
First, if you are using sources from CVS, run "./autogen.sh"
to generate the "configure" script. If you are using sources
If you have problems with one or more of the optional script language bindings,
they can be disabled with e.g. --disable-perl.
<p>
-2. (Recommend for other Unix platforms.) As above, you need
-the external packages to be installed somewhere.
+When configure is finished, it reports which optional packages were
+found and which Graphviz features are enabled. If some package or
+feature you expected is not shown as used, you may need to check
+the config.log file or configure.ac or configure files to see what
+went wrong. Usually, any problem can be resolved using environment
+variables or the command-line flags of configure.
+<p>
+Once configure has finished, complete the build with
+<pre>
+gmake
+gmake install
+</pre>
+2. To avoid the use of configure and gmake, the source package comes with
+a collection of simple non-GNU makefiles. As above, you need
+the external packages to be installed somewhere. Then
<ul>
<li>
Run configure.old from the root graphviz directory.
In particular, set the ARCH make variable.
<li>
If desired, check settings in makearch/$(ARCH).
-See below for further notes on individual platforms.
<li>
-Run make.
+Run make and make install.
</ul>
-<pre>
-make
-make install
-make clean
-</pre>
-<P>
-3. (Recommended for Dave Korn and Eleftheris Koutsofios) Use AT&T/Lucent
-<A HREF="http://www.research.att.com/sw/tools/reuse/packages/astkit.html">nmake</A>.
-<P>
-You have to install the AST tools first.
-<P>
-Then edit Makeargs in the top source directory appropriately
-and <tt>nmake install</tt>. Some fiddling with X11 libs is probably
-necessary to compile 'lefty'. This usually involes editing
-$INSTALLROOT/lib/lib/Xt or X11 (or less portably, edit nmakefile).
-You may also need...
-<pre>
-export PACKAGE_tcl=/where/tcl/is/installed
-</pre>
-<P>
-When nmake works, it's absolutely great, but it's usually
-some work to get the environment right including the
-actions of tools like <tt>iffe</tt> (the AST equivalent
-of what GNU <tt>configure</tt> does). If you're Lefty
-or Dave Korn, you already knew that.
-<P>
<h2>Build tools for win32</h2>
<p>See separate
-<A HREF="http://www.graphviz.org/pub/scm/graphviz2/doc/winbuild.html">
-build notes</A> for Microsoft Windows (in native mode).
+<A HREF="http://www.graphviz.org/doc/winbuild.html">
+build notes</A> for Microsoft Windows.
<p>
With some persistence you can likely get Graphviz to build on
<A HREF="http://www.research.att.com/sw/tools/uwin">UWIN</A>
<h2>Apple Mac OS/X</h2>
<P>
-Currently, PixelGlow (Glen Low) provides a full featured
-<A HREF="http://www.pixelglow.com/graphviz/">
-port of Graphviz</A> including a very nice Aqua-based graph
-document container. Highly recommended. We merged his patches
-into our source, but we don't build or test on OS X. Talk to Glen.
-<P>
-The following are old pre-Pixelglow build notes:
-<P>
-dot and neato build with old make. (Didn't bother with tcldot.)
-<P>
-There could still be problems with case-sensitive names,
-though we fixed all the ones we could find.
+Currently, Glen Low provides a full-featured
+<A HREF="http://www.graphviz.org/Download_macos.php">
+port of Graphviz</A>.
+Also, Ryan Schmidt maintains versions of Graphviz for macports.
<P>
-It's weird that Mac OSX declares lrand48() but it's not
-defined in any of the standard system library functions.
+We recommend using macports to install the desired third-party
+libraries. Once these have been installed,
+the standard build using configure and make works fine. The only caveat
+is that sometimes, an incompatible, non-GNU tool is picked up
+rather than the needed GNU version.
<h2>GNU style building</h2>