= Building GGobi on Windows from Source = This document attempts to explain how to build GGobi (>= 2.0) for Windows. It assumes that the reader is reasonably familiar with building packages in linux. == Setup == === Required tools and libraries: === === MinGW: === The tools we use to build the GGobi distribution depend on having the [http://www.mingw.org MinGW/MSYS tools] installed. MinGW is Minimalist GNU for Windows, essentially gcc for Windows. MSYS is a build environment for MinGW. For MinGW, there are options within the installation that allow you to customize which packages are installed (this can also be done after the initial installation). First it asks you whether you want the previous, current, or candidate version. Go ahead and choose 'candidate' so that we're on the bleeding edge. The next step lets you decide which individual packages are installed. Be sure that you include the MinGW base tools and the g77 package (if you want to build Rggobi2, it's an R thing). You'll also want the [http://prdownloads.sourceforge.net/mingw/msysDTK-1.0.1.exe?download MSYS DTK] for tools like autoconf. Download and install these three packages. === GTK development environment: === Download the latest GTK+ [http://gladewin32.sourceforge.net/ developer package] and install it. === pkg-config: === The GTK developers pack includes pkg-config, but since we're using MSYS we need at least version 0.20. At the time of this writing, the included pkg-config is only 0.15, so we need to get the latest from the [http://www.gimp.org/~tml/gimp/win32/downloads.html GTK+ win32 downloads page]. Unzip it into the toplevel GTK directory. === GObject Builder: === You need the [http://http://www.5z.com/jirka/gob.html GObject builder] to build GGobi from SVN. First though you need the Flex library. Get the package offered by the [http://unxutils.sourceforge.net/ UnxUtils project] and move the contents of the `/usr/local/lib` directory in the zip file to your `/GTK/lib` directory. Now you can unpack the gob2 archive into your home directory, `configure`, `make`, and `make install` it. === Nullsoft Installer: === GGobi uses the nullsoft installation system, so if you want to build the GGobi installer (exe), download and install the latest [http://nsis.sourceforge.net/ nullsoft installer] now. === Subversion: === In order to get the latest source code, you'll need [http://subversion.tigris.org/ subversion]. === Path setup: === == Compilation: == Start MSYS. You will find yourself in your "user" directory. This is where we will do all of our work. Type `svn co http://ggobi.org/svn/ggobi ggobi` to grab the entire repository, including Rggobi2, the website, the GGobi book, etc. If you're not a core GGobi dev or you're only interested in GGobi itself, `svn co http://ggobi.org/svn/ggobi/ggobi/trunk ggobi` should do. Next, switch to the `~/ggobi/ggobi/trunk` (or `~/ggobi` if you only got GGobi) directory and type: `./configure --enable-local --with-plugins="DataViewer ggvis VarCloud DescribeDisplay"` and then `make`. Note that if you ever want to debug GGobi, you can add `--enable-debug` to the configure line. To enable the plugins you built, run `make ggobirc` now.
If you have trouble send an [mailto:ggobi-help@ggobi.org email], complete with the error messages you got in the MSYS window. We'll aim to help as possible. == Building the Self-installing Executable == To create the self-installing GGobi executable, we will use the Nullsoft Scriptable Installation System. Make sure that `iscc.exe` (the Inno compiler) is on your path.
Run `make win32-installer` to build the setup executable. = Building RGGobi on Windows: =
Follow the instructions for building ggobi on Windows in the ggobi distribution files. You'll at least need the same development environment. == Obtain necessary files == [http://www.ggobi.org/Download Download] the latest Rggobi and unpack it into `/c/build/src`. The R build system requires [http://www.activestate.com/store/languages/register.plex?id=ActivePerl ActivePerl]. Make sure it (`/c/perl`) is on your path. In order to build Windows help for the documentation, you need `hhc.exe` from the [http://msdn.microsoft.com/library/default.asp?url=/library/en-us/htmlhelp/html/hwMicrosoftHTMLHelpDownloads.asp HTML Help Workshop] on your path. Yes, I know it's from Microsoft, but you need it. == Build the binary R package == Enter the `Rggobi2` directory and run `./configure`. Now you have to hack the `build` perl script in the `R/bin` directory so that it doesn't prefix `cygwin` to paths when running tar. Finally, make sure R is on your path, and in the parent directory, run: {{{ Rcmd build --binary Rggobi2 }}} == Installing the package == Install the Rggobi package using the R menu for installing packages. You should be ready to start it up: {{{ > library(Rggobi2) > ggobi() }}} ---- These notes are by Michael Lawrence.