Use g++ instead of gcc.