cmUnixDefinesRule.cxx 530 B

12345678910111213141516171819202122232425
  1. #include "cmUnixDefinesRule.h"
  2. cmUnixDefinesRule::cmUnixDefinesRule()
  3. {
  4. #if defined(_WIN32) && !defined(__CYGWIN__)
  5. this->SetEnableOff();
  6. #endif
  7. }
  8. // cmUNIXDefinesRule
  9. bool cmUnixDefinesRule::Invoke(std::vector<std::string>& args)
  10. {
  11. if(args.size() < 1 )
  12. {
  13. this->SetError("Win32Defines called with incorrect number of arguments");
  14. return false;
  15. }
  16. for(std::vector<std::string>::iterator i = args.begin();
  17. i != args.end(); ++i)
  18. {
  19. m_Makefile->AddDefineFlag((*i).c_str());
  20. }
  21. return true;
  22. }