CMake/Source/cmLinkLibrariesCommand.h

86 lines
2.1 KiB
C
Raw Normal View History

2001-01-11 16:04:28 +03:00
/*=========================================================================
Program: Insight Segmentation & Registration Toolkit
Module: $RCSfile$
Language: C++
Date: $Date$
Version: $Revision$
Copyright (c) 2000 National Library of Medicine
All rights reserved.
See COPYRIGHT.txt for copyright details.
=========================================================================*/
2001-01-18 19:20:24 +03:00
#ifndef cmLinkLibrariesCommand_h
#define cmLinkLibrariesCommand_h
#include "cmStandardIncludes.h"
2001-01-18 19:20:24 +03:00
#include "cmCommand.h"
2001-01-18 19:20:24 +03:00
/** \class cmLinkLibrariesCommand
2001-01-11 16:04:28 +03:00
* \brief Specify a list of libraries to link into executables.
*
2001-01-18 19:20:24 +03:00
* cmLinkLibrariesCommand is used to specify a list of libraries to link
2001-01-11 16:04:28 +03:00
* into executable(s) or shared objects. The names of the libraries
2001-01-18 19:20:24 +03:00
* should be those defined by the LIBRARY(library) command(s).
2001-01-11 16:04:28 +03:00
*/
2001-01-18 19:20:24 +03:00
class cmLinkLibrariesCommand : public cmCommand
{
public:
2001-01-11 16:04:28 +03:00
/**
2001-01-18 19:20:24 +03:00
* This is a virtual constructor for the command.
2001-01-11 16:04:28 +03:00
*/
2001-01-18 19:20:24 +03:00
virtual cmCommand* Clone()
{
2001-01-18 19:20:24 +03:00
return new cmLinkLibrariesCommand;
}
2001-01-11 16:04:28 +03:00
/**
2001-01-18 19:20:24 +03:00
* This is called when the command is first encountered in
2001-01-11 16:04:28 +03:00
* the CMakeLists.txt file.
*/
virtual bool Invoke(std::vector<std::string>& args);
2001-01-11 16:04:28 +03:00
/**
2001-01-18 19:20:24 +03:00
* This determines if the command gets propagated down
2001-01-11 16:04:28 +03:00
* to makefiles located in subdirectories.
*/
virtual bool IsInherited() {return true;}
2001-01-11 16:04:28 +03:00
/**
2001-01-18 19:20:24 +03:00
* The name of the command as specified in CMakeList.txt.
2001-01-11 16:04:28 +03:00
*/
virtual const char* GetName() { return "LINK_LIBRARIES";}
2001-01-11 16:04:28 +03:00
/**
* Succinct documentation.
*/
2001-01-12 22:35:15 +03:00
virtual const char* GetTerseDocumentation()
{
2001-01-11 16:04:28 +03:00
return
2001-01-12 22:35:15 +03:00
"Specify a list of libraries to be linked into\n"
"executables or shared objects.";
}
2001-01-11 16:04:28 +03:00
/**
* More documentation.
*/
2001-01-12 22:35:15 +03:00
virtual const char* GetFullDocumentation()
{
2001-01-11 16:04:28 +03:00
return
2001-01-12 21:07:20 +03:00
"LINK_LIBRARIES(library1 library2)\n"
"Specify a list of libraries to be linked into\n"
2001-01-18 19:20:24 +03:00
"executables or shared objects. This command is passed\n"
"down to all other commands. The library name should be\n"
"the same as the name used in the LIBRARY(library) command.";
}
cmTypeMacro(cmLinkLibrariesCommand, cmCommand);
};
#endif