use -fPIC to build on Linux
fix test: create temp directory recursively
add test directory to .gitignore
Merge pull request #1 from catwell/master

Small tweaks