Just install gcc-7 package from buster repo and cmake complains with this error message c++: fatal error: '-c' is not a valid option to the preprocessor as shown below. Has anyone seen this issue?
CMake Error at /usr/share/cmake-3.10/Modules/CMakeTestCXXCompiler.cmake:45 (message):
The C++ compiler
"/usr/bin/c++"
is not able to compile a simple test program.
It fails with the following output:
Change Dir: /home/local/PEOPLE/debian/works/C++/BMP/bmp-6/build/CMakeFiles/CMakeTmp
Run Build Command:"/usr/bin/make" "cmTC_3f125/fast"
/usr/bin/make -f CMakeFiles/cmTC_3f125.dir/build.make CMakeFiles/cmTC_3f125.dir/build
make[1]: Entering directory '/home/local/PEOPLE/debian/works/C++/BMP/bmp-6/build/CMakeFiles/CMakeTmp'
Building CXX object CMakeFiles/cmTC_3f125.dir/testCXXCompiler.cxx.o
/usr/bin/c++ -o CMakeFiles/cmTC_3f125.dir/testCXXCompiler.cxx.o -c
/home/local/PEOPLE/debian/works/C++/BMP/bmp-6/build/CMakeFiles/CMakeTmp/testCXXCompiler.cxx
c++: fatal error: '-c' is not a valid option to the preprocessor
compilation terminated.
CMakeFiles/cmTC_3f125.dir/build.make:65: recipe for target 'CMakeFiles/cmTC_3f125.dir/testCXXCompiler.cxx.o' failed
make[1]: *** [CMakeFiles/cmTC_3f125.dir/testCXXCompiler.cxx.o] Error 1
make[1]: Leaving directory '/home/local/PEOPLE/debian/works/C++/BMP/bmp-6/build/CMakeFiles/CMakeTmp'
Makefile:126: recipe for target 'cmTC_3f125/fast' failed
make: *** [cmTC_3f125/fast] Error 2