Bug fix: prevent the trashing of LDFLAGS.
Merge pull request #133 from satterly/master

Fix configure and makefiles so build process is more robust
Merge pull request #132 from zaitseff/master

Bug fix: prevent the trashing of LDFLAGS.