Modify Makefile to build shared library
Remove un-necessary and not working checks