wl-chuang / libyuv

Automatically exported from code.google.com/p/libyuv
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Windows Clang build #412

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Follow chrome instructions
https://code.google.com/p/chromium/wiki/Clang#Windows

1. install cmake

2. set GYP_DEFINES=clang=1
call python tools\clang\scripts\update.py

3.call python gyp_libyuv -fninja libyuv_test.gyp
ninja -C out\Debug
ninja -C out\Release

In step 2 the compiler source code downloads but the build of the compiler 
fails.

Original issue reported on code.google.com by fbarch...@google.com on 10 Mar 2015 at 11:29

GoogleCodeExporter commented 9 years ago
chromium provides a local repo:

set GYP_DEFINES=clang=1
set LLVM_REPO_URL=svn://svn.chromium.org/llvm-project
call python tools\clang\scripts\update.py

Original comment by fbarch...@google.com on 11 Mar 2015 at 4:52

GoogleCodeExporter commented 9 years ago
needed to uninstall mingw, and then tools\clang\scripts\update.py works.
But the build fails

[61/67] CXX obj\util\psnr.psnr.obj
..\..\util\psnr.cc(210,22) :  error(clang): redefinition of '__cpuid'
static __inline void __cpuid(int cpu_info[4], int info_type) {
                     ^
c:\src\libyuv3\trunk\third_party\llvm-build\Release+Asserts\bin\..\lib\clang\3.7
.0\include\intrin.h(908,1) :  note(clang): previous definition is here
__cpuid(int __info[4], int __level) {
^
1 error generated.

Original comment by fbarch...@google.com on 12 Mar 2015 at 9:41