Merge pull request #1 from snoweye/master

Updates
registering native routines with R
added some tests
fixed finalize prototype, cleaned up ~ files
Merge pull request #9 from wrathematics/master

Registering native routines with R