Commit Graph

491 Commits

Author SHA1 Message Date
David Cole 9a4e7ea742 ENH: Add InstallNameFixupPath to support installing built frameworks on the Mac. Change Application to Applications in the BundleTest. Also correct small typo (tcl->Tcl) noted in bug 4572. 2007-08-24 13:30:41 -04:00
Brad King 9f2de08f90 ENH: Added cmTarget::GetLanguages method to centralize computation of the list of languages compiled in a target. 2007-08-02 13:38:39 -04:00
Brad King cac79e92b8 STYLE: Fixed line-too-long, fixed indentation, removed trailing whitespace, added function separator comment lines. 2007-07-02 13:32:41 -04:00
Brad King 35936433e1 ENH: Merging changes from branch CMake-SourceFile2-b between tags
CMake-SourceFile2-bp and CMake-SourceFile2-b-mp1 to trunk.  This
commit is surrounded by tags CMake-SourceFile2-b-mp1-pre and
CMake-SourceFile2-b-mp1-post on the trunk.

The changes re-implement cmSourceFile and the use of it to allow
instances to be created much earlier.  The use of cmSourceFileLocation
allows locating a source file referenced by a user to be much simpler
and more robust.  The two SetName methods are no longer needed so some
duplicate code has been removed.  The strange "SourceName" stuff is
gone.  Code that created cmSourceFile instances on the stack and then
sent them to cmMakefile::AddSource has been simplified and converted
to getting cmSourceFile instances from cmMakefile.  The CPluginAPI has
preserved the old API through a compatibility interface.

Source lists are gone.  Targets now get real instances of cmSourceFile
right away instead of storing a list of strings until the final pass.

TraceVSDependencies has been re-written to avoid the use of
SourceName.  It is now called TraceDependencies since it is not just
for VS.  It is now implemented with a helper object which makes the
code simpler.
2007-06-18 11:59:23 -04:00
Alexander Neundorf 9d4f3a0686 STYLE: remove duplicate non-const accessors GetLocalGenerator(int) and
GetLocaGenerators(cmLocalGenerators) from cmGlobalGenerator(). Now there is
one const accessor which is even faster since it returns a reference
(instead of copying a vector)
-more const to ensure that this the returned local generators don't actually
get modified
-removed duplicated code in GetCTestCommand() and GetCPackCommand()
-added some const accessors

Alex
2007-06-15 10:10:24 -04:00
Brad King 3f2dd9bc54 ENH: Made cmTarget::GetSourceFiles method return reference to const so addition of cmSourceFile pointers must be done with an access method in cmTarget. 2007-05-28 10:25:03 -04:00
Brad King d2f62e6ac3 ENH: Made cmTarget::GetSourceLists return a reference to const so that all additions of sources must go through access methods in cmTarget. 2007-05-28 09:59:08 -04:00
Brad King c288da754a BUG: Target names in the COMMAND part of a custom command should not create a file-level dependency that forces the command to rerun when the executable target rebuilds, but the target-level dependency should still be created. Target names in a DEPENDS should do both a target-level and file-level dependency. Updated the BuildDepends test to check that this works. 2007-05-23 13:27:00 -04:00
Alexander Neundorf 4878c00905 ENH: add the IMPORT keyword to ADD_EXECUTABLE(), which generates an
"imported" executable target. This can then be used e.g. with
ADD_CUSTOM_COMMAND() to generate stuff. It adds a second container for
"imported" targets, and FindTarget() now takes an additional argument bool
useImportedTargets to specify whether you also want to search in the
imported targets or only in the "normal" targets.

Alex
2007-05-22 10:24:59 -04:00
Alexander Neundorf e701ef77d8 STYLE: functions use upper case for the first letter
Alex
2007-05-09 09:35:59 -04:00
Alexander Neundorf 7f11536704 ENH: now target names can be used in add_custom_command() and
add_custom_target() as COMMAND, and cmake will recognize them and replace
them with the actual output path of these executables. Also the dependency
will be added automatically. Test included.
ENH: moved TraceVSDependencies() to the end of GlobalGenerator::Configure(),
so it is done now in one central place

