summaryrefslogtreecommitdiffstats
path: root/Source/cmTarget.cxx
diff options
context:
space:
mode:
authorAndy Cedilnik <andy.cedilnik@kitware.com>2002-10-06 16:12:59 (GMT)
committerAndy Cedilnik <andy.cedilnik@kitware.com>2002-10-06 16:12:59 (GMT)
commit9ed93397fbe57a09e2a510b45331fa925a392bf8 (patch)
tree6e0960bd96eca344d168bd6c1444e968e24b73de /Source/cmTarget.cxx
parent1ba0a050395fda65718da8e62a896ea788dec8e4 (diff)
downloadCMake-9ed93397fbe57a09e2a510b45331fa925a392bf8.zip
CMake-9ed93397fbe57a09e2a510b45331fa925a392bf8.tar.gz
CMake-9ed93397fbe57a09e2a510b45331fa925a392bf8.tar.bz2
If you specify header file as source, it should still use C compiler and not CXX. Also fix COnly test so that it make sure that this still works...
Diffstat (limited to 'Source/cmTarget.cxx')
-rw-r--r--Source/cmTarget.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index de92dab..1bb7a5b 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -206,7 +206,8 @@ bool cmTarget::HasCxx() const
for(std::vector<cmSourceFile*>::const_iterator i = m_SourceFiles.begin();
i != m_SourceFiles.end(); ++i)
{
- if((*i)->GetSourceExtension() != "c")
+ if((*i)->GetSourceExtension() != "c" &&
+ (*i)->GetSourceExtension() != "h")
{
return true;
}