cmBuildSharedLibrariesCommand.cxx 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. /*=========================================================================
  2. Program: Insight Segmentation & Registration Toolkit
  3. Module: $RCSfile$
  4. Language: C++
  5. Date: $Date$
  6. Version: $Revision$
  7. Copyright (c) 2000 National Library of Medicine
  8. All rights reserved.
  9. See COPYRIGHT.txt for copyright details.
  10. =========================================================================*/
  11. #include "cmBuildSharedLibrariesCommand.h"
  12. // cmBuildSharedLibrariesCommand
  13. bool cmBuildSharedLibrariesCommand::Invoke(std::vector<std::string>& args)
  14. {
  15. // Now check and see if the value has been stored in the cache
  16. // already, if so use that value and don't look for the program
  17. const char* cacheValue
  18. = cmCacheManager::GetInstance()->GetCacheValue("BUILD_SHARED_LIBS");
  19. if(!cacheValue)
  20. {
  21. cmCacheManager::GetInstance()->AddCacheEntry("BUILD_SHARED_LIBS","0",
  22. cmCacheManager::BOOL);
  23. m_Makefile->AddDefinition("BUILD_SHARED_LIBS", "0");
  24. }
  25. else
  26. {
  27. m_Makefile->AddDefinition("BUILD_SHARED_LIBS", cacheValue);
  28. }
  29. return true;
  30. }