[Cmake] file.C not seen as C++ source file

Peter Vanroose Peter.Vanroose at esat.kuleuven.ac.be
Tue Apr 1 04:00:32 EST 2003


I'm trying to use CMake to compile C++ files with extension .C
but it seems that CMake thinks these are C source files, despite
the fact that CMake/Source/cmSystemTools.cxx at around line 2286
seems to indicate that only ".c" is seen as C file extension.

This happens both with gcc on Linux and on an SGI with its native
compiler, so no DOS lowercase mapping can be involved.
Below is an extract from the generated Makefile.

Any idea what goes wrong?


--	Peter Vanroose



#---------------------------------------------------------
# object file
#

MatOps.o: /disk1/Numerics/math/MatOps.C
	echo "Building object file MatOps.o..."
	gcc -o MatOps.o  -g -fPIC  $(INCLUDE_FLAGS)  -c /disk1/Numerics/math/MatOps.C



More information about the CMake mailing list