[LLVMdev] build warnings

James Molloy james.molloy at arm.com
Mon Oct 24 01:07:43 PDT 2011


That's interesting, what version of GCC are you using?

[ 94%] [ 94%] Building CXX object
tools/clang/tools/libclang/CMakeFiles/libclang.dir/IndexingContext.cpp.o
Building CXX object
tools/clang/lib/StaticAnalyzer/Core/CMakeFiles/clangStaticAnalyzerCore.dir/M
emRegion.cpp.o
Linking CXX shared library ../../../../lib/liblibclang.so

-----Original Message-----
From: Csaba Raduly [mailto:rcsaba at gmail.com] 
Sent: 24 October 2011 08:52
To: James Molloy
Cc: Paul Berube; llvmdev at cs.uiuc.edu
Subject: Re: [LLVMdev] build warnings

On Sun, Oct 23, 2011 at 10:34 PM, James Molloy  wrote:
> Hi,
>
> I haven't seen those errors. Clang and LLVM both build with no warnings on
the 3 versions of GCC I test with. MSVC reports loads of warnings however.
>

$ make happiness
...
Updated to revision 142790.
...
make[4]: Entering directory
`/home/ecsardu/LLVM/build-tcclab1/tools/clang/tools/libclang'
llvm[4]: Compiling CIndex.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling CIndexCXX.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling CIndexCodeCompletion.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling CIndexDiagnostic.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling CIndexHigh.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling CIndexInclusionStack.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling CIndexUSRs.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling CIndexer.cpp for Release+Asserts build (PIC)
/home/ecsardu/LLVM/llvm/tools/clang/tools/libclang/CIndexUSRs.cpp: In
function 'bool clang::cxcursor::getDeclCursorUSR(const clang::Decl*,
llvm::SmallVectorImpl<char>&)':
/home/ecsardu/LLVM/llvm/tools/clang/tools/libclang/CIndexUSRs.cpp:820:22:
warning: cast from type 'const clang::Decl*' to type 'clang::Decl*'
casts away qualifiers
llvm[4]: Compiling CXCursor.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling CXString.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling CXType.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling IndexBody.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling IndexDecl.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling IndexTypeSourceInfo.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling Indexing.cpp for Release+Asserts build (PIC)
llvm[4]: Compiling IndexingContext.cpp for Release+Asserts build (PIC)
/home/ecsardu/LLVM/llvm/tools/clang/tools/libclang/IndexingContext.cpp:
In member function 'void
clang::cxindex::IndexingContext::handleReference(const
clang::NamedDecl*, clang::SourceLocation, const clang::NamedDecl*,
const clang::DeclContext*, const clang::Expr*, CXIdxEntityRefKind)':
/home/ecsardu/LLVM/llvm/tools/clang/tools/libclang/IndexingContext.cpp:401:6
8:
warning: cast from type 'const clang::Decl*' to type 'clang::Decl*'
casts away qualifiers
llvm[4]: Linking Release+Asserts Shared Library libclang.so

This is with gcc version 4.5.0 20100604 [gcc-4_5-branch revision
160292] (SUSE Linux) on openSUSE 11.3 "Teal"
Also gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5) on Ubuntu 10.04 LTS


-- 
GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++
The Tao of math: The numbers you can count are not the real numbers.
Life is complex, with real and imaginary parts.
"Ok, it boots. Which means it must be bug-free and perfect. " -- Linus
Torvalds
"People disagree with me. I just ignore them." -- Linus Torvalds








More information about the llvm-dev mailing list