MantisBT - CMake
View Issue Details
0012650CMakeModulespublic2012-01-02 18:352016-06-10 14:31
Julien Finet 
Kitware Robot 
normalfeatureN/A
closedmoved 
CMake 2.8.7 
 
0012650: Support duplicate keyword value pairs in CMAKE_PARSE_ARGUMENTS
Being able to specify multiple times the same variable (here TARGETS) could be useful. I took the example from the doc:

  34 # function(MY_INSTALL)
  35 # set(options OPTIONAL FAST)
  36 # set(oneValueArgs DESTINATION RENAME)
  37 # set(multiValueArgs TARGETS CONFIGURATIONS)
  38 # cmake_parse_arguments(MY_INSTALL "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN} )
  39 # ...
  41 # Assume my_install() has been called like this:
  42 # my_install(TARGETS foo DESTINATION bin OPTIONAL TARGETS bar)
  43 #
  44 # After the cmake_parse_arguments() call the macro will have set the following
  45 # variables:
  46 # MY_INSTALL_OPTIONAL = TRUE
  47 # MY_INSTALL_FAST = FALSE (this option was not used when calling my_install()
  48 # MY_INSTALL_DESTINATION = "bin"
  49 # MY_INSTALL_RENAME = "" (was not used)
  50 # MY_INSTALL_TARGETS = "foo;bar"
  51 # MY_INSTALL_CONFIGURATIONS = "" (was not used)
  52 # MY_INSTALL_UNPARSED_ARGUMENTS = ""
Doing so would allow nesting calls without parsing. Keeping the same example:

 function(MY_INSTALL_WITH_FRUIT_DEPENDENCY)
   my_install(TARGET banana apple ${ARGN} )
 end_function()

function(MY_INSTALL_WITH_PERSON_DEPENDENCY)
  my_install(TARGET john alice ${ARGN})
end_functions()
No tags attached.
Issue History
2012-01-02 18:35Julien FinetNew Issue
2012-08-11 21:09David ColeStatusnew => backlog
2012-08-11 21:09David ColeNote Added: 0030344
2016-06-10 14:28Kitware RobotNote Added: 0041951
2016-06-10 14:28Kitware RobotStatusbacklog => resolved
2016-06-10 14:28Kitware RobotResolutionopen => moved
2016-06-10 14:28Kitware RobotAssigned To => Kitware Robot
2016-06-10 14:31Kitware RobotStatusresolved => closed

Notes
(0030344)
David Cole   
2012-08-11 21:09   
Sending old, never assigned issues to the backlog.

(The age of the bug, plus the fact that it's never been assigned to anyone means that nobody is actively working on it...)

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 who has the bandwidth to take it on, and ferry a fix through to our 'next' branch for dashboard testing.
(0041951)
Kitware Robot   
2016-06-10 14:28   
Resolving issue as `moved`.

This issue tracker is no longer used. Further discussion of this issue may take place in the current CMake Issues page linked in the banner at the top of this page.