I&#39;ve got the following code in my top-level CMakeLists.txt file:<br><br>IF (WIN32)<br>    SET(CMAKE_INSTALL_PREFIX &quot;$ENV{ProgramFiles}\${PROJECT_NAME}_${VERSION}&quot;)<br>    SET(CPACK_GENERATOR &quot;ZIP&quot;)<br>
ELSE(WIN32)<br>    SET(CMAKE_INSTALL_PREFIX &quot;/opt/${PROJECT_NAME}_${VERSION}&quot;)<br>    SET(CPACK_GENERATOR &quot;RPM&quot;)<br>ENDIF(WIN32)<br><br>Regardless of how I try to construct the Win32 CMAKE_INSTALL_PREFIX, I get some kind of quoting-related<br>
problem e,g:<br><br>CMake Error: Invalid escape sequence \P<br>Syntax error in cmake code at<br>C:/Program Files/CMake 2.6/share/cmake-2.6/Modules/CPack.cmake:788:<br>syntax error, unexpected cal_ERROR, expecting $end (4), when parsing string &quot;C:\Program Files\MDP_1.0.0&quot;<br>
<br>with variants, depending on presence/absence of quotes and number of \ <br><br>Can someone put me out of my misery and tell me what I need to do to get this right ?<br><br>Steve Collyer<br>