Skip to content

Latest commit

 

History

9 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

swigTest

Testing swig for generating python and matlab wrappers.

Building

Prerequisites

In order to build the project you need:

  • python
  • matlab
  • swig

SWIG with matlab support

If you need the matlab wrapper then you should switch to a developer version of swig. You need to checkout the matlab branch from the swig repository

git clone --branch matlab https://github.com/swig/swig.git

Please refer to http://www.swig.org/svn.html for the necessary tools needed to build. and then install it:

cd swig
./autogen.sh 
./configure --prefix=`pwd`/build/install --with-matlab=/Applications/MATLAB_R2015b.app/
make -j8
make install

Change --prefix=<install_path> to any directory where you want to install swig. Change --with-matlab=<matlabroot> to the root path of your matlab installation (note it will look for matlab binaries into <matlabroot>/bin).

Then at cmake stage you have to pass -DCMAKE_PREFIX_PATH=<install_path> so that the installed version can be found (unless you install in a system directory).

Building the wrappers

The generation of the wrappers is controlled by two cmake options:

option(BUILD_MATLAB_WRAPPER "Build the matlab wrapper with SWIG" ON)
option(BUILD_PYTHON_WRAPPER "Build the python wrapper with SWIG" ON)

so you can change the behaviour at cmake stage with eg -DBUILD_MATLAB_WRAPPER:BOOL=OFF.

About

Testing swig

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages