Added support for the source version of gtsam

This adds support for using the source version of gtsam