Fix for static linking
Merge pull request #464 from proteneer/staticFix

Fix for static linking