MantisBT - CMake
View Issue Details
0008920CMakeCMakepublic2009-04-22 09:292015-11-02 09:13
Ralf Habacker 
Brad King 
normalfeaturealways
closedfixed 
CMake-2-6 
CMake-2-8 
0008920: different named for created files of a given target
There are situations where a specific type of file created by a target need to have a different name (see thread "msvc linking problem k3b on windows" on the cmake mailing list)

I suggest to add the following properties

OUTPUT_RUNTIME_NAME
OUTPUT_ARCHIVE_NAME
OUTPUT_LIBRARY_NAME

to the "set_target_properties" command, which enforce developers to be able to change individual types of generated files in a generic way.

For win32 the individual types

OUTPUT_RUNTIME_NAME -> basename for dll/exe files
OUTPUT_ARCHIVE_NAME -> basename for import libraries
OUTPUT_LIBRARY_NAME -> basename for static libraries

No tags attached.
Issue History
2009-04-22 09:29Ralf HabackerNew Issue
2009-04-22 09:41Brad KingStatusnew => assigned
2009-04-22 09:41Brad KingAssigned To => Brad King
2009-04-22 09:46Brad KingNote Added: 0016131
2009-05-01 09:46Brad KingNote Added: 0016273
2012-08-13 10:36Brad KingStatusassigned => backlog
2012-08-13 10:36Brad KingNote Added: 0030493
2015-04-13 13:43Stephen KellyNote Added: 0038502
2015-04-13 14:12Brad KingNote Added: 0038505
2015-04-13 14:13Brad KingStatusbacklog => resolved
2015-04-13 14:13Brad KingResolutionopen => fixed
2015-04-13 14:13Brad KingFixed in Version => CMake-2-8
2015-11-02 09:13Robert MaynardNote Added: 0039770
2015-11-02 09:13Robert MaynardStatusresolved => closed

Notes
(0016131)
Brad King   
2009-04-22 09:46   
To follow the RUNTIME_OUTPUT_DIRECTORY, LIBRARY_OUTPUT_DIRECTORY, and ARCHIVE_OUTPUT_DIRECTORY properties which already exist, it should be

  RUNTIME_OUTPUT_NAME -> basename for dll/exe files
  LIBRARY_OUTPUT_NAME -> basename for UNIX shared libs, nothing on windows
  ARCHIVE_OUTPUT_NAME -> basename for static libs and import libs
(0016273)
Brad King   
2009-05-01 09:46   
ENH: Refactor target output file type computation
/cvsroot/CMake/CMake/Source/cmTarget.cxx,v <-- Source/cmTarget.cxx
new revision: 1.240; previous revision: 1.239
/cvsroot/CMake/CMake/Source/cmTarget.h,v <-- Source/cmTarget.h
new revision: 1.122; previous revision: 1.121

ENH: Allow more specification of target file names
/cvsroot/CMake/CMake/Source/cmTarget.cxx,v <-- Source/cmTarget.cxx
new revision: 1.241; previous revision: 1.240
/cvsroot/CMake/CMake/Source/cmTarget.h,v <-- Source/cmTarget.h
new revision: 1.123; previous revision: 1.122
/cvsroot/CMake/CMake/Tests/ExportImport/Export/CMakeLists.txt,v <-- Tests/ExportImport/Export/CMakeLists.txt
new revision: 1.17; previous revision: 1.16
/cvsroot/CMake/CMake/Tests/SimpleInstall/CMakeLists.txt,v <-- Tests/SimpleInstall/CMakeLists.txt
new revision: 1.103; previous revision: 1.102
(0030493)
Brad King   
2012-08-13 10:36   
Sending issues I'm not actively working on to the backlog to await someone with time for them.

If an issue you care about is sent to the backlog when you feel it should have been addressed in a different manner, please bring it up on the CMake mailing list for discussion. Sign up for the mailing list here, if you're not already on it:

 http://www.cmake.org/mailman/listinfo/cmake [^]

It's easy to re-activate a bug here if you can find a CMake developer or contributor who has the bandwidth to take it on.
(0038502)
Stephen Kelly   
2015-04-13 13:43   
I think this is done?
(0038505)
Brad King   
2015-04-13 14:12   
Yes, this is done as of CMake 2.8.0.

The commit referenced in 0008920:0016273 is:

 ENH: Allow more specification of target file names
 http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=2740db5e [^]
(0039770)
Robert Maynard   
2015-11-02 09:13   
Closing resolved issues that have not been updated in more than 4 months.