Updates to build.sh
Formatting, build, and include guard fixes
Removed unnecessary dynamic memory allocations with mem leaks
Fix compiler warnings
Removed use of malloc/free
Updated interface to prevent unnecessary copies and memory leaks
Updated SWIG file
Updated and cleaned up tests
Addressed Charles' comment about default repo URL
Fix typo after var rename in build.sh
Improved const-correctness and used C++-recommended cast operators
Merge pull request #1 from tanadeau/master

Bug fixes and convention updates