Fix some small bugs in the makefile template.

- GCC in C++ mode should be called g++ not gcc.
- ICC in C++ mode should be called icpc not icc.
- Don't explicitly link against libstdc++.