Fixed Merge Issues

Fixed a handful of build issues stemming from merging the code. Also committing R-related files, though I'm not sure they're necessary.