summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefileExecutableTargetGenerator.cxx
Commit message (Collapse)AuthorAgeFilesLines
* Port some of the generator API to cmGeneratorTarget.Stephen Kelly2013-11-221-3/+3
| | | | | | | Just enough to reach the BuildMacContentDirectory method and the NeedRelinkBeforeInstall methods. In the future, those methods can be moved to cmGeneratorTarget.
* Revert "Use --sysroot when cross compiling."Stephen Kelly2013-07-121-16/+0
| | | | | | | This reverts commit de4da665d3205afa239749c41513a315c3831f51. This feature is not yet ready for release. It needs to be merged with the CMAKE_OSX_SYSROOT feature.
* Use --sysroot when cross compiling.Stephen Kelly2013-06-071-0/+16
| | | | | | | | | | As CMAKE_ROOT_FIND_PATH can be a list, a new CMAKE_SYSROOT is introduced, which is never a list. The contents of this variable is passed to supporting compilers as --sysroot. It is also accounted for when processing implicit link directories reported by the compiler, and when generating RPATH information.
* Refactor how bundles and frameworks are supported.Clinton Stimpson2013-05-231-4/+1
| | | | | | | | | | | | | | | | Make handling of directory separators consistent between non-bundle and bundle code. Remove xcode specific flag from cmTarget when getting install_name. Add (more) consistent convenience functions in cmTarget to get directories inside of bundles and frameworks to add files to. This refactor also fixes bug #12263 where frameworks had the wrong install name when SKIP_BUILD_RPATH. Also make install_name for frameworks consistent between Makefile and Xcode generator.
* Merge topic 'ninja-LIBPATH'Brad King2012-10-021-5/+7
|\ | | | | | | | | | | | | 1e47ccb Ninja: add option to enforce usage of response files e31df03 Ninja: move <OBJECTS> in front of the first linker option 8d674e7 Ninja: move -LIBPATH behind -link option
| * Ninja: move -LIBPATH behind -link optionPeter Kümmel2012-10-011-5/+7
| | | | | | | | Don' pass linker option to the compile
* | Merge topic 'vs-pdb-output'Brad King2012-10-011-1/+6
|\ \ | |/ |/| | | | | | | | | | | 2ccca05 Run PDBDirectoryAndName test on MSVC and Intel efc83b3 Document that PDB_(NAME|OUTPUT_DIRECTORY) are ignored for VS 6 b294457 Verify that PDB_(NAME|OUTPUT_DIRECTORY) are honored in test 3f60dbf Add PDB_OUTPUT_DIRECTORY and PDB_NAME target properties (#10830)
| * Add PDB_OUTPUT_DIRECTORY and PDB_NAME target properties (#10830)Yuchen Deng2012-09-251-1/+6
| | | | | | | | | | | | | | This enables changing the name and output folder of the debug symbol files produced by MS compilers. Inspired-by: Thomas Bernard <thomas.bernard@ipetronik.com>
* | Port cmLocalGenerator::GetTargetFlags to cmGeneratorTarget.Stephen Kelly2012-09-191-1/+2
| |
* | Make cmLocalGenerator::AddArchitectureFlags take a cmGeneratorTarget.Stephen Kelly2012-09-191-1/+1
|/
* Re-factor bundle content copying rules generation.Nicolas Despres2012-07-171-3/+2
|
* Re-factor OS X bundle and framework generation.Nicolas Despres2012-07-171-30/+16
|
* Remove trailing white-spaces.Nicolas Despres2012-07-171-1/+1
|
* Add CMAKE_GNUtoMS option to convert GNU .dll.a to MS .libBrad King2011-12-051-0/+7
| | | | | | | | | | | | | | | | 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 makefile generator link rule lookup into helper functionBrad King2011-12-051-2/+1
| | | | | This provides a place in the makefile generators to adjust the link rules for both libraries and executables.
* Generate target-wide flags before individual build rulesBrad King2011-03-171-3/+3
| | | | | | | This switches the internal generation order but does not affect the results. The new order ensures that any internal state changed by generating target-wide flags is known when the individual rules that use those flags are generated.
* Consolidate duplicate link rule make dependency codeBrad King2010-11-051-26/+1
| | | | | Factor code previously duplicated for library and executable rules into a common method.
* Evaluate <OBJECT_DIR> rule variable for executablesBrad King2010-09-161-0/+7
| | | | | Previously this placeholder was evaluated only for libraries. Make it work for executables too.
* -improve crosscompiling from Linux to iphone (#10526)Alex Neundorf2010-05-011-2/+0
| | | | | | Patch by Karol Krizka Alex
* Fix line-too-long style violationsBrad King2009-10-231-1/+2
| | | | | The commit "Define per-target OSX_ARCHITECTURES property" introduced some long lines. This wraps them into multiple shorter lines.
* Define per-target OSX_ARCHITECTURES propertyBrad King2009-10-211-0/+4
| | | | | | | | | | | The CMAKE_OSX_ARCHITECTURES variable works only as a global setting. This commit defines target properties OSX_ARCHITECTURES OSX_ARCHITECTURES_<CONFIG> to specify OS X architectures on a per-target and per-configuration basis. See issue #8725.
* Do not use -fPIC to link executablesBrad King2009-10-081-5/+0
| | | | | | | | | | | | | | The commit "add support for borland run time flag for shared builds" started using the value of CMAKE_SHARED_LIBRARY_CXX_FLAGS to link executables because Borland requires some flags both at compile and link time. This change ended up propagating all the way to the current Makefile generators and the behavior applies on all platforms. In general it is incorrect to use these flags to link executables. The commit "Split Borland compiler information files" re-wrote Borland support to work without this behavior, so we remove it in this commit. Patch from Ben Hutchings. See issue #9659.
* Centralize language flag addition for MakefilesBrad King2009-10-021-3/+2
| | | | | | We create cmMakefileTargetGenerator::AddFeatureFlags to consolidate addition of language flags. Currently it just adds the flags from generic per-language flag variables (AddLanguageFlags).
* Fix use of module .def files for MS toolsBrad King2009-09-291-0/+2
| | | | | | | We recognize .def source files and map them to the /DEF:<file> option in the MSVC tools. Previously this worked only for shared libraries. This commit cleans up the implementation and makes it work for executables too. See issue #9613.
* Convert CMake to OSI-approved BSD LicenseBrad King2009-09-281-14/+9
| | | | | | | This converts the CMake license to a pure 3-clause OSI-approved BSD License. We drop the previous license clause requiring modified versions to be plainly marked. We also update the CMake copyright to cover the full development time range.
* Do not call CollapseFullPath for PDB file namesBrad King2009-09-171-1/+1
| | | | | | | | | | | | | | | | Some vendor tools convert PDB file names given on the command line to lower-case before creating the file. When CMake places a mixed-case PDB file name into the build system, the file does not exist the first time and it is written with mixed case. After the first build though the native tool has created a lower-case version of the file. If CMake does CollapseFullPath again, the file exists so the actual-case lookup gets the lower-case name. This causes the build files to change so the project rebuilds. The solution is to avoid calling CollapseFullPath for files generated by the build. In the case of PDB files we already construct them from paths that have been collapsed, so we can just skip the call altogether. See issue #9350.
* ENH: Pass config to cmTarget::GetLinkerLanguageBrad King2009-07-081-1/+2
| | | | | | This passes the build configuration to most GetLinkerLanguage calls. In the future the linker language will account for targets linked in each configuration.
* ENH: Pass config to cmTarget RPATH install methodsBrad King2009-07-081-1/+1
| | | | | This passes the build configuration to cmTarget methods IsChrpathUsed and NeedRelinkBeforeInstall. Later these methods will use the value.
* ENH: Simpler cmTarget::GetLinkerLanguage signatureBrad King2009-07-071-2/+1
| | | | | | | This method previously required the global generator to be passed, but that was left from before cmTarget had its Makefile member. Now the global generator can be retrieved automatically, so we can drop the method argument.
* ENH: Pass config to cmTarget::GetDirectory()Brad King2009-07-031-3/+3
| | | | | | | This teaches the makefile generators to always pass the configuration name to the cmTarget::GetDirectory method. Later this will allow per-configuration target output directories, and it cleans up use of the current API.
* ENH: Create cmMakefileTargetGenerator::ConfigNameBrad King2009-07-031-7/+5
| | | | | | This member stores the build configuration for which Makefiles are being generated. It saves repeated lookup of the equivalent member from cmLocalUnixMakefileGenerator3, making code shorter and more readable.
* ENH: Remove cmTarget::GetExecutableCleanNamesBrad King2009-05-011-21/+7
| | | | This method was redundant with GetExecutableNames.
* ENH: Allow projects to disable per-rule echo linesBrad King2009-03-161-7/+10
| | | | | | | | | This creates global property RULE_MESSAGES which can be set to disbale per-rule progress and action reporting. On Windows, these reports may cause a noticable delay due to the cost of starting extra processes. This feature will allow scripted builds to avoid the cost since they do not need detailed information anyway. This replaces the RULE_PROGRESS property created earlier as it is more complete. See issue #8726.
* ENH: Define RULE_LAUNCH_* propertiesBrad King2009-02-101-0/+2
| | | | | | | This defines global, directory, and target properties RULE_LAUNCH_COMPILE, RULE_LAUNCH_LINK, and RULE_LAUNCH_CUSTOM. Their values specify 'launcher' command lines which are prefixed to compile, link, and custom build rules by Makefile generators.
* ENH: Give target in which custom commands buildBrad King2009-02-101-3/+6
| | | | | | This gives the cmTarget instance for which custom command rules are being generated to cmLocalUnixMakefileGenerator3::AppendCustomCommands. It will be useful in the future.
* BUG: Do not re-generate after a AppBundle buildBrad King2009-02-061-2/+2
| | | | | | | A previous change accidentally added the MacOS content directory and Info.plist files created for MACOSX_BUNDLE executables to the list of CMake input files. This causes CMake to re-generate the project too often. These items should be added to the list of CMake output files.
* ENH: Factor out listing of objects on command lineBrad King2008-10-151-26/+2
| | | | | | Previously generation of object file lists for linker and cleaning command lines was duplicated for library and executable target generators. This combines the implementations.
* STYLE: Remove computed but unused variable.Brad King2008-10-151-3/+0
| | | | | An old list of object files for cleaning seems to have been left behind. This removes it.
* ENH: Fix optional use of relative paths.Brad King2008-10-091-2/+2
| | | | | | | These changes refactor cmLocalGenerator methods Convert and ConvertToOutputForExisting to support references inside the build tree using relative paths. After this commit, all tests pass with Makefile generators when relative paths are enabled by default. See issue #7779.
* BUG: Fix issue #3648 - make sure CMake reruns if a Bundle application's ↵David Cole2008-09-021-0/+2
| | | | directory is removed or if it's Info.plist file disappears since those elements are put in place at CMake configure time.
* BUG: Do not create target output directory in cmTarget. Let the generators ↵Brad King2008-04-071-0/+2
| | | | do it.
* ENH: Handle large object file lists on some platformsBrad King2008-02-271-1/+24
| | | | | | | - Use a response file when enabled by CMAKE_<LANG>_USE_RESPONSE_FILE_FOR_OBJECTS - Enable for C and CXX with cl (MSVC) - Enable for Fortran with ifort (Intel Fortran)
* BUG: Link scripts should be generated with copy-if-different and included as ↵Brad King2008-02-201-1/+1
| | | | a dependency of the link rule.
* ENH: Cleanup impl of PUBLIC_HEADER, PRIVATE_HEADER, and RESOURCE propertiesBrad King2008-02-181-16/+34
|
* ENH: Cleanup building of OS X bundle contentBrad King2008-02-151-29/+1
| | | | | | | | | | - Fixes repeated rebuild of bundles by Makefile generators - Add special rules to copy sources to their MACOSX_PACKAGE_LOCATION bundle directory - Remove MacOSX_Content language hack - Remove EXTRA_CONTENT property - Remove MACOSX_CONTENT - Remove corresponding special cases in object names
* ENH: Allow multiple OS X applications bundles to be created in a single ↵Brad King2008-02-141-12/+4
| | | | build directory. Converted Info.plist files to be generated directly instead of configured with make variables. The MACOSX_BUNDLE_* variables are now properties (and vars for compatibility).
* ENH: Enable use of link script whenever incremental archive construction ↵Brad King2008-01-301-0/+6
| | | | rules are available. Enable use of archive construction rules on MSYS.
* ENH: Updated exporting and importing of targets to support libraries and ↵Brad King2008-01-281-2/+2
| | | | | | | | | | | | | | | | | | configurations. - Created cmExportFileGenerator hierarchy to implement export file generation - Installed exports use per-config import files loaded by a central one. - Include soname of shared libraries in import information - Renamed PREFIX to NAMESPACE in INSTALL(EXPORT) and EXPORT() commands - Move addition of CMAKE_INSTALL_PREFIX to destinations to install generators - Import files compute the installation prefix relative to their location when loaded - Add mapping of importer configurations to importee configurations - Rename IMPORT targets to IMPORTED targets to distinguish from windows import libraries - Scope IMPORTED targets within directories to isolate them - Place all properties created by import files in the IMPORTED namespace - Document INSTALL(EXPORT) and EXPORT() commands. - Document IMPORTED signature of add_executable and add_library - Enable finding of imported targets in cmComputeLinkDepends
* ENH: Simplified and moved link script implementation up from ↵Brad King2007-12-281-36/+66
| | | | cmMakefileLibraryTargetGenerator to cmMakefileTargetGenerator and use for cmMakefileExecutableTargetGenerator too. This addresses bug #6192.
* ENH: Add a depends check step to custom targets. Add support for the ↵Brad King2007-12-211-3/+4
| | | | IMPLICIT_DEPENDS feature of custom commands when building in custom targets. Convert multiple-output pair checks to be per-target instead of global.