Brad King
96fd5909d9
ENH: Implement linking with paths to library files instead of -L and -l separation. See bug #3832
...
- This is purely an implementation improvement. No interface has changed.
- Create cmComputeLinkInformation class
- Move and re-implement logic from:
cmLocalGenerator::ComputeLinkInformation
cmOrderLinkDirectories
- Link libraries to targets with their full path (if it is known)
- Dirs specified with link_directories command still added with -L
- Make link type specific to library names without paths
(name libfoo.a without path becomes -Wl,-Bstatic -lfoo)
- Make directory ordering specific to a runtime path computation feature
(look for conflicting SONAMEs instead of library names)
- Implement proper rpath support on HP-UX and AIX.
2008-01-22 09:13:04 -05:00
Brad King
8d1d5500c8
ENH: Enable use of COMPILE_DEFINITIONS property for Fortran sources.
2008-01-17 19:58:01 -05:00
Brad King
433099ecdd
ENH: Converted cmMakefile DefineFlags added by ADD_DEFINITIONS command into a COMPILE_DEFINITIONS directory property.
2008-01-17 19:29:43 -05:00
Brad King
18b9e7db6c
ENH: Enable CMAKE_<lang>_DEFINE_FLAG for COMPILE_DEFINITIONS property implementation.
2008-01-17 10:00:19 -05:00
Brad King
8262ccfd4e
ENH: Create COMPILE_DEFINITIONS property for targets and source files. Create <config>_COMPILE_DEFINITIONS property as per-configuration version. Add Preprocess test to test the feature. Document limitations on Xcode and VS6 generators.
2008-01-14 09:20:58 -05:00
Brad King
857e2e15dd
ENH: Improved escaping in kwsys/System. Added escape of % for NMake. Added escape of ; for the VS IDE.
2008-01-13 16:36:20 -05:00
Bill Hoffman
ee886fbbdb
ENH: add CMAKE_DEFINE_FLAG_(LANG) that can replace -D flags with what the compiler actually uses
2008-01-11 13:00:29 -05:00
Brad King
52eb0ccac7
BUG: Restore old interface of "make foo.o" and "make foo.i" even though object file names now include source extensions. For Java we also need to always remove the source extension (.java -> .class). This fixes the re-opening of bug #6169 .
2008-01-07 16:12:37 -05:00
Brad King
f872c10b7e
ENH: Added method cmLocalGenerator::GetBackwardsCompatibility to reduce parsing of CMAKE_BACKWARDS_COMPATIBILITY variable. Add cmLocalGenerator::NeedBackwardsCompatibility to simplify checks for compatibility requirements.
2007-12-28 23:07:14 -05:00
Brad King
73704ede42
ENH: Enabled color printing of "Scanning dependencies of target ..." message.
2007-12-19 17:15:41 -05:00
Brad King
de96fd1df9
ENH: Moved dependency integrity check from CheckBuildSystem over to a per-target UpdateDependencies step. This greatly reduces the startup time for make processes and allows individual targets to be built without a global dependency check.
2007-12-19 16:36:30 -05:00
Alexander Neundorf
ac017f7aba
STYLE: fix warnings: comparison signed/unsigned, unused variable
...
Alex
2007-12-19 03:56:13 -05:00
Alexander Neundorf
3ae731fab7
ENH: add support for chrpath, so the RPATH in ELF files can be changed when
...
installing without having to link the target again -> can save a lot of time
chrpath is handled very similar to install_name_tool on the mac. If the
RPATH in the build tree file is to short, it is padded using the separator
character.
This is currently disabled by default, it can be enabled using the option
CMAKE_USE_CHRPATH. There are additional checks whether it is safe to enable
it. I will rework them and use FILE(READ) instead to detect whether the
binaries are actually ELF files.
chrpath is available here
http://www.tux.org/pub/X-Windows/ftp.hungry.com/chrpath/
or kde svn (since a few days): http://websvn.kde.org/trunk/kdesupport/chrpath/
Alex
2007-12-18 17:50:27 -05:00
Alexander Neundorf
f2bb0af819
STYLE: restructure OutputLinkLibraries() a bit, so that new there is a
...
function which returns the RPATH, so e.g. the install rpath can be queried
when the command for the build rpath is created. This is a first step for
supporting chrpath.
Alex
2007-11-26 17:57:39 -05:00
Brad King
ea874415d9
ENH: Moved GetTargetDirectory method up to cmLocalGenerator. This provides a common interface to something that was implemented in most local generators anyway.
2007-08-01 15:25:40 -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
c25d2bfdd2
ENH: Added testing for custom command line arguments containing all special characters on the US keyboard. Fixed curly brace arguments on borland and % arguments in mingw32-make.
2007-05-17 10:53:18 -04:00
Bill Hoffman
76dd86b410
BUG: fix -D escaped quotes for watcom
2007-05-10 14:43:55 -04:00
Alexander Neundorf
8245f437b6
BUG: fix problem for non-C/CXX languages with Visual Studio, the
...
dependencies for the custom commands added for java were not handled
correctly. Needs more work.
Alex
2007-05-09 14:41:38 -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
1f639ee76c
ENH: Added computation of object file names that are almost always short enough to not exceed the filesystem path length limitation. This is useful when a source file from outside the tree is referenced with a long full path. The object file name previously would contain the entire path which when combined with the build output directory could exceed the filesystem limit. Now CMake recognizes this case and replaces enough of the beginning of the full path to the source file with an md5sum of the replaced portion to make the name fit on disk. This addresses bug#4520.
2007-03-16 10:34:25 -04:00
Ken Martin
b99129d2d8
ENH: some code cleanup
2007-03-12 10:26:59 -04:00
Brad King
2f2b5b2503
ENH: SetupPathConversions is now called automatically on demand.
2007-03-08 08:38:40 -05:00
Brad King
4036627487
ENH: Improved computation of RelativePathTopSource and RelativePathTopBinary to use higher relative path tops when the source directories jump around in a tree below the original source top.
2007-03-07 17:32:35 -05:00
Brad King
073076e0f7
COMP: Fix ConvertToRelativePath change for Xcode generator.
2007-03-07 16:32:29 -05:00
Brad King
fc19882e8f
ENH: Moved ConvertToRelativePath from cmGlobalGenerator to cmLocalGenerator. This is in preparation for setting up each local generator to have its own RelativePathTopSource and RelativePathTopBinary based on its ancestor directories.
2007-03-07 15:15:46 -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
Bill Hoffman
ca0230a33e
ENH: check in initial conv library stuff
2007-02-16 16:12:17 -05:00
Brad King
54731fa2c8
ENH: Adding support for # escape in Watcom WMake.
2006-10-25 11:23:04 -04: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
Brad King
406f3554c7
BUG: Fixed display of custom command comments with quotes, dollars, and other special characters in them.
2006-10-04 18:52:29 -04:00
Brad King
019dabc97f
BUG: MSYS makefile shell needs posix paths to executables in some cases and it does not hurt to do it always.
2006-09-28 10:37:19 -04:00
Brad King
0b135767d6
BUG: Do not filter system directories for include file dependencies.
2006-09-28 09:49:40 -04:00
Brad King
dd332a00cc
ENH: Re-implemented command line argument shell quoting to support several platforms with one code base.
2006-09-27 13:43:46 -04:00
Brad King
b9fc06735d
BUG: Enabled use of EscapeForShell to properly escape custom command lines. This addresses bug#3786 for Xcode.
2006-09-21 16:10:47 -04:00
Brad King
2459ceb076
BUG: Centralized generation of command line arguments in escaped form. This addresses bug#3786 for several platforms.
2006-09-21 15:14:06 -04:00
Bill Hoffman
8f1aaf28c1
ENH: make sure RuleVariable struct is initialized correctly, also make sure custom command targets do not crash cmake
2006-08-08 13:44:25 -04:00
Brad King
5cfa1b02ab
ENH: Added generation of rules to manually request preprocessed or generated assembly sources.
2006-08-07 23:25:21 -04:00
Brad King
88702ff442
ENH: Moved GetSourceFileLanguage up to cmLocalGenerator.
2006-08-03 09:26:07 -04:00
Brad King
9bf5af6e32
ENH: Moved unique object file name computation from cmLocalUnixMakefileGenerator3 up to cmLocalGenerator for use by all generators. Created cmLocalVisualStudioGenerator as superclass for all VS generators. Implemented on-demand unique object file name computation for VS 7 generator to avoid slow compiles when all sources are in subdirectories.
2006-07-11 11:41:38 -04:00
Brad King
ec2104cd31
BUG: Updated Makefile dependency scanning to provide a full local generator to the dependency scanner to do proper path conversions. This allows the rules written into the depend.make files to use the same relative path conversion as those written into the build.make files. Several previous changes added more and more information for use by the dependency scanner and it was converging to having the full local generator anyway.
2006-05-25 09:47:30 -04:00
Bill Hoffman
e6ef33f598
ENH: name pdb files for visual studio make based builds
2006-04-19 16:36:14 -04:00
Bill Hoffman
5ecfd3d4d3
ENH: fix java and add OBJECT_DIR support
2006-04-17 14:01:22 -04:00
Brad King
d5719f22c1
ENH: Added support for multiple outputs generated by a single custom command. For Visual Studio generators the native tool provides support. For Xcode and Makefile generators a simple trick is used. The first output is considered primary and has the build rule attached. Other outputs simply depend on the first output with no build rule. During cmake_check_build_system CMake detects when a secondary output is missing and removes the primary output to make sure all outputs are regenerated. This approach always builds the custom command at the right time and only once even during parallel builds.
2006-04-11 11:06:19 -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
Bill Hoffman
f7c1723135
ENH: add support for universal binaries
2006-03-24 09:15:05 -05:00
Ken Martin
3d96e52261
STYLE: some m_ to this-> cleanup
2006-03-15 11:02:08 -05:00
Bill Hoffman
89e5fc63fe
STYLE: fix line lengths
2006-03-10 13:54:57 -05:00
Bill Hoffman
3f532f5489
ENH: add support for language flags at rule expansion time
2006-03-06 15:14:23 -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
Brad King
576f0b65c7
BUG: Fix generation of Xcode 2.0 and earlier projects to use CMAKE_BUILD_TYPE.
2006-02-24 11:13:31 -05:00
Bill Hoffman
398827ebc1
ENH: make it compile on vs6
2006-02-20 14:37:24 -05:00
Bill Hoffman
39e636a4a4
ENH: change expand stuff to pass a struct for all the args
2006-02-20 13:42:18 -05:00
Brad King
3fa4a95f56
BUG: Xcode generator should use local generator computation of include directories.
2006-02-20 09:54:25 -05:00
Brad King
96f0266228
ENH: Created new install script generation framework. The INSTALL command creates the generators which are later used by cmLocalGenerator to create the cmake_install.cmake files. A new target installation interface is provided by the INSTALL command which fixes several problems with the INSTALL_TARGETS command. See bug#2691. Bugs 1481 and 1695 are addressed by these changes.
2006-02-19 15:25:27 -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
Bill Hoffman
347c5f4b46
ENH: add working directory support
2006-02-08 10:58:36 -05:00
Brad King
8340c0d186
ENH: Further centralized custom command dependency computation. Custom command dependencies in the source tree may now also be specified relative to the source directory.
2006-01-13 20:51:45 -05:00
Brad King
327489ae59
COMP: Removed unused paramter from cmLocalGenerator::OutputLinkLibraries.
2006-01-13 18:33:51 -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
f6588b7919
ENH: fix borland make clean targets before build, add new generators for msys and mingw
2005-12-22 16:42:36 -05:00
Ken Martin
f85f919dbc
ENH: reduce the number of files produced still needs a bit more cleanup
2005-07-27 09:49:37 -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
Ken Martin
e559aa11ac
ENH: added support for forcing recomputation of depends
2005-06-10 10:45:08 -04:00
Ken Martin
708828dc37
ENH: removed old convert calls
2005-06-10 08:41:47 -04:00
Ken Martin
8c65179339
ENH: warning fixes and some first steps in cleaning up the convert code
2005-05-13 09:54:30 -04:00
Ken Martin
caf17c123b
ENH: added new generator
2005-05-12 10:49:56 -04:00
Andy Cedilnik
d395b563ed
ENH: Improve internal test handling by creating a test class. Command cmEnableTesting now only sets CMAKE_TESTING_ENABLED and cmAddTest only adds a test to the list. The actual test files are written by local generator. This way we can at some point in the future replace DartTestfile with some XML file
2005-04-24 15:59:51 -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
Bill Hoffman
1004073942
ENH: performance improvements
2005-04-12 13:27:07 -04:00
Ken Martin
345cf04012
ENH: big change that includes immediate subdir support, removing the notion of inherited commands, makefiles no longer read in the parent makefiles but instead inherit thier parent makefiles current settings
2005-03-18 10:41:41 -05:00
Ken Martin
791aa6052b
ENH: add support for out of source source
2005-03-14 11:29:15 -05:00
Brad King
cb48e0c161
ENH: Merged implementations of ConvertToRelative*Path methods. The main ConvertToRelativePath method is now in cmGlobalGenerator. It converts paths only if they are at least inside the deepest common directory between the top-level source and build trees. Each cmLocalGenerator instance calls this global method with its own output directory as the "local" argument from which paths are relative. Added separate ConvertToOptionallyRelative path that pays attention to the CMAKE_USE_RELATIVE_PATHS option.
2005-02-24 16:04:54 -05:00
Bill Hoffman
2ebbf64508
ENH: remove unused code
2005-02-24 14:27:16 -05:00
Bill Hoffman
ff812580eb
ENH: add a new library path ordering algorithm to make sure -L paths will pick the correct libraries if possible
2005-02-24 13:16:41 -05:00
Brad King
39af9ee1e4
ENH: Updated implementation of custom commands. Multiple command lines are now supported effectively allowing entire scripts to be written. Also removed extra variable expansions and cleaned up passing of commands through to the generators. The command and individual arguments are now kept separate all the way until the generator writes them out. This cleans up alot of escaping issues.
2005-02-22 10:32:44 -05:00
Bill Hoffman
34e7e36cae
ENH: getting closer
2005-02-14 16:46:32 -05:00
Bill Hoffman
fd0f29e6f4
ENH: depends work between targets
2005-02-03 17:42:55 -05:00
Bill Hoffman
68c419c780
ENH: getting closer
2005-02-02 17:16:07 -05:00
Bill Hoffman
35ec09480a
ENH: move AddFlags stuff up to LocalGenerator from LocalUnix generator
2005-02-02 13:19:57 -05:00
Brad King
16e86a3ea9
ENH: Split part of GetIncludeFlags method into separate GetIncludeDirectories method.
2004-10-26 10:15:49 -04: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
46a493ae74
ENH: remove warnings
2004-09-03 13:24:10 -04:00
Bill Hoffman
c2ef51e181
ENH: define language extensions in cmake files and not hard coded, also fix trycompile problem
2004-09-03 12:03:41 -04:00
Andy Cedilnik
f9b43b9212
BUG: Implement installing of shared library versioning and add test for the whole thing
2004-06-28 14:40:17 -04:00
Andy Cedilnik
5a5cd54730
ENH: GetSafeDefinition is now in cmMakefile
2004-04-27 12:02:32 -04:00
Bill Hoffman
ddb815c125
ENH: add new subdirectory exclude from top option
2004-03-09 16:28:44 -05:00
Andy Cedilnik
d13e30f3ae
ENH: Make install on windows seems to work now
2004-01-27 12:37:30 -05:00
Andy Cedilnik
7608d3f586
ERR: Fix std:: namespace
2004-01-25 19:30:24 -05:00
Andy Cedilnik
797db2bd82
ENH: Start adding new installation framework
2004-01-25 19:25:26 -05:00
Bill Hoffman
d79e3ae698
ENH: move relative path to parent generator class
2003-12-22 15:16:46 -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
d2c4432bbe
changed handling of FinalPass
2002-09-15 08:54:16 -04:00
Ken Martin
b7455e404f
compiler warning
2002-09-07 21:22:03 -04:00
Ken Martin
12054916d4
made destructor virtual
2002-09-05 09:04:55 -04:00
Ken Martin
5b0611d709
updates
2002-09-04 15:24:49 -04:00
Ken Martin
3ffc4b2ee1
in progress checkin
2002-08-30 16:00:35 -04:00