1 /*============================================================================
2 CMake - Cross Platform Makefile Generator
3 Copyright 2000-2009 Kitware, Inc., Insight Software Consortium
5 Distributed under the OSI-approved BSD License (the "License");
6 see accompanying file Copyright.txt for details.
8 This software is distributed WITHOUT ANY WARRANTY; without even the
9 implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10 See the License for more information.
11 ============================================================================*/
12 #ifndef cmExportLibraryDependenciesCommand_h
13 #define cmExportLibraryDependenciesCommand_h
15 #include "cmCommand.h"
17 /** \class cmExportLibraryDependenciesCommand
18 * \brief Add a test to the lists of tests to run.
20 * cmExportLibraryDependenciesCommand adds a test to the list of tests to run
23 class cmExportLibraryDependenciesCommand : public cmCommand
27 * This is a virtual constructor for the command.
29 virtual cmCommand* Clone()
31 return new cmExportLibraryDependenciesCommand;
35 * This is called when the command is first encountered in
36 * the CMakeLists.txt file.
38 virtual bool InitialPass(std::vector<std::string> const& args,
39 cmExecutionStatus &status);
42 * This is called at the end after all the information
43 * specified by the command is accumulated.
45 virtual void FinalPass();
46 virtual bool HasFinalPass() const { return true; }
49 * The name of the command as specified in CMakeList.txt.
51 virtual const char* GetName() const { return "export_library_dependencies";}
54 * Succinct documentation.
56 virtual const char* GetTerseDocumentation() const
58 return "Deprecated. Use INSTALL(EXPORT) or EXPORT command.";
64 virtual const char* GetFullDocumentation() const
67 "This command generates an old-style library dependencies file. "
68 "Projects requiring CMake 2.6 or later should not use the command. "
69 "Use instead the install(EXPORT) command to help export targets "
70 "from an installation tree and the export() command to export targets "
71 "from a build tree.\n"
72 "The old-style library dependencies file does not take into account "
73 "per-configuration names of libraries or the LINK_INTERFACE_LIBRARIES "
75 " export_library_dependencies(<file> [APPEND])\n"
76 "Create a file named <file> that can be included into a CMake listfile "
77 "with the INCLUDE command. The file will contain a number of SET "
78 "commands that will set all the variables needed for library dependency "
79 "information. This should be the last command in the top level "
80 "CMakeLists.txt file of the project. If the APPEND option is "
81 "specified, the SET commands will be appended to the given file "
82 "instead of replacing it.";
85 /** This command is kept for compatibility with older CMake versions. */
86 virtual bool IsDiscouraged() const
91 cmTypeMacro(cmExportLibraryDependenciesCommand, cmCommand);
96 void ConstFinalPass() const;