Commit Graph

59 Commits

Author SHA1 Message Date
Brad King 9e64d5b272 ENH: Improve exporting/importing of targets
- Use real name instead of link for location of versioned targets
  - Error when a target is exported multiple times
2008-02-06 14:20:36 -05:00
Brad King efec4f1cd6 COMP: Add missing include for assert. 2008-02-04 19:00:33 -05:00
Brad King 8401c5ba06 ENH: Allow separate installation of shared libs and their links.
- Add NAMELINK_ONLY and NAMELINK_SKIP to INSTALL command
  - Options select a \"namelink\" mode
  - cmInstallTargetGenerator selects files/link based on mode
  - See bug #4419
2008-02-04 17:03:48 -05:00
Brad King 16186ec18c BUG: Remove InstallNameFixupPath from cmTarget and cmInstallTargetGenerator.
- Motivation:
    - It depended on the order of installation
    - It supported only a single destination for each target
    - It created directory portions of an install name without user request
  - Updated ExportImport test to install targets in an order that expoed
    this bug
2008-02-01 13:08:12 -05:00
Brad King 319c4c4d80 ENH: Update cmInstallTargetGenerator to get the shared libraries linked by a target from cmComputeLinkInformation instead of duplicating the computation. 2008-01-29 15:47:18 -05:00
Brad King ffac622a85 ENH: Add cmTarget::GetLinkInformation method to allow several places in the generators to share link information while only computing it once per configuration for a target. Use it to simplify the chrpath feature. 2008-01-29 15:07:33 -05:00
Brad King e3b1bdb058 ENH: Support exporting/importing of AppBundle targets.
- Imported bundles have the MACOSX_BUNDLE property set
  - Added cmTarget::IsAppBundleOnApple method to simplify checks
  - Document BUNDLE keyword in INSTALL command
  - Updated IMPORTED_LOCATION property documentation for bundles
  - Updated ExportImport test to test bundles
2008-01-28 14:46:16 -05:00
Brad King 28ea034737 ENH: Support exporting/importing of Framework targets.
- Imported frameworks have the FRAMEWORK property set
  - Added cmTarget::IsFrameworkOnApple method to simplify checks
  - Also remove separate IMPORTED_ENABLE_EXPORTS property and just use ENABLE_EXPORTS since, like FRAMEWORK, it just represents the target type.
  - Document FRAMEWORK keyword in INSTALL command.
  - Updated IMPORTED_LOCATION property documentation for Frameworks
2008-01-28 13:05:58 -05:00
Brad King 5594ad4885 ENH: Updated exporting and importing of targets to support libraries and 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
2008-01-28 08:38:36 -05:00
Bill Hoffman d92d51429e BUG: fix for bug 6193, fix xcode depend helper 2008-01-10 15:17:23 -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
David Cole 8e4c7b99e1 ENH: Finish up the Framework creation code restructuring. Frameworks build and install now. More work needed on the packaging step. See Tests/Framework for example use. 2007-10-10 11:06:15 -04:00
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
Alexander Neundorf 7db8c86ac9 STYLE: add some newlines to cmake_install.cmake, so it's easier to read
-move the array behind the if, it's unused before it

Alex
2007-08-20 16:59:06 -04:00
Brad King bffcff4530 ENH: Added warning when an install rule is created from an EXCLUDE_FROM_ALL target. Added a foo/preinstall version of targets that need relinking so that exclude-from-all targets can be manually relinked for installation. 2007-08-03 16:31:08 -04:00
Brad King c3fed205e9 COMP: Remove shadowed local. 2007-07-02 16:04:12 -04:00
Brad King 7f29f8966d ENH: Further cleanup of installation script generation. The per-component and per-configuration testing is now done in cmake code instead of in the FILE(INSTALL) command. The generation of the cmake code to do these tests is centralized in cmInstallGenerator. Old-style shared library versioning and component/config support code has been removed from FILE(INSTALL). This commit is surrounded by the tags CMake-InstallGeneratorCleanup2-pre and CMake-InstallGeneratorCleanup2-post. 2007-07-02 14:56:57 -04:00
Brad King 39d1343896 BUG: Fix install_name_tool update of the executable in an installed bundle on OSX. This addresses bug#4534. 2007-07-02 11:31:10 -04:00
Brad King c83ae4673d ENH: Improved indentation of generated cmake_install.cmake code. 2007-07-02 11:02:52 -04:00
Brad King fdf7b203af ENH: First step of install script generator cleanup. Each configuration to be installed is now separately handled instead of using variables to store per-configuration names. For targets the component and configuration install-time tests are now done in the install script instead of in the FILE(INSTALL) command. This cleans things up like not trying to strip a file that was optionally not installed. It also simplifies the code for install_name adjustment on OSX. This commit is surrounded by the tags CMake-InstallGeneratorCleanup1-pre and CMake-InstallGeneratorCleanup1-post. 2007-06-28 16:11:18 -04:00
Alexander Neundorf 617602e9e9 STYLE: preparations for the INSTALL(EXPORT ...) generator
-move std::string Destination to cmInstallGenerator, since all (except
the script one) have it and add a const accessor so it can be queried
-use temporary variables in cmInstallCommand for the generators so they can be reused easier
-some more const

Alex
2007-06-19 11:11:06 -04:00
Alexander Neundorf 0ef8da2a53 STYLE: remove code duplication between PrepareScriptReference and
GetScriptReference, and make the logic for getting the filename public, so
it can be used e.g. for exporting

