General Unix Build Instructions for the VTP Software

  1. Dependencies.  There are a lot of libraries that the VTP uses, but fortunately many of them are already included in most flavors of Unix/Linux, and several of them are optional.  Here is a dependency tree, with typical version numbers.  Generally, specific versions are not necessary for compatibility, except where noted.

    - TerrainApps (Applications VTBuilder, Enviro, etc.)
       - wxWidgets (wxGTK)              ver. 2.8.x
         - tiff                         ver. 3.5.5
         - jpeg                         ver. 6b
         - zlib                         ver. 1.2.3
       - TerrainSDK (Libraries vtdata, vtosg, vtui)
         - libpng                       ver. 1.2.12
         - OSG                          ver. 2.6 (should be at least 2.0)
           - OpenGL (glut,GLU,etc.)     ver. 1.2
         - libMini                      ver. 8.9.2 (exact version, svn rev 13xx)
         - GDAL                         ver. 1.5.x (must be at least 1.3.2)
           - PROJ.4                     ver. 4.4.9
         - netcdf                       ver. 3.5.0 (optional)
         - libcurl                      ver. 7.15.0 (optional)
     
  2. If you received the VTP on CDROM, then all the libraries are already present.
    Otherwise, you can download them.

    Library Download Library Website
    GDAL gdal-xxx.tar.gz http://www.gdal.org/
    PROJ.4 proj-xxx.tar.gz http://trac.osgeo.org/proj/
    OSG OSG downloads http://www.openscenegraph.org/
    wxWidgets wxGTK-xxx.tar.gz http://www.wxwidgets.org/
    libMini download page http://stereofx.org/terrain.html
    optional libraries:
    netCDF netcdf-xxx.ZIP http://www.unidata.ucar.edu/packages/netcdf/
      netCDF binaries are also available for download for just about every platform
    Libcurl download page http://curl.haxx.se/

  3. Build each dependent library.  See in the build instructions included with each, but first read this advice:
  4. Confirm that you have the data files installed for  GDAL and PROJ.4.
  5. Look at the file Make.defs.  It provide definitions for the Makefiles.  Most platform-specific build changes (compiler, flags, library locations, etc.) can be made here.
    Optionally, you set any of these flags to 1 to use an optional library:
    SUPPORT_QUIKGRID
    SUPPORT_NETCDF
    SUPPORT_HTTP   
    (for libcurl)
    SUPPORT_UNZIP
    SUPPORT_SQUISH
     
  6. Do a make in the TerrainSDK directory to build the VTP libraries.  Each library is created as a .so file (or .dylib on OS X), so you will need to do whatever your OS wants for dynamic libraries.  I've found it easiest (on Linux) to add the directories which contain the .so files to the library path (environment variable LD_LIBRARY_PATH, example in step 9).
     
  7. Do a make in the TerrainApps directory to build the VTP applications.
     
  8. In order for the shared libraries (.so) to be found at runtime, you need to either:

If you encounter build problems, the vtp-unix mailing list exists to answer any questions.