Building a x86 application with CMake, Ninja and Clang on x64 Windows

旧城冷巷雨未停 提交于 2019-12-02 02:16:26

CMake Issue #16259: "Ninja generator fails with clang-cl when mixing 64/32 bit clang and Visual Studio Environment" suggests utilizing environment variables:

The Ninja generator requires that the environment already be configured for the compiler to produce the desired target. You need to do

>set CC=clang-cl
>set CFLAGS=-m32
>set CXX=clang-cl
>set CXXFLAGS=-m32

to tell CMake how to invoke the compiler for the desired target.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!