Building and Installing in a UNIX-like Environment using the GPSTk script

The following procedure will build and install the GPSTk under the following environments.
Linux & Solaris
The following procedure will build and install the GPSTk.
  1. Ensure that prerequisites such as CMake have been installed.
  2. Download the GPSTk source distribution.
  3. Extract the GPSTk tarball. For example, using GNU tar
    tar xvzf gpstk.tar.gz
  4. Navigate to the root GPSTk directory
  5. Run the GPSTk script with the desired parameters
    Build and Install using default paths
    $ ./build.sh [-h] [-cdeusxtpv] [-b ] [-i ] [-j ] [-P ]
    -h Display this help message.

    -b <build_path> Specify the cmake build directory to use.

    -i <install_prefix> Install the build to the given path.

    -j <num_threads> Number of threads to have make use. Defauts to $num_threads on host

    -c Clean out any files in the build dir prior to running cmake.

    -d Build documentation, including generate dependency graphs
    using GraphViz (.DOT and .PDF files).

    -e GPSTk has several parts: core, ext, and python/swig bindings.
    See README.txt for details.
    Default (without -e) will build only core
    Optional (with -e) will build core, ext, and swig

    -u Install the build to the path in the \$gpstk environment variable.
    If this variable is not set, it will be installed to
    $user_install_prefix.

    -s Install the build into $system_install_prefix and the python
    bindings to the default system location. Make sure the build path
    is writable by root.

    -x Disable building the python bindings. Default is to build them
    if -e is specified.

    -P <python_exe> Python executable used to help determine with python system libraries
    will be used when building python extension package.
    Default=$python_exe

    -t Build and run tests.

    -p Build supported packages (source, binary, deb, ...)

    -v Include debugging output.

    Notes:
    Remember to add user and non-standard locations to your environment. Eg:
    $ export LD_LIBRARY_PATH=/tmp/test/gpstk/lib:\$LD_LIBRARY_PATH
    $ export PYTHONPATH=/tmp/test/lib/python2.7/site-packages:\$PYTHONPATH

Building and Installing in a UNIX-like Environment using CMake

The following procedure will build and install the GPSTk under the following environments.
Linux & Solaris
The following procedure will build and install the GPSTk.
  1. Ensure that prerequisites such as CMake have been installed.
  2. Download the GPSTk source distribution.
  3. Extract the GPSTk tarball. For example, using GNU tar
    tar xvzf gpstk.tar.gz
  4. Create a directory for your build. For example, change into the gpstk/directory and type
    mkdir build
  5. Change into the gpstk/build directory, this will be where all of the build files will reside.
  6. If GPSTk Core will be installed as a system library in /usr/local, execute the following commands:
    cmake ../ 
    make
    To install to a different directory, the install directory must be set-up when CMake configures the makefiles, add the following command:
    -DCMAKE_INSTALL_PREFIX:PATH=/path/to/install 
    To build GPSTk with Ext, in addition to Core, add the following command:
    -DBUILD_EXT=ON
    To turn on processing of python extension package, add the following command:
     -DBUILD_PYTHON=ON
    To turn on test mode, add the following command:
     -DTEST_SWITCH=ON 
    Example - Command for building GPSTk with core, ext, python, and test code and installing to sytem library in /usr/local:
     cmake -DBUILD_EXT=ON -DBUILD_PYTHON=ON -DTEST_SWITCH=ON ../ 
    make
  7. To test GPSTk (if Test_Switch=ON), execute
    make test
  8. To install GPSTk, execute
    make install
  9. To build the source documentation using doxygen: Change into the gpstk/dev directory (if using Developer repo) or the gpstk/directory (if using the tarball), and type
    doxygen 
Topic revision: r20 - 08 Jan 2016, BryanParsons
 

This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback