You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

70 lines
2.5 KiB

ENH: merge CMake-CrossCompileBasic to HEAD -add a RESULT_VARIABLE to INCLUDE() -add CMAKE_TOOLCHAIN_FILE for specifiying your (potentially crosscompiling) toolchain -have TRY_RUN() complain if you try to use it in crosscompiling mode (which were compiled but cannot run on this system) -use CMAKE_EXECUTABLE_SUFFIX in TRY_RUN(), probably TRY_RUN won't be able to run the executables if they have a different suffix because they are probably crosscompiled, but nevertheless it should be able to find them -make several cmake variables presettable by the user: CMAKE_C/CXX_COMPILER, CMAKE_C/CXX_OUTPUT_EXTENSION, CMAKE_SYSTEM_NAME, CMAKE_SYSTEM_INFO_FILE -support prefix for GNU toolchains (arm-elf-gcc, arm-elf-ar, arm-elf-strip etc.) -move ranlib on OSX from the file command to a command in executed in cmake_install.cmake -add support for stripping during install in cmake_install.cmake -split out cl.cmake from Windows-cl.cmake, first (very incomplete) step to support MS crosscompiling tools -remove stdio.h from the simple C program which checks if the compiler works, since this may not exist for some embedded platforms -create a new CMakeFindBinUtils.cmake which collects the search fro ar, ranlib, strip, ld, link, install_name_tool and other tools like these -add support for CMAKE_FIND_ROOT_PATH for all FIND_XXX commands, which is a list of directories which will be prepended to all search directories, right now as a cmake variable, turning it into a global cmake property may need some more work -remove cmTestTestHandler::TryExecutable(), it's unused -split cmFileCommand::HandleInstall() into slightly smaller functions Alex
18 years ago
ENH: merge CMake-CrossCompileBasic to HEAD -add a RESULT_VARIABLE to INCLUDE() -add CMAKE_TOOLCHAIN_FILE for specifiying your (potentially crosscompiling) toolchain -have TRY_RUN() complain if you try to use it in crosscompiling mode (which were compiled but cannot run on this system) -use CMAKE_EXECUTABLE_SUFFIX in TRY_RUN(), probably TRY_RUN won't be able to run the executables if they have a different suffix because they are probably crosscompiled, but nevertheless it should be able to find them -make several cmake variables presettable by the user: CMAKE_C/CXX_COMPILER, CMAKE_C/CXX_OUTPUT_EXTENSION, CMAKE_SYSTEM_NAME, CMAKE_SYSTEM_INFO_FILE -support prefix for GNU toolchains (arm-elf-gcc, arm-elf-ar, arm-elf-strip etc.) -move ranlib on OSX from the file command to a command in executed in cmake_install.cmake -add support for stripping during install in cmake_install.cmake -split out cl.cmake from Windows-cl.cmake, first (very incomplete) step to support MS crosscompiling tools -remove stdio.h from the simple C program which checks if the compiler works, since this may not exist for some embedded platforms -create a new CMakeFindBinUtils.cmake which collects the search fro ar, ranlib, strip, ld, link, install_name_tool and other tools like these -add support for CMAKE_FIND_ROOT_PATH for all FIND_XXX commands, which is a list of directories which will be prepended to all search directories, right now as a cmake variable, turning it into a global cmake property may need some more work -remove cmTestTestHandler::TryExecutable(), it's unused -split cmFileCommand::HandleInstall() into slightly smaller functions Alex
18 years ago
  1. /*=========================================================================
  2. Program: CMake - Cross-Platform Makefile Generator
  3. Module: $RCSfile$
  4. Language: C++
  5. Date: $Date$
  6. Version: $Revision$
  7. Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
  8. See Copyright.txt or http://www.cmake.org/HTML/Copyright.html for details.
  9. This software is distributed WITHOUT ANY WARRANTY; without even
  10. the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
  11. PURPOSE. See the above copyright notices for more information.
  12. =========================================================================*/
  13. #ifndef cmInstallTargetGenerator_h
  14. #define cmInstallTargetGenerator_h
  15. #include "cmInstallGenerator.h"
  16. #include "cmTarget.h"
  17. /** \class cmInstallTargetGenerator
  18. * \brief Generate target installation rules.
  19. */
  20. class cmInstallTargetGenerator: public cmInstallGenerator
  21. {
  22. public:
  23. cmInstallTargetGenerator(
  24. cmTarget& t, const char* dest, bool implib,
  25. const char* file_permissions = "",
  26. std::vector<std::string> const& configurations
  27. = std::vector<std::string>(),
  28. const char* component = "",
  29. bool optional = false
  30. );
  31. virtual ~cmInstallTargetGenerator();
  32. std::string GetInstallFilename(const char* config) const;
  33. static std::string GetInstallFilename(cmTarget*target, const char* config,
  34. bool implib, bool useSOName);
  35. protected:
  36. typedef cmInstallGeneratorIndent Indent;
  37. virtual void GenerateScript(std::ostream& os);
  38. void GenerateScriptForConfig(std::ostream& os,
  39. const char* fromDir,
  40. const char* config,
  41. Indent const& indent);
  42. void GenerateScriptForConfigDir(std::ostream& os,
  43. const char* fromDirConfig,
  44. const char* config,
  45. Indent const& indent);
  46. void AddInstallNamePatchRule(std::ostream& os, Indent const& indent,
  47. const char* config,
  48. const std::string& toDestDirPath);
  49. void AddStripRule(std::ostream& os, Indent const& indent,
  50. cmTarget::TargetType type,
  51. const std::string& toDestDirPath);
  52. void AddRanlibRule(std::ostream& os, Indent const& indent,
  53. cmTarget::TargetType type,
  54. const std::string& toDestDirPath);
  55. cmTarget* Target;
  56. bool ImportLibrary;
  57. std::string FilePermissions;
  58. bool Optional;
  59. };
  60. #endif