Alex
2007-05-09 08:25:45 -04:00
Brad King af95f61d76 ENH: Created method cmTarget::GetExportMacro to centralize computation of the export symbol name. This removes duplicate code from all the generators. Also enabled the export definition for executable targets with the ENABLE_EXPORTS property set. 2007-03-27 23:13:25 -04:00
Brad King fc7c433463 ENH: Added support for import libraries created by executable and module targets. The module import libraries should never be used but some windows compilers always create them for .dll files since there is no distinction from shared libraries on that platform. The executable import libraries may be used to create modules that when loaded bind to symbols from the executables. This is an enhancement related to bug#4210 though not requested by it explicitly. 2007-03-19 10:00:36 -04:00
Ken Martin b99129d2d8 ENH: some code cleanup 2007-03-12 10:26:59 -04:00
Brad King 92ff60b6a6 ENH: Added target properties ARCHIVE_OUTPUT_DIRECTORY, LIBRARY_OUTPUT_DIRECTORY, and RUNTIME_OUTPUT_DIRECTORY. If set these override EXECUTABLE_OUTPUT_PATH and LIBRARY_OUTPUT_PATH for a specific target. They can be used to distribute target files in the build tree with the same granularity that the INSTALL command provides for the install tree. This addresses bug#2240 and bug#4210. 2007-03-09 15:14:27 -05:00
Brad King 528f60f4a6 ENH: Added implib option to cmTarget::GetDirectory to support a separate directory containing the import library. This is an incremental step for bug#4210. 2007-03-09 09:30:16 -05:00
Brad King 01dc699d82 ENH: Combined cmTarget::GetDirectory and cmTarget::GetOutputDir since they are nearly the same. This is another step for bug#2240. 2007-03-08 15:33:19 -05:00
Brad King 33ee83714d ENH: Replaced LibraryOutputPath and ExecutableOutputPath variables in Makefile and VS generators to instead ask each target for its output path. This significantly reduces total code size and centralizes previously duplicate code. It is also a step towards bug#2240. 2007-03-08 14:57:28 -05:00
Andy Cedilnik 8ad3430931 ENH: Make EXCLUDE_FROM_ALL a target and directory properties. Also, make IsInAll use EXCLUDE_FROM_ALL. Also, enable the test that tests this 2007-02-23 09:46:27 -05:00
Ken Martin 84315a7d57 BUG: fix accidental checkin 2007-02-19 14:32:36 -05:00
Ken Martin 09699018cc ENH: turn on spaces in path test 2007-02-19 13:20:27 -05:00
Bill Hoffman ca0230a33e ENH: check in initial conv library stuff 2007-02-16 16:12:17 -05:00
Brad King 4bc0fd0941 ENH: Added cmTarget::GetPDBName method to simplify computation of .pdb file name for a target. 2007-02-01 16:54:49 -05:00
Brad King 712345ffc4 BUG: The .pdb file generated for a library or executable should match the real file name used for the target. This addresses bug#3277. 2007-02-01 09:57:24 -05:00
Ken Martin 27379d7b08 ENH: make properties a bit more formal with documentation and chaining 2006-12-07 09:45:32 -05:00
Ken Martin daa6d2bc04 ENH: updated handling of debug and optimized target link libraries 2006-11-29 11:00:17 -05:00
Brad King b155f3aa1c ENH: Adding image version number (major.minor) property to windows binaries. Default is 0.0, but the VERSION target property may change the value. Windows now has first-class support for dll and exe versioning. This addresses bug#1219. 2006-10-16 18:17:14 -04:00
Bill Hoffman 0f2f074978 ENH: fix for vtk 4.4 and other projects that may try to link to a module 2006-05-19 13:02:12 -04:00
Ken Martin cac30b5ff8 STYLE: fix line length 2006-05-12 14:12:13 -04:00
Brad King 2301a025ea ENH: Added global TargetManifest computation between Configure and Generate steps. This allows generators to know what other targets will exist on disk when the build completes. 2006-04-04 11:48:19 -04:00
Andy Cedilnik ed5f95cf23 ENH: Add proper support for installing bundles 2006-03-28 13:16:15 -05:00
Ken Martin 3d96e52261 STYLE: some m_ to this-> cleanup 2006-03-15 11:02:08 -05:00
Bill Hoffman 6b47b28867 ENH: fix line length style stuff 2006-03-10 11:13:15 -05:00
Brad King 5792dc8da8 ENH: Replaced UpdateLocation method with call to GetLocation. Added comment about problems with the LOCATION attribute. 2006-03-03 18:06:44 -05:00
Andy Cedilnik bc4e5581ee ENH: Add support for exporting graphviz of the project dependencies 2006-03-03 14:24:31 -05:00
Andy Cedilnik c4156b4531 COMP: Even more global target fixes 2006-02-24 17:35:35 -05:00
Brad King 586a9427d3 ENH: Created target property INSTALL_NAME_DIR initalized by CMAKE_INSTALL_NAME_DIR specifying the directory portion of the OSX install_name field in shared libraries. This is the OSX equivalent of RPATH. 2006-02-24 13:13:14 -05:00
Andy Cedilnik ea5564624c ENH: Add a notion of a global target 2006-02-23 10:03:24 -05:00
Brad King 8dd00d5b1e BUG: Fixed relink with new install framework. 2006-02-19 17:27:47 -05:00
Brad King 81677b3130 ENH: Generate import libraries for DLLs on Cygwin and MinGW. 2006-02-18 15:37:23 -05:00
Brad King 537e2b4ed5 ENH: Implemented RPATH specification support. It is documented by the command SET_TARGET_PROPERTIES. 2006-02-16 15:19:00 -05:00
Brad King 22c62c9e65 BUG: Sweeping changes to cleanup computation of target names. This should
fix many bugs related to target names being computed inconsistently.

