[ 
https://issues.apache.org/jira/browse/XERCESC-2252?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2252:
----------------------------------
    Fix Version/s: 3.3.0

> Unable to compile with clang-cl on Windows
> ------------------------------------------
>
>                 Key: XERCESC-2252
>                 URL: https://issues.apache.org/jira/browse/XERCESC-2252
>             Project: Xerces-C++
>          Issue Type: Bug
>          Components: Build
>    Affects Versions: 3.2.5
>            Reporter: Mark
>            Assignee: Scott Cantor
>            Priority: Major
>             Fix For: 3.3.0
>
>
> The following error happens when trying to build on Windows, using LLVM 
> 17.0.6:
>  
>  
> {code:java}
> [287/299] Building RC object 
> src\CMakeFiles\xerces-c.dir\Release\xercesc\util\version.rc.res
> FAILED: src/CMakeFiles/xerces-c.dir/Release/xercesc/util/version.rc.res 
> "C:\Program Files\Microsoft Visual 
> Studio\2022\Professional\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\cmake.exe"
>  -E cmake_llvm_rc 
> D:\conan\p\b\xerce57c5f34a11450\b\build\src\xercesc\util\version.rc 
> src\CMakeFiles\xerces-c.dir\Release\xercesc\util\version.rc.res.pp 
> C:\PROGRA~1\LLVM\bin\clang-cl.exe -DHAVE_CONFIG_H=1 
> -DXERCES_BUILDING_LIBRARY=1 -DXERCES_DLL_NAME=\"xerces-c_3_2.dll\0\" 
> -D_THREAD_SAFE=1 -Dxerces_c_EXPORTS -DCMAKE_INTDIR=\"Release\" -DRC_INVOKED 
> -I D:\conan\p\b\xerce57c5f34a11450\b\build -I 
> D:\conan\p\b\xerce57c5f34a11450\b\src\src -I 
> D:\conan\p\b\xerce57c5f34a11450\b\build\src -DWIN32 -clang:-MD -clang:-MF 
> -clang:src\CMakeFiles\xerces-c.dir\Release\xercesc\util\version.rc.res.d  -E 
> -- D:\conan\p\b\xerce57c5f34a11450\b\build\src\xercesc\util\version.rc ++ 
> llvm-rc -DHAVE_CONFIG_H=1 -DXERCES_BUILDING_LIBRARY=1 
> -DXERCES_DLL_NAME=\"xerces-c_3_2.dll\0\" -D_THREAD_SAFE=1 -Dxerces_c_EXPORTS 
> -DCMAKE_INTDIR=\"Release\" -I SOURCE_DIR -I 
> D:\conan\p\b\xerce57c5f34a11450\b\build -I 
> D:\conan\p\b\xerce57c5f34a11450\b\src\src -I 
> D:\conan\p\b\xerce57c5f34a11450\b\build\src -DWIN32 -clang:-MD -clang:-MF 
> -clang:src\CMakeFiles\xerces-c.dir\Release\xercesc\util\version.rc.res.d /fo 
> src\CMakeFiles\xerces-c.dir\Release\xercesc\util\version.rc.res 
> src\CMakeFiles\xerces-c.dir\Release\xercesc\util\version.rc.res.pp
> llvm-rc: Error in VERSIONINFO statement (ID 1): 
> Non-ASCII 8-bit codepoint (´┐¢) can't be interpreted in the current codepage 
> {code}
>  
>  
> This is caused by [llvm-rc chokes on cp1252 · Issue #57367 · 
> llvm/llvm-project 
> (github.com)|https://github.com/llvm/llvm-project/issues/57367]
>  
> And can be easily fixed by adding these lines to the CMakeLists.txt:
> {code:java}
> if (WIN32 AND CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
>     set(CMAKE_RC_FLAGS="-C 1252")
> endif() {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org

Reply via email to