MantisBT - CMake
View Issue Details
0015509CMakeCMakepublic2015-04-10 15:182016-06-10 14:31
Cedric Guerin 
Kitware Robot 
normalfeatureN/A
closedmoved 
CMake 3.2.1 
 
0015509: CMake needs a generator expression equivalent to TO_NATIVE_PATH.
Some commands which accept generator expressions also need native pathes as arguments (typically programs parameters passed to add_custom_command on Windows) and the conversion can't be done with the file(TO_NATIVE_PATH ...) command since the generator expression hasn't been evaluated yet.

I have read the CONTRIBUTING.rst (but am not interested in joining the mailing list, thank you), so feel free to use the trivial attached patch as you see fit (it may need to be updated in light of whatever will be done in response to http://public.kitware.com/Bug/view.php?id=5939 [^]).
No tags attached.
related to 0005939closed Bill Hoffman TO_NATIVE_PATH incorrect on MinGW 
patch 0001-Added-a-TO_NATIVE_PATH-generator-expression.patch (1,881) 2015-04-10 15:18
https://public.kitware.com/Bug/file/5424/0001-Added-a-TO_NATIVE_PATH-generator-expression.patch
Issue History
2015-04-10 15:18Cedric GuerinNew Issue
2015-04-10 15:18Cedric GuerinFile Added: 0001-Added-a-TO_NATIVE_PATH-generator-expression.patch
2015-04-10 15:29Brad KingNote Added: 0038486
2015-04-10 15:57Cedric GuerinNote Added: 0038487
2015-04-10 16:24Brad KingRelationship addedrelated to 0005939
2016-06-10 14:29Kitware RobotNote Added: 0042756
2016-06-10 14:29Kitware RobotStatusnew => resolved
2016-06-10 14:29Kitware RobotResolutionopen => moved
2016-06-10 14:29Kitware RobotAssigned To => Kitware Robot
2016-06-10 14:31Kitware RobotStatusresolved => closed

Notes
(0038486)
Brad King   
2015-04-10 15:29   
As discussed in 0005939:0036429, 0005939:0036437, and 0005939:0036440, the concept of a TO_NATIVE_PATH is ill-defined because we don't know what "native" is targeting. Even ConvertToOutputPath may need to be refactored, so I'm hesitant to expose it publicly through any more interfaces than it already is.

Instead some set of well-defined conversions needs to be enumerated. For the purposes of this issue we need to come up with a different name for the proposed generator expression and define precise behavior for it. In particular, it should be defined for use in shell commands with add_custom_command.
(0038487)
Cedric Guerin   
2015-04-10 15:57   
That's fine with me. I don't mind waiting (I'm already building CMake from the source anyway) and the patch is archived in case other people are looking for the feature right now.

Once you find an acceptable solution to 0005939 (no opinion, I'm not affected) it should still be trivial to expose the same feature(s) as a generator expression with an appropriate name where it matters.
(0042756)
Kitware Robot   
2016-06-10 14:29   
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.