- Centralized computation of a target's file name to a method in
  cmTarget.  Now that global knowledge is always available the
  *_CMAKE_PATH cache variables are no longer needed.

- Centralized computation of link library command lines and link
  directory search order.

- Moved computation of link directories needed to link CMake targets
  to be after evaluation of linking dependencies.

This also removed alot of duplicate code in which each version had its
own bugs.

This commit is surrounded by the tags

  CMake-TargetNameCentralization1-pre

and

  CMake-TargetNameCentralization1-post

so make the large set of changes easy to identify.
2006-01-13 18:18:32 -05:00
Bill Hoffman 452925649a ENH: add better support for framework linking 2005-12-26 13:14:19 -05:00
Brad King 163e3ff56c ENH: Removed cmMakefile arguments from cmTarget methods because cmTarget has the ivar m_Makefile now. Re-implemented cmLocalUnixMakefileGenerator3::AppendAnyDepend to use the new global knowledge and avoid the need to look at the cache for information about other targets. This should fix problems with custom commands and executables with the OUTPUT_NAME set. Also the <target>_LIBRARY_TYPE cache variable is no longer needed at all and has been removed. 2005-12-14 10:47:33 -05:00
Ken Martin 345fb993aa ENH: some fixes for better backwards compatibility 2005-10-10 11:49:17 -04:00
Brad King d392acb4e6 ENH: Added versioned executable support. This partially addresses bug#2143. Also made OUTPUT_NAME work when installing executables. 2005-08-17 16:11:18 -04:00
Ken Martin 369308ca76 ENH: make LOCATION an computed property of the target and get rid of a bunch of const junk 2005-06-22 09:06:46 -04:00
Brad King b1c5289787 ENH: Created cmTarget::GetLibraryNames to replace cmLocalUnixMakefileGenerator2::GetLibraryNames. Added cmTarget::GetLibraryCleanNames to be used by cmLocalUnixMakefileGenerator2. Now when a library is linked both the shared and static versions are removed from the build tree. In this way we avoid having both kinds of libraries present when the user switches BUILD_SHARED_LIBS on/off. This prevents problems with turning off shared libraries and then expecting the linker to use the static libraries only to find it is using the out-of-date shared versions. 2005-04-22 16:11:00 -04:00
Brad King 1b71f4477b ENH: Added cmTarget::GetBaseName and cmTarget::GetFullName methods and removed cmLocalGenerator::GetFullTargetName and cmLocalUnixMakefileGenerator2::GetBaseTargetName. This functionality is more sensibly implemented in cmTarget. It is also needed for an upcoming feature in which both the shared and static versions of a library will be removed before one is linked. 2005-04-22 15:23:21 -04:00
Brad King 1088f39327 COMP: Added missing forward declaration of cmMakefile. This was only working because cmCustomCommand.h declared it. 2005-02-18 16:12:08 -05:00
Bill Hoffman 7cef36c628 ENH: add the ability to generate custom commands for a language that is not supported by an IDE 2004-10-21 14:34:02 -04:00
Bill Hoffman 692ba48c4e ENH: major changes to support addition of languages from cmake modules directory. 2004-09-22 14:42:05 -04:00
Bill Hoffman 9655299f08 ENH: initial fortran support 2004-08-06 14:51:41 -04:00
Andy Cedilnik b1a7421840 ENH: Styart working on bundles support and abstract WIN32_EXECUTABLE 2004-02-28 18:59:19 -05:00
Andy Cedilnik d13e30f3ae ENH: Make install on windows seems to work now 2004-01-27 12:37:30 -05:00
Ken Martin 072db6ad70 removed redundent includes 2003-08-10 18:30:54 -04:00
Ken Martin 117f961a5a moved function into cmTarget 2003-06-24 15:10:47 -04:00
Ken Martin ba68f771b3 yikes added new custom command support 2003-06-03 10:30:23 -04:00
Bill Hoffman 3859417d1a ENH: add target properties 2002-12-20 17:15:45 -05:00
Amitha Perera 939035ad91 BUG: the dependency analysis would incorrectly alphabetically re-order the
link lines, which affects external libraries pulled up from deep within
the dependency tree. Fixed by preserving order everywhere.
2002-11-19 18:01:05 -05:00
Brad King 1f6a3c67b1 ENH: Added reference to Copyright.txt. Removed old reference to ITK copyright. Changed program name to CMake instead of Insight in source file header. Also removed tabs. 2002-10-23 18:03:27 -04:00
Ken Martin 7ddb408621 removed some includes 2002-09-27 16:24:10 -04:00
Amitha Perera 0e6b39e52f BUG: Correct some of the dependency analysis code.
- Make sure the original link line is untouched
- Avoid duplicating the link line when supporting version < 1.4
- Make sure the cyclic dependencies and such are output correctly in
  complicated cases.
