summaryrefslogtreecommitdiffstats
path: root/Source/cmCPluginAPI.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmCPluginAPI.cxx')
-rw-r--r--Source/cmCPluginAPI.cxx18
1 files changed, 9 insertions, 9 deletions
diff --git a/Source/cmCPluginAPI.cxx b/Source/cmCPluginAPI.cxx
index 7da334e..fb78446 100644
--- a/Source/cmCPluginAPI.cxx
+++ b/Source/cmCPluginAPI.cxx
@@ -51,14 +51,14 @@ void CCONV cmSetError(void *info, const char *err)
unsigned int CCONV cmGetCacheMajorVersion(void *arg)
{
cmMakefile *mf = static_cast<cmMakefile *>(arg);
- cmCacheManager *manager = mf->GetCMakeInstance()->GetCacheManager();
- return manager->GetCacheMajorVersion();
+ cmState *state = mf->GetState();
+ return state->GetCacheMajorVersion();
}
unsigned int CCONV cmGetCacheMinorVersion(void *arg)
{
cmMakefile *mf = static_cast<cmMakefile *>(arg);
- cmCacheManager *manager = mf->GetCMakeInstance()->GetCacheManager();
- return manager->GetCacheMinorVersion();
+ cmState *state = mf->GetState();
+ return state->GetCacheMinorVersion();
}
unsigned int CCONV cmGetMajorVersion(void *)
@@ -116,7 +116,7 @@ const char* CCONV cmGetProjectName(void *arg)
{
cmMakefile *mf = static_cast<cmMakefile *>(arg);
static std::string name;
- name = mf->GetProjectName();
+ name = mf->GetStateSnapshot().GetProjectName();
return name.c_str();
}
@@ -373,13 +373,13 @@ void CCONV cmAddLinkLibraryForTarget(void *arg, const char *tgt,
switch (libtype)
{
case CM_LIBRARY_GENERAL:
- mf->AddLinkLibraryForTarget(tgt,value, cmTarget::GENERAL);
+ mf->AddLinkLibraryForTarget(tgt,value, GENERAL_LibraryType);
break;
case CM_LIBRARY_DEBUG:
- mf->AddLinkLibraryForTarget(tgt,value, cmTarget::DEBUG);
+ mf->AddLinkLibraryForTarget(tgt,value, DEBUG_LibraryType);
break;
case CM_LIBRARY_OPTIMIZED:
- mf->AddLinkLibraryForTarget(tgt,value, cmTarget::OPTIMIZED);
+ mf->AddLinkLibraryForTarget(tgt,value, OPTIMIZED_LibraryType);
break;
}
}
@@ -395,7 +395,7 @@ void CCONV cmAddLibrary(void *arg, const char *libname, int shared,
srcs2.push_back(srcs[i]);
}
mf->AddLibrary(libname,
- (shared? cmTarget::SHARED_LIBRARY : cmTarget::STATIC_LIBRARY),
+ (shared? cmState::SHARED_LIBRARY : cmState::STATIC_LIBRARY),
srcs2);
}