[cfe-users] Build Errors in building Clang in Visual Studio 2012/ Windows-32-bit

asif saeed asif.lse2 at gmail.com
Wed May 22 23:06:55 PDT 2013


Hi,

I successfully built the LLVM.sln using CMake, after help from this mailing
list (Kim Gräsman). However, building the LLVM in Visual Studio 2012 on
Windows 7 32-bit gives me 1 compiler error (about memcpy) and many linker
errors (about LLVMR600CodeGen.lib):

Build Output with Errors
-----------------------------------------------------------------

44>C:/llvm_clang/llvm/include\llvm/ADT/SmallVector.h(353): error C2872:
'memcpy' : ambiguous symbol
44>          could be 'C:\Program Files\Microsoft Visual Studio
11.0\VC\include\string.h(54) : void *memcpy(void *,const void *,size_t)'
44>          or
'C:/llvm_clang/build/include\llvm/IR/Intrinsics.gen(1050) :
llvm::Intrinsic::ID memcpy'

59>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
61>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
62>------ Build started: Project: FrontendTests, Configuration: Release
Win32 ------
60>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
63>------ Build started: Project: DynamicASTMatchersTests, Configuration:
Release Win32 ------
64>------ Build started: Project: libclang, Configuration: Release Win32
------
62>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
65>------ Build started: Project: BugpointPasses, Configuration: Release
Win32 ------
63>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
64>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
66>------ Build started: Project: ClangUnitTests, Configuration: Release
Win32 ------
67>------ Build started: Project: macho-dump, Configuration: Release Win32
------
68>------ Build started: Project: UnitTests, Configuration: Release Win32
------
69>------ Build started: Project: arcmt-test, Configuration: Release Win32
------
70>------ Build started: Project: c-arcmt-test, Configuration: Release
Win32 ------
67>LINK : fatal error LNK1181: cannot open input file
'..\..\lib\Release\LLVMR600CodeGen.lib'
71>------ Build started: Project: c-index-test, Configuration: Release
Win32 ------
69>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
70>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\libclang.lib'
72>------ Build started: Project: opt, Configuration: Release Win32 ------
73>------ Build started: Project: clang, Configuration: Release Win32 ------
74>------ Build started: Project: clang-check, Configuration: Release Win32
------
74>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
71>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\libclang.lib'
75>------ Build started: Project: clang-format, Configuration: Release
Win32 ------
75>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
72>LINK : fatal error LNK1181: cannot open input file
'..\..\lib\Release\LLVMR600CodeGen.lib'
76>------ Build started: Project: diagtool, Configuration: Release Win32
------
77>------ Build started: Project: llc, Configuration: Release Win32 ------
73>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
76>LINK : fatal error LNK1181: cannot open input file
'..\..\..\..\lib\Release\LLVMR600CodeGen.lib'
77>LINK : fatal error LNK1181: cannot open input file
'..\..\lib\Release\LLVMR600CodeGen.lib'
78>------ Build started: Project: llvm-mc, Configuration: Release Win32
------
79>------ Build started: Project: llvm-objdump, Configuration: Release
Win32 ------
80>------ Build started: Project: llvm-readobj, Configuration: Release
Win32 ------
81>------ Build started: Project: llvm-rtdyld, Configuration: Release Win32
------
78>LINK : fatal error LNK1181: cannot open input file
'..\..\lib\Release\LLVMR600CodeGen.lib'
79>LINK : fatal error LNK1181: cannot open input file
'..\..\lib\Release\LLVMR600CodeGen.lib'
80>LINK : fatal error LNK1181: cannot open input file
'..\..\lib\Release\LLVMR600CodeGen.lib'
81>LINK : fatal error LNK1181: cannot open input file
'..\..\lib\Release\LLVMR600CodeGen.lib'
82>------ Build started: Project: check-clang, Configuration: Release Win32
------
82>  Building Custom Rule C:/llvm_clang/llvm/tools/clang/test/CMakeLists.txt
83>------ Build started: Project: check-llvm, Configuration: Release Win32
------
82>  CMake does not need to re-run because
C:\llvm_clang\build\tools\clang\test\CMakeFiles\generate.stamp is
up-to-date.
82>  Running the Clang regression tests
84>------ Build started: Project: ALL_BUILD, Configuration: Release Win32
------
85>------ Skipped Build: Project: check-all, Configuration: Release Win32
------
85>Project not selected to build for this solution configuration
82>  lit.py: LitConfig.py:103: note: Unable to find 'bash.exe'.
82>  lit.py: lit.cfg:177: fatal: couldn't find 'clang' program, try setting
CLANG in your environment
82>C:\Program
Files\MSBuild\Microsoft.Cpp\v4.0\V110\Microsoft.CppCommon.targets(172,5):
error MSB6006: "cmd.exe" exited with code 2.
86>------ Skipped Build: Project: clang-test, Configuration: Release Win32
------
86>Project not selected to build for this solution configuration
83>  Building Custom Rule C:/llvm_clang/llvm/test/CMakeLists.txt
83>  CMake does not need to re-run because
C:\llvm_clang\build\test\CMakeFiles\generate.stamp is up-to-date.
83>  Running the LLVM regression tests
83>  Could not find llc in C:/llvm_clang/build/bin/Release
83>  lit.py: LitConfig.py:103: note: Unable to find 'bash.exe'.
83>C:\Program
Files\MSBuild\Microsoft.Cpp\v4.0\V110\Microsoft.CppCommon.targets(172,5):
error MSB6006: "cmd.exe" exited with code 42.
84>  Build all projects
87>------ Skipped Build: Project: check, Configuration: Release Win32 ------
87>Project not selected to build for this solution configuration
88>------ Skipped Build: Project: PACKAGE, Configuration: Release Win32
------
88>Project not selected to build for this solution configuration
89>------ Skipped Build: Project: INSTALL, Configuration: Release Win32
------
89>Project not selected to build for this solution configuration
========== Build: 60 succeeded, 24 failed, 178 up-to-date, 5 skipped
==========


Can you help me resolve these errors?

Best regards,
-Asif
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-users/attachments/20130523/e4bef53a/attachment.html>


More information about the cfe-users mailing list