- Avoid outputing dependencies that are already satisfied on the original
  link line when possible.
2002-05-10 13:35:42 -04:00
Bill Hoffman 6734d3bb88 ENH: change set<string> to set<cmStdString> to avoid long symbols that crash ar on solaris 2002-05-09 09:33:52 -04:00
Bill Hoffman cdf550de13 ENH: rework library depend stuff 2002-05-03 16:34:05 -04:00
Amitha Perera 4bff970413 - bug fix where paths weren't being output when LIB_OUT_PATH *isn't* used
- test case for above mentioned bug
- more comments. Comments are good.
2002-05-03 00:27:34 -04:00
Bill Hoffman 46e9d970e9 remove canonical conversion for lib names 2002-05-02 16:13:18 -04:00
Amitha Perera 4fe8947bcc BUG: The library paths should stay with the libraries during dependency analysis. 2002-05-02 13:41:40 -04:00
Bill Hoffman 27fe57b716 ENH: change LINK_LIBRARY to add to targets 2002-05-02 13:17:10 -04:00
Amitha Perera 1f8df8585e ENH: Add library dependency analysis. 2002-05-01 14:00:21 -04:00
Bill Hoffman 4ea0f6b949 ENH: add enable language support for PROJECT command, this means that a C only project can be built with cmake, even without a cxx compiler 2002-04-02 15:43:23 -05:00
Bill Hoffman 8b3b49a010 ENH: major change, the cmMakefile now contains a master list of cmSourceFile objects, the source lists reference the list via pointers, also you can now set properties on a file, like compile flags, abstract, etc. 2002-03-29 10:06:30 -05:00
Will Schroeder a6a43d5320 ENH:Updated copyright 2002-01-21 15:30:43 -05:00
Luis Ibanez bf7470be7c FIX: GENERATED_CODE type is no longer needed: generated code is not a Target. 2001-12-11 02:17:53 -05:00
Luis Ibanez f86418e99f ENH: A type of target was added for representing GENERATED_CODE 2001-11-29 01:48:23 -05:00
Yves Starreveld 247c1640da Changes to allow MODULE type target for a shared library 2001-08-28 18:02:59 -04:00
Bill Hoffman ddd5a7d729 ENH: change all maps of string to be maps of cmStdString, to reduce symbol length in object files. 2001-08-22 11:58:17 -04:00
Brad King cfa25e9e1a ENH: Added INSTALL_PROGRAMS command and corresponding support. This involved splitting cmTarget::INSTALL into INSTALL_FILES and INSTALL_PROGRAMS enum values. INSTALL_FILES no longer adds execute permission. The INSTALL_PROGRAMS commnad takes either a list of explicit names, or a regex. It will not expand source lists like the INSTALL_FILES command will. 2001-07-31 11:29:21 -04:00
Brad King e693d47253 ENH: Added support for selection of static/shared build on a per-library basis. 2001-07-02 15:38:02 -04:00
Ken Martin 012603c746 duh 2001-06-13 13:53:11 -04:00
Ken Martin 521e301116 minor cvs web changeCMakeLists.txt 2001-06-13 13:49:24 -04:00
Bill Hoffman 4f77d737c9 ENH: move utilities to targets from makefile, and add versioning to cache 2001-06-07 14:52:29 -04:00
Ken Martin dbebd0a276 added install rules 2001-05-23 11:31:43 -04:00
Ken Martin 32f7cef6f3 added win32 executable option 2001-05-10 13:52:23 -04:00
Ken Martin 089aa3e106 option to make utilities in the all target 2001-05-04 15:50:26 -04:00
Bill Hoffman 96ec40943c ENH: implement ADD_TARGET command, and add an ALL_BUILD target 2001-05-01 16:55:32 -04:00
Ken Martin 2da0c57d46 added TARGET_LINK_LIBRARY command and support for debug and release libraries to link against 2001-04-30 10:44:00 -04:00
Will Schroeder 54cfe84f3f ENH:New copyright 2001-04-27 08:01:17 -04:00
Ken Martin 73f04d1409 many fixes and cleanup and features 2001-04-24 16:49:12 -04:00
Ken Martin 24bce99cbf cleaned up the coding style made ivars private etc 2001-04-19 13:28:46 -04:00
Ken Martin 865ec96644 major changes to support multiple libraries and source lists 2001-04-11 14:59:02 -04:00