From: erg Date: Fri, 4 Jan 2008 18:48:16 +0000 (+0000) Subject: Update windows build notes with comments on building on Mingw. X-Git-Tag: LAST_LIBGRAPH~32^2~4912 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=06515cc55af5895c537cb340aea868a366154cac;p=graphviz Update windows build notes with comments on building on Mingw. --- diff --git a/doc/winbuild.html b/doc/winbuild.html index 501860ef4..c95bafe38 100644 --- a/doc/winbuild.html +++ b/doc/winbuild.html @@ -46,7 +46,77 @@ Build Graphviz:

make install

-Presumably, a similar approach would work with Cygwin or Mingw. If you +Presumably, a similar approach would work with Cygwin or Mingw. +The following are some notes by +Steve Roush +describing how he +made a static build of the libraries on Mingw. +

+
  • Install MinGW and Msys. This gives a mini GNU-like compile environment +that produces Windows-compatible results. +
  • You may need to configure and build in Windows "Safe mode". Try +./configure in normal mode; if it dies with "fork" problems, use Safe mode. +
  • Edit the "configure" file.
    + after this line:
    + DEFS=-DHAVE_CONFIG_H
    + add these lines:
    + +
    +    case "$host_os" in
    +     mingw*)
    +       DEFS="$DEFS -DWIN32 -DMSWIN32"
    +       ;;
    +     esac
    +
    +
    +
  • run configure:
    + +
    +   ./configure  --enable-static=yes --enable-shared=no 
    +--prefix=/usr/local/ --with-libgd=no --enable-ltdl=no --disable-swig  
    +--disable-sharp --disable-guile --disable-io --disable-java 
    +--disable-lua --disable-ocaml --disable-perl --disable-php 
    +--disable-python --disable-ruby --disable-tcl
    +
    +
    +
  • edit lib/Makefile
    + replace these lines:
    + +
    + SUBDIRS = cdt graph agraph gd pathplan agutil sfio vmalloc ast vpsc \
    +     circogen dotgen fdpgen neatogen twopigen common pack gvc \
    +     ingraphs expr
    +
    +
    + + with these lines:
    + +
    + SUBDIRS = cdt graph agraph gd pathplan  vpsc \
    +    circogen dotgen fdpgen neatogen twopigen common pack gvc \
    +    ingraphs
    +
    +make  # builds most of "lib" (see Makefile changes), cmd/dot and 
    +cmd/tools - stops on cmd/gvpr
    +make install
    +
    +
    +
  • +here is the command line I used to build "simple.c" (dot.demo/simple.c), +after adding a few lines based on +https://mailman.research.att.com/pipermail/graphviz-interest/2006q2/003586.html + + + +
    +X=simple;gcc -v -I'/usr/local/include/graphviz' -I'/usr/local/include' 
    +-o $X -O $X.c  -L/usr/local/lib -L/usr/local/lib/graphviz -lgvc  -lgraph 
    +-lpathplan -lcdt -lgvplugin_core -lgvplugin_dot_layout 
    +-lgvplugin_neao_layout -lgvplugin_gd -lgvplugin_pango -lgvc -lpathplan
    +
    +
    +

    +If you desire to build directly using Visual Studio or other non-Unix-based environment, you will need to derive the necessary information from the supplied Makefiles.