summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefile.cxx
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2002-05-02 19:10:19 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2002-05-02 19:10:19 (GMT)
commit2242006ca1f6834059d23b761dafd4ad7e70661b (patch)
tree25234eab987916695cbe4202d2548b8c61def63e /Source/cmMakefile.cxx
parent4fe8947bcc725396a6bb85720c6836d81d100dd7 (diff)
downloadCMake-2242006ca1f6834059d23b761dafd4ad7e70661b.zip
CMake-2242006ca1f6834059d23b761dafd4ad7e70661b.tar.gz
CMake-2242006ca1f6834059d23b761dafd4ad7e70661b.tar.bz2
Debug optimized cache fixes
Diffstat (limited to 'Source/cmMakefile.cxx')
-rw-r--r--Source/cmMakefile.cxx17
1 files changed, 9 insertions, 8 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index 4c31efa..55acc50 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -665,7 +665,16 @@ void cmMakefile::AddLibrary(const char* lname, int shared,
default:
target.SetType(cmTarget::STATIC_LIBRARY);
}
+ // Clear its dependencies. Otherwise, dependencies might persist
+ // over changes in CMakeLists.txt, making the information stale and
+ // hence useless.
+ std::string depname = lname;
+ depname += "_LIB_DEPENDS";
+ cmCacheManager::GetInstance()->
+ AddCacheEntry(depname.c_str(), "",
+ "Dependencies for target", cmCacheManager::INTERNAL);
+
target.SetInAll(true);
target.GetSourceLists() = srcs;
std::vector<std::string>::iterator j;
@@ -723,14 +732,6 @@ void cmMakefile::AddLibrary(const char* lname, int shared,
cmCacheManager::INTERNAL);
}
- // Clear its dependencies. Otherwise, dependencies might persist
- // over changes in CMakeLists.txt, making the information stale and
- // hence useless.
- std::string depname = lname;
- depname += "_LIB_DEPENDS";
- cmCacheManager::GetInstance()->
- AddCacheEntry(depname.c_str(), "",
- "Dependencies for target", cmCacheManager::INTERNAL);
}
void cmMakefile::AddExecutable(const char *exeName,