summaryrefslogtreecommitdiffstats
path: root/Source/cmTarget.cxx
Commit message (Collapse)AuthorAgeFilesLines
* automoc: default to strict mode, use CMAKE_AUTOMOC_RELAXED_MODEAlex Neundorf2011-12-131-1/+1
| | | | | | | | | automoc now defaults to strict mode, also with Qt4, i.e. it behaves as the documentation says by default. I also inverted the switch CMAKE_AUTOMOC_STRICT_MODE to CMAKE_AUTOMOC_RELAXED_MODE. Docs and test adapted accordingly. Alex
* Merge topic 'AutomocIncludedDotMocFileHandling'David Cole2011-12-071-2/+4
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2d11951 Merge branch 'master' into AutomocIncludedDotMocFileHandling 1eca18f automoc: add documentation for CMAKE_AUTOMOC_STRICT_MODE bc278ce automoc: fix line length 62e223e automoc: add variable CMAKE_AUTOMOC_STRICT_MODE, to enable strict parsing 40c5167 automoc: accept even more .moc files in non-strict mode c207f5d automoc: also accept other files when .moc is included in non-strict mode 9c0df72 automoc: add a StrictParseCppFile(), which is only qmake-compatible 174bf35 automoc: move the code for finding headers into separate function 8507eae automoc: fix handling of included _p.moc files 7ada172 automoc: some more linebreaks for the warnings for better readability 3b93e26 automoc: add extra check whether the header contains Q_PRIVATE_SLOT 4745715 Add a test case for the use of Q_PRIVATE_SLOT. bde4edb automoc: add special handling for including basename_p.moc, with test 74ab0f6 automoc: move some code from the big parsing loop into separate functions bc7560e automoc: add test for including a moc_abc_p.cpp file 30fd8e6 automoc: add test for including the moc file from another header ...
| * Merge branch 'master' into AutomocIncludedDotMocFileHandlingDavid Cole2011-12-071-12/+83
| |\ | | | | | | | | | | | | Conflicts: Source/cmTarget.cxx
| * | automoc: add documentation for CMAKE_AUTOMOC_STRICT_MODEAlex Neundorf2011-12-061-1/+4
| | | | | | | | | | | | Alex
* | | Merge topic 'refactor-versioned-lib-names'David Cole2011-12-071-40/+30
|\ \ \ | |_|/ |/| | | | | | | | 96f65ba cmTarget: Create helper method for versioned library names
| * | cmTarget: Create helper method for versioned library namesBrad King2011-12-061-40/+30
| | | | | | | | | | | | | | | Replace the duplicate logic for the realName and soName of versioned shared libraries with calls to a new ComputeVersionedName method.
* | | Merge topic 'GNU-to-MS'David Cole2011-12-061-0/+38
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ae62a1c Test CMAKE_GNUtoMS option in ExportImport on MinGW and MSys afb00fe Add CMAKE_GNUtoMS option to convert GNU .dll.a to MS .lib 61e8629 Factor makefile generator link rule lookup into helper function a603250 Load platform files that need to know the ABI when possible ecd8414 Fortran: Detect pointer size in gfortran on MinGW
| * | | Add CMAKE_GNUtoMS option to convert GNU .dll.a to MS .libBrad King2011-12-051-0/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Teach the Windows-GNU.cmake platform file to look for Visual Studio tools matching the target ABI. Add an extra step to the link command for shared libraries and executables that export symbols and on which a new GNUtoMS property is set (initialized by the CMAKE_GNUtoMS option). Tell the GNU linker to output a module definition (.def) file listing exported symbols in addition to the GNU-format import library (.dll.a). Pass the .def file to the MS "lib" tool to construct a MS-format DLL import library (.lib). Teach the install(TARGETS) command to install the MS import library next to the GNU one. Teach the install(EXPORT) and export() command to set the IMPORTED_IMPLIB property pointing at the import library to use the import library matching the tools in the importing project.
* | | | Factor out target location undefined behavior helper macroBrad King2011-12-011-11/+3
| |/ / |/| | | | | | | | | | | | | | Move CM_LOCATION_UNDEFINED_BEHAVIOR into a dedicated header. Add a parameter to describe the action that leads to the undefined target location.
* | | VS: Add support for three new project properties (#12586)Aaron Ten Clay2011-11-281-0/+23
|/ / | | | | | | | | | | | | | | | | | | | | VS_GLOBAL_PROJECT_TYPES: A string containing UUIDs to embed in the Visual Studio project file under <ProjectTypes>. VS_GLOBAL_KEYWORD: Allows specification of a keyword like "ManagedCProj" instead of the default "Win32Proj", under <Keyword> VS_DOTNET_REFERENCES: Semicolon-delimited list of .NET references to add to the project, which creates a new <ItemGroup>.
* | Merge topic 'AddMocOptionsToAutomoc'David Cole2011-11-081-1/+15
|\ \ | | | | | | | | | | | | | | | 2c648ab add documentation for the AUTOMOC_MOC_OPTIONS property 52719a1 automoc: fix #12541, support moc options
| * | add documentation for the AUTOMOC_MOC_OPTIONS propertyAlex Neundorf2011-11-011-1/+14
| | | | | | | | | | | | Alex
| * | automoc: fix #12541, support moc optionsAlex Neundorf2011-11-011-0/+1
| |/ | | | | | | | | | | | | | | This commit adds a new target property AUTOMOC_MOC_OPTIONS, which can be set to add extra options for the moc invocations done via automoc. This is equivalent to the OPTIONS parameter in the qt4_wrap_cpp() macro. Alex
* | VS: Add VS_SCC_AUXPATH target property (#12549)Robert Dailey2011-11-011-1/+6
|/ | | | Maps to SccAuxPath tag in VCPROJ files.
* Merge topic 'cmake-link-interface-libraries'David Cole2011-10-251-0/+4
|\ | | | | | | | | d9cbba7 Initialize LINK_INTERFACE_LIBRARIES target property with a variable
| * Initialize LINK_INTERFACE_LIBRARIES target property with a variableStephen Kelly2011-10-241-0/+4
| | | | | | | | | | | | | | | | | | | | | | Define variable CMAKE_LINK_INTERFACE_LIBRARIES to initialize the value of this property when a target is created. This allows authors to write set(CMAKE_LINK_INTERFACE_LIBRARIES "") to disable transitive linking to implementation dependencies of shared libraries on platforms where it is possible.
* | Refactor TargetTypeNames.Nicolas Despres2011-10-021-41/+31
|/ | | | | | Make it a static method instead of an array. It is safer for the type checking and if we add a new target type we will be warned to add a case to the switch.
* Merge topic 'effective-platform-name'David Cole2011-09-131-1/+5
|\ | | | | | | | | | | 64c9b31 Xcode: Add test to demonstrate iOS project in Xcode 59a2265 Xcode: Use EFFECTIVE_PLATFORM_NAME reference in ComputeOutputDir
| * Xcode: Use EFFECTIVE_PLATFORM_NAME reference in ComputeOutputDirDavid Cole2011-09-121-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Caveats apply: only valid when not overriding default value for output dir *and* there is a CMAKE_XCODE_EFFECTIVE_PLATFORMS value. For now, CMAKE_XCODE_EFFECTIVE_PLATFORMS must be defined in each project, or in the cache for a build. Code relying on value of LOCATION and similar properties may not work if it depends on file existence on disk since CMake will not evaluate $(EFFECTIVE_PLATFORM_NAME). This feature is only enabled for making it easier to build Xcode iOS projects where the developer wants to be able to switch easily between simulator and device builds.
* | Fortran: Add support for free- and fixed-form flagsBrad King2011-08-311-0/+12
| | | | | | | | | | | | | | Define a "Fortran_FORMAT" target and source file property. Initialize the target property from a "CMAKE_Fortran_FORMAT" variable. Interpret values "FIXED" and "FREE" to indicate the source file format. Append corresponding flags to the compiler command line.
* | Add documentation for AUTOMOC, add initialization via CMAKE_AUTOMOCAlex Neundorf2011-08-161-1/+24
| | | | | | | | Alex
* | Add support for Visual Studio project-specific globals (#8707)David Cole2011-07-291-0/+8
| | | | | | | | | | | | | | | | | | | | | | Thanks to Pau Garcia i Quiles for the inspiration for the patch. I've tweaked it a bit compared to what's in the bug tracker: this commit does not allow empty global variable names. I also added usage of the new feature to an existing test. Although it has no effect on the resulting Visual Studio projects, you can verify that the VSResource test produces a non-empty globals section in the generated .vcproj(x) files.
* | Merge topic 'effective-platform-name'Brad King2011-07-261-1/+13
|\ \ | |/ | | | | | | | | 74c73d5 Correct KWStyle line too long error 0c030ef Add use of EFFECTIVE_PLATFORM_NAME to generated Xcode projects.
| * Add use of EFFECTIVE_PLATFORM_NAME to generated Xcode projects.David Cole2011-07-181-1/+13
| | | | | | | | | | Facilitates building iOS projects, enabling switching back and forth between simulator and device builds at development time.
* | Fix #12342: Add APPEND_STRING option to set_property()Alex Neundorf2011-07-151-2/+3
|/ | | | | | | | | set_property() has APPEND, which creates a list. E.g. when appending to COMPILE_FLAGS a string is needed, not a list. With the APPEND_STRING option the value is append as string, not as list. Alex
* Documentation: Fix spelling / formatting errors (#12287)Modestas Vainius2011-06-191-1/+1
| | | | | | | | | | | | | | The patch fixes the following problems spotted by lintian: W: cmake-data: manpage-has-errors-from-man usr/share/man/man1/cmakemodules.1.gz 2641: warning [p 39, 1.5i]: can't break line I: cmake-data: spelling-error-in-manpage usr/share/man/man1/cmakeprops.1.gz explict explicit I: cmake: spelling-error-in-binary usr/bin/cmake explict explicit I: cmake: spelling-error-in-binary usr/bin/cpack explict explicit I: cmake: spelling-error-in-binary usr/bin/ctest explict explicit W: cmake: manpage-has-errors-from-man usr/share/man/man1/cmake.1.gz 7300: warning [p 120, 3.3i]: can't break line I: cmake: spelling-error-in-manpage usr/share/man/man1/cmake.1.gz explict explicit I: cmake-curses-gui: spelling-error-in-binary usr/bin/ccmake explict explicit I: cmake-qt-gui: spelling-error-in-binary usr/bin/cmake-gui explict explicit
* Merge topic 'module-link-interface-issue-11945'Brad King2011-03-151-3/+7
|\ | | | | | | | | | | c9d55ae Add parens in cmTarget::ComputeLinkInterface logic c6a8e4c The link interface of MODULE libraries is empty (#11945)
| * Add parens in cmTarget::ComputeLinkInterface logicBrad King2011-03-141-1/+1
| | | | | | | | | | | | | | | | | | Avoid GCC warning warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] added by commit c6a8e4c7 (The link interface of MODULE libraries is empty, 2011-03-09).
| * The link interface of MODULE libraries is empty (#11945)Brad King2011-03-091-3/+7
| | | | | | | | | | | | | | | | MODULE libraries cannot be linked into other libraries and executables (just like executables without ENABLE_EXPORTS). Set the MODULE target link interface to be empty. This allows such targets to be installed in an EXPORT set without including all their private implementation dependencies.
* | Add target property LINK_SEARCH_START_STATIC to aid static linkingBrad King2011-03-031-8/+23
| | | | | | | | | | | | | | | | | | Commit afd7d4ca (Add target property LINK_SEARCH_END_STATIC, 2008-01-31) defined a property to ensure that static runtime libraries get selected. Add a property to specify that all libraries whose type is unknown, such as "-lm", should be assumed static. Furthermore it assumes that an option such as "-static" is also used so that no initial -Bstatic is needed.
* | Merge topic 'fix-11295-support-plugin-bundles-on-mac'Brad King2011-02-221-0/+24
|\ \ | |/ |/| | | | | | | cabc407 CFBundle Test: Add PATHS for finding Rez (#11295) 5457b82 Add support for CFBundle targets on the Mac (#11295)
| * Add support for CFBundle targets on the Mac (#11295)Richard Bateman2011-01-111-0/+24
| | | | | | | | | | This commit enables building, for example, plugin bundles to be loaded by web browsers.
* | Combine duplicate COMPILE_DEFINITIONS disclaimerBrad King2011-01-171-8/+2
| |
* | Document reading LOCATION_<CONFIG> early as undefined (#11671)Brad King2011-01-101-9/+12
| | | | | | | | | | | | | | Although the LOCATION property is for compatibility with CMake 2.4, the LOCATION_<CONFIG> property is modern. However, if a project reads it and sets location-altering properties later the behavior is undefined. See parent commit for details.
* | Document reading LOCATION early as undefined (#11671)Brad King2011-01-101-1/+11
|/ | | | | | | | | | | Reading the LOCATION target property currently locks down the result and ignores any later changes to properties that affect it. This may or may not be expected and may or may not be the behavior in earlier versions of CMake. The property is documented as provided only for compatibility with CMake 2.4 and alternative interfaces are now available for all originally envisioned use cases. We want to discourage its use without outright deprecating it. Add documentation to explicitly state that reading the property before other properties are set is undefined.
* Merge topic 'custom-command-generator-expressions'Brad King2010-12-211-0/+17
|\ | | | | | | | | | | | | | | | | | | | | 4499d50 Mark CustomCommand test perconfig.out as SYMBOLIC f0cdb60 Introduce "generator expression" syntax to custom commands (#11209) 4749e4c Record set of targets used in cmGeneratorExpression ef9e9de Optionally suppress errors in cmGeneratorExpression 45e1953 Factor per-config sample targets out of 'Testing' test 4091bca Factor generator expression docs out of add_test bfb7288 Record backtrace in cmCustomCommand
| * Introduce "generator expression" syntax to custom commands (#11209)Brad King2010-12-151-0/+17
| | | | | | | | | | | | | | | | | | Evaluate in the COMMAND arguments of custom commands the generator expression syntax introduced in commit d2e1f2b4 (Introduce "generator expressions" to add_test, 2009-08-11). These expressions have a syntax like $<TARGET_FILE:mytarget> and are evaluated during build system generation. This syntax allows per-configuration target output files to be referenced in custom command lines.
* | Merge topic 'cross-compile-apple-host'Brad King2010-12-141-15/+24
|\ \ | | | | | | | | | | | | 3b7f901 Fix soname in cross-compiled targets with Mac host (#11547)
| * | Fix soname in cross-compiled targets with Mac host (#11547)Brad King2010-12-091-15/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The soname generation code was compile-time selected instead of runtime selected. The result is that a Mac-compiled cmake used to cross-compile Mac -> Unix generates an soname of the form libfoo.x.y.so instead of libfoo.so.x.y as expected. Instead do a runtime check based on the target platform. Inspired-By: George Staikos <staikos@kde.org>
* | | Merge topic 'parallel-make-install-of-CMake'Brad King2010-12-141-0/+9
|\ \ \ | |_|/ |/| | | | | | | | 608d6bb Fix parallel "make install" of CMake itself
| * | Fix parallel "make install" of CMake itselfBrad King2010-12-091-0/+9
| |/ | | | | | | | | | | | | | | | | | | | | | | | | Avoid tracing dependencies of GLOBAL_TARGET targets. The build system generators are not designed to handle any dependencies that may be discovered. Global targets are only generated by CMake and never have commands that reference targets built in the project anyway. The exception is when building CMake itself there is a special case to use the just-built "cmake" binary in the "install" target so that CMake can replace itself on Windows. Even in this special case we do not want to let the "install" target depend on the "cmake" target. Doing so breaks cases like "make -j4 install".
* | Honor custom command dependencies on imported targets (#10395)Brad King2010-12-081-4/+4
|/ | | | | | | Imported targets do not themselves build, but we can follow dependencies through them to find real targets. This allows imported targets to depend on custom targets that provide the underlying files at build time.
* Define LINK_DEPENDS target property (#11406)Brad King2010-11-051-0/+12
| | | | | Custom Makefile link rules may need to depend on linker scripts. Define this property to allow user-specified link-time dependencies.
* Document ENABLE_EXPORTS behavior on Mac (#11295)Brad King2010-10-111-4/+8
| | | | | Mention that it is implemented with -bundle-loader on platforms that need link-time symbol resolution but that do not use DLL import libs.
* Merge topic 'document-IMPORTED_NO_SONAME'Brad King2010-09-211-0/+18
|\ | | | | | | | | 8f96818 Document IMPORTED_NO_SONAME target property
| * Document IMPORTED_NO_SONAME target propertyBrad King2010-09-171-0/+18
| | | | | | | | | | Commit fd37a6ec (Better linker search path computation, 2008-02-21) added this property but did not document it. Add the documentation.
* | Merge topic 'improve-missing-source-file-error'Brad King2010-09-141-1/+8
|\ \ | | | | | | | | | | | | a6b5ead Report missing source files with context of target
| * | Report missing source files with context of targetBrad King2010-09-131-1/+8
| | | | | | | | | | | | | | | Previously we reported only the CMakeLists.txt file in the directory that adds the target.
* | | No CMAKE_CONFIGURATION_TYPES in single-config generators (#10202)Brad King2010-09-081-12/+1
|/ / | | | | | | | | | | Factor out reading of CMAKE_CONFIGURATION_TYPES and CMAKE_BUILD_TYPE into cmMakefile::GetConfigurations. Read the former only in multi-config generators.
* | Add FOLDER target property, for IDEs (#3796)David Cole2010-09-031-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This work was started from a patch by Thomas Schiffer. Thanks, Thomas! See the newly added documentation of the FOLDER target property for details. Also added global properties, USE_FOLDERS and PREDEFINED_TARGETS_FOLDER. See new docs here, too. By default, the FOLDER target property is used to organize targets into folders in IDEs that have support for such organization. This commit adds "solution folder" support to the Visual Studio generators. Currently works with versions 7 through 10. Also, use the new FOLDER property in the ExternalProject test and in the CMake project itself.