[LLVMdev] [patch] EXPORTED_SYMBOL_FILE using mingw and cmake

Mueller-Roemer, Johannes Sebastian Johannes.Sebastian.Mueller-Roemer at igd.fraunhofer.de
Wed Jul 23 11:45:55 PDT 2014


The new patch works fine, but considering the discussion on the CMake bug tracker, I'm would say that TO_NATIVE_PATH shouldn't be used at all.
________________________________________
From: Dan Liew [dan at su-root.co.uk]
Sent: Wednesday, July 23, 2014 10:38 AM
To: Mueller-Roemer, Johannes Sebastian
Cc: llvmdev at cs.uiuc.edu
Subject: Re: [LLVMdev] [patch] EXPORTED_SYMBOL_FILE using mingw and cmake

Okay I guess the test would be something like this then

if (CMAKE_GENERATOR STREQUAL "MinGW Makefiles")
  # mingw workaround, as file(TO_NATIVE_PATH ...) is implemented incorrectly
  # See http://public.kitware.com/Bug/print_bug_page.php?bug_id=5939
  string(REPLACE / \\ export_file_backslashes "${export_file}")
else()
  file(TO_NATIVE_PATH "${export_file}" export_file_backslashes)
endif()

I've written this into patch applied against trunk. Could you test
this (I don't use MinGW and don't have time to set it up) and confirm
it works? It would be great if you could test that the
file(TO_NATIVE_PATH ...) still gets used for the MSYS-Makefiles and
Cygwin generators.

It's also good to see some activity on the CMake bug report :)

If it all works then I can commit on your behalf.

Thanks,
Dan




More information about the llvm-dev mailing list