Alex
2007-06-15 14:27:33 -04:00
Alexander Neundorf 8237518994 BUG: don't strip static libraries, it removes their symbol table, dynamic
libs have an extra symbol table so they still work stripped

Alex
2007-06-15 13:00:54 -04:00
Alexander Neundorf 69d3628461 BUG: don't run strip on OPTIONAL install targets if the file doesn't exist
Alex
2007-06-15 11:12:07 -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 a18d286635 ENH: move hack to fix "new cmake on old build tree on OSX doesn't have CMAKE_INSTALL_NAME_TOOL in the cache" from
cmInstallTargetGenerator.cxx to Darwin.cmake

Alex
2007-05-18 11:57:29 -04:00
Alexander Neundorf aee311a89d STYLE: fix line lengths
Alex
2007-05-18 08:49:06 -04:00
Brad King 42a272428b BUG: Need to use GetSafeDefinition when assigning to a string. 2007-05-17 17:43:32 -04:00
Alexander Neundorf b47807fc15 STYLE: fix indentation
ENH: add hack to make new cmake work with older existing cmake build trees

Alex
2007-05-17 17:21:52 -04:00
Alexander Neundorf 61d3444f93 ENH: merge CMake-CrossCompileBasic to HEAD
-add a RESULT_VARIABLE to INCLUDE()
-add CMAKE_TOOLCHAIN_FILE for specifiying your (potentially crosscompiling) toolchain
-have TRY_RUN() complain if you try to use it in crosscompiling mode (which were compiled but cannot run on this system)
-use CMAKE_EXECUTABLE_SUFFIX in TRY_RUN(), probably TRY_RUN won't be able to
run the executables if they have a different suffix because they are
probably crosscompiled, but nevertheless it should be able to find them
-make several cmake variables presettable by the user: CMAKE_C/CXX_COMPILER, CMAKE_C/CXX_OUTPUT_EXTENSION, CMAKE_SYSTEM_NAME, CMAKE_SYSTEM_INFO_FILE
-support prefix for GNU toolchains (arm-elf-gcc, arm-elf-ar, arm-elf-strip etc.)
-move ranlib on OSX from the file command to a command in executed in cmake_install.cmake
-add support for stripping during install in cmake_install.cmake
-split out cl.cmake from Windows-cl.cmake, first (very incomplete) step to support MS crosscompiling tools
-remove stdio.h from the simple C program which checks if the compiler works, since this may not exist for some embedded platforms
-create a new CMakeFindBinUtils.cmake which collects the search fro ar, ranlib, strip, ld, link, install_name_tool and other tools like these
-add support for CMAKE_FIND_ROOT_PATH for all FIND_XXX commands, which is a
list of directories which will be prepended to all search directories, right
now as a cmake variable, turning it into a global cmake property may need
some more work
-remove cmTestTestHandler::TryExecutable(), it's unused
-split cmFileCommand::HandleInstall() into slightly smaller functions

Alex
2007-05-17 13:20:44 -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
Brad King 7fb8ac8904 BUG: Use GetExecutableNames instead of GetLibraryNames to compute the installation file name for executable targets. 2007-03-16 16:28:30 -04: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 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
Andy Cedilnik 897a2a9029 ENH: Cleanup of install component list. There was already the list in the global generator. Use that one 2006-10-31 14:28:48 -05:00
Andy Cedilnik 605d8871bb STYLE: Fix kwstyle 2006-10-31 06:43:18 -05:00
Andy Cedilnik 7ded253013 ENH: Add support for displaying the list of components 2006-10-30 15:59:54 -05:00
Brad King 934c804ea4 ENH: Added OPTIONAL option to INSTALL command to allow installation of files if they exist while ignoring them otherwise. This addresses bug#2922. 2006-10-05 11:31:57 -04:00
Brad King bed79f6c6b ENH: Implemented INSTALL(DIRECTORY) command and added a test. Re-organized cmFileCommand's implementation of FILE(INSTALL) a bit to help out. This addresses bug#1694 and partially addresses bug#2691. 2006-08-21 16:55:03 -04:00
Brad King 8a72d43c17 ENH: Started implementing INSTALL(DIRECTORY) command mode. This is not yet finished so it is undocumented and there is no test. These changes also separate the notions of file and directory permissions. 2006-08-17 14:48:54 -04:00
Brad King 15a2b5b4e5 STYLE: Fixed long line. 2006-08-02 21:30:58 -04:00
Brad King c9506c30f0 BUG: Fixed shared library version support for Fortran. This addresses bug#3558. 2006-08-01 15:36:49 -04:00
Ken Martin 8e9a6beccc ENH: centralized locaiton of CMakeFiles setting 2006-06-14 12:28:32 -04:00
Brad King bfb0ec58e8 BUG: Adjustment of install_name with install_name_tool should account for DESTDIR when specifying the file to be changed. 2006-06-01 15:08:36 -04:00
Ken Martin ba2b99bb9f STYLE: fix line length 2006-05-11 15:50:11 -04:00
Brad King 50a0f71120 ENH: Added CONFIGURATIONS option to INSTALL command to allow per-configuration install rules. 2006-05-05 14:57:19 -04:00
Brad King 08b14163ee ENH: Added named component installation implementation. Installation behavior should be unchanged unless -DCOMPONENT=<name> is specified when cmake_install.cmake is invoked. 2006-03-30 13:33:48 -05:00
Andy Cedilnik ed5f95cf23 ENH: Add proper support for installing bundles 2006-03-28 13:16:15 -05:00
Brad King 15f7676a6d BUG: Pay attention to the MACOSX_BUNDLE target property only on APPLE platforms. 2006-03-28 10:58:14 -05:00