Converted Makefiles to use libtool

Since we're going to be using a number of shared libraries, something like
libtool makes building things so much easier.  We've now got the shared
libraries back, and did some cleanup on the include paths.  Local includes
now need a relative path, rather than just adding a -I flag to the compile.
.gitignore now ignores artifacts of the libtool builds.

Also noticed a possible format-string vulnerability within Log, so that
should be resolved.