set(single_path "c:/foo/bar")
set(several_paths "c:/foo/1.txt;c:/bar/2.txt")
file(TO_NATIVE_PATH "${single_path}" single_path_result)
file(TO_NATIVE_PATH "${several_paths}" several_paths_result)
message("single='${single_path_result}'")
message("several='${several_paths_result}'")


On Tue, Oct 14, 2008 at 6:16 PM, Eric Noulard <[EMAIL PROTECTED]> wrote:
> 2008/10/14 Nicolas Desprès <[EMAIL PROTECTED]>:
>> On Tue, Oct 14, 2008 at 4:48 PM, Andy Lego <[EMAIL PROTECTED]> wrote:
>>> Hi,
>>>
>>> Look at FILE and STRING commands.
>>
>> Thanks. That's what I did.
>
> May be
>
> FILE(TO_NATIVE_PATH ${in} ${out})
>
> is easier than string(REPLACE ...
>
>  TO_NATIVE_PATH works just like TO_CMAKE_PATH, but will convert from a
>       cmake style path into the native path style \ for windows and / for
>       UNIX.
>

For some reason, I don't understand the following line did not work...

     file(TO_NATIVE_PATH "${${var}}" ${var}_in)

-- 
Nicolas Desprès
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to