fixed makefile bug for g++4.6 link problem which has --as-needed by default