1. PREREQUISITES ================ In order to compile the OpenCTM shared library, all you need is a supported compiler and it should compile right out of the box. In order to compile the entire OpenCTM package, including documentation and the tools, there are some extra dependencies: - To build all the tools, you need GLUT, and for Un*x/X11 you also need GTK+ 2.0 (Ubuntu: sudo apt-get install libgtk2.0-dev). - To build the documentation you need Doxygen (www.doxygen.org), a full LaTeX installation (see TeX Live - http://www.tug.org/texlive/), and Groff (Windows: http://gnuwin32.sourceforge.net/packages/groff.htm, Mac OS X: preinstalled, Ubuntu: sudo apt-get install groff). 2. COMPILING ============ There are a few makefiles for different systems and compilers. Just pick the one that fits your system, and run "make" on the corresponding file. Here are a few specific instructions: 2.1 Windows, MinGW32 -------------------- mingw32-make -f Makefile.mingw 2.2 Windows, MS Visual Studio (Express) 2008 -------------------------------------------- nmake /f Makefile.msvc 2.3 Mac OS X ------------ make -f Makefile.macosx 2.4 Linux --------- make -f Makefile.linux 2.5 OpenSolaris --------------- gmake -f Makefile.linux 3. BUILD TARGETS ================ By default, the OpenCTM shared library and the OpenCTM tools are compiled when make is run. To select what is built, use one of the following build targets (just append it to the end of the make command line): openctm (the shared library) toolset (the tools) documentation (the HTML and PDF documentation) all (openctm + toolset + documentation) clean (clean all the built files - start from scratch) For instance, to just build the OpenCTM shared library under Windows with MS Visual Studio, type: nmake /f Makefile.msvc openctm 4. INSTALLATION =============== For Linux and Mac OS X, it is possible to make a system wide installation by using the "install" build target. The installation process will install the following: - OpenCTM shared library - OpenCTM C/C++ headers (inlcude files) - ctmconv and ctmviewer tools - Man pages Just make sure that the Makefile contains the correct (and desired) installation paths. Also, you need to have root privileges to make a system wide installation. For instance, to compile and install OpenCTM under Ubuntu, do: make -f Makefile.linux sudo make -f Makefile.linux install ...and to compile and install OpenCTM under Mac OS X, do: make -f Makefile.macosx sudo make -f Makefile.macosx install