Fix Makefile: support Linux, respect env

Add support fox Linux.
Respect CC, CXX, CFLAGS, CXXFLAGS, LDFLAGS, DESTDIR.
Fix building with '-Wl,--as-needed'.
Fix 'make install'.
Link only to required libs.
Add missing rules, remove rules for non existing files.

Solves issue #3 and issue #15
Merge remote-tracking branch 'nikoli/build_system2'

Conflicts:
	Makefile