You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[ 19%] Building CXX object src/liboslexec/CMakeFiles/oslexec.dir/__/liboslcomp/oslcomp.cpp.o
cd ....../OpenShadingLanguage/build/src/liboslexec && ccache /usr/bin/c++ -DCUDA_TARGET_ARCH=\"sm_75\" -DOIIO_HIDE_FORMAT=1 -DOSL_CUDA_VERSION=\"\" -DOSL_EXPORTS -DOSL_FAST_MATH=1 -DOSL_INTERNAL=1 -DOSL_LLVM_FULL_VERSION=\"15.0.0git\" -DOSL_LLVM_VERSION=150 -DOSL_OPTIX_VERSION=\"\" -DUSE_PARTIO=1 -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -Doslexec_EXPORTS -Doslparse=OSL_v1_12_5_oslparse -Dosoparse=OSL_v1_12_5_osoparse -I....../OpenShadingLanguage/build/include -I....../OpenShadingLanguage/build/src/include -I....../OpenShadingLanguage/src/include -I....../OpenShadingLanguage/ext/dist/include -I....../OpenShadingLanguage/src/liboslexec -I....../OpenShadingLanguage/dist/include -I....../OpenShadingLanguage/src/liboslcomp -isystem /usr/local/include/opencv4 -isystem /usr/local/include/Imath -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -O3 -DNDEBUG -fPIC -Wall -Werror -Wno-error=strict-overflow -Wno-unused-local-typedefs -Wno-unused-result -Wno-error=misleading-indentation -fno-math-errno -std=c++14 -fno-rtti -MD -MT src/liboslexec/CMakeFiles/oslexec.dir/llvm_util.cpp.o -MF CMakeFiles/oslexec.dir/llvm_util.cpp.o.d -o CMakeFiles/oslexec.dir/llvm_util.cpp.o -c ....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp
cd ....../OpenShadingLanguage/build/src/liboslexec && ccache /usr/bin/c++ -DCUDA_TARGET_ARCH=\"sm_75\" -DOIIO_HIDE_FORMAT=1 -DOSL_CUDA_VERSION=\"\" -DOSL_EXPORTS -DOSL_FAST_MATH=1 -DOSL_INTERNAL=1 -DOSL_LLVM_FULL_VERSION=\"15.0.0git\" -DOSL_LLVM_VERSION=150 -DOSL_OPTIX_VERSION=\"\" -DUSE_PARTIO=1 -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -Doslexec_EXPORTS -Doslparse=OSL_v1_12_5_oslparse -Dosoparse=OSL_v1_12_5_osoparse -I....../OpenShadingLanguage/build/include -I....../OpenShadingLanguage/build/src/include -I....../OpenShadingLanguage/src/include -I....../OpenShadingLanguage/ext/dist/include -I....../OpenShadingLanguage/src/liboslexec -I....../OpenShadingLanguage/dist/include -I....../OpenShadingLanguage/src/liboslcomp -isystem /usr/local/include/opencv4 -isystem /usr/local/include/Imath -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -O3 -DNDEBUG -fPIC -Wall -Werror -Wno-error=strict-overflow -Wno-unused-local-typedefs -Wno-unused-result -Wno-error=misleading-indentation -fno-math-errno -std=c++14 -MD -MT src/liboslexec/CMakeFiles/oslexec.dir/__/liboslcomp/oslcomp.cpp.o -MF CMakeFiles/oslexec.dir/__/liboslcomp/oslcomp.cpp.o.d -o CMakeFiles/oslexec.dir/__/liboslcomp/oslcomp.cpp.o -c ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp
In file included from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:24:/usr/local/include/clang/Basic/TargetInfo.h: In member function ‘virtual bool clang::TargetInfo::shouldDLLImportComdatSymbols() const’:/usr/local/include/clang/Basic/TargetInfo.h:1192:69: error: ‘const class llvm::Triple’ has no member named ‘isPS4CPU’; did you mean ‘isPS4’? 1192 | getTriple().isWindowsItaniumEnvironment() || getTriple().isPS4CPU(); | ^~~~~~~~ | isPS4/usr/local/include/clang/Basic/TargetInfo.h: In member function ‘virtual bool clang::TargetInfo::hasPS4DLLImportExport() const’:/usr/local/include/clang/Basic/TargetInfo.h:1197:24: error: ‘const class llvm::Triple’ has no member named ‘isPS4CPU’; did you mean ‘isPS4’? 1197 | return getTriple().isPS4CPU() || | ^~~~~~~~ | isPS4In file included from /usr/local/include/clang/Basic/FileEntry.h:17, from /usr/local/include/clang/Basic/SourceManager.h:38, from /usr/local/include/clang/Frontend/CompilerInstance.h:14, from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:25:/usr/local/include/clang/Basic/DirectoryEntry.h: At global scope:/usr/local/include/clang/Basic/DirectoryEntry.h:131:19: error: expected ‘;’ at end of member declaration 131 | RefTy &getValue() LLVM_LVALUE_FUNCTION { | ^ | ;/usr/local/include/clang/Basic/DirectoryEntry.h:131:21: error: ‘LLVM_LVALUE_FUNCTION’ does not name a type; did you mean ‘LLVM_PRETTY_FUNCTION’? 131 | RefTy &getValue() LLVM_LVALUE_FUNCTION { | ^~~~~~~~~~~~~~~~~~~~ | LLVM_PRETTY_FUNCTION/usr/local/include/clang/Basic/DirectoryEntry.h:135:27: error: expected ‘;’ at end of member declaration 135 | RefTy const &getValue() const LLVM_LVALUE_FUNCTION { | ^~~~~ | ;/usr/local/include/clang/Basic/DirectoryEntry.h:135:33: error: ‘LLVM_LVALUE_FUNCTION’ does not name a type; did you mean ‘LLVM_PRETTY_FUNCTION’? 135 | RefTy const &getValue() const LLVM_LVALUE_FUNCTION { | ^~~~~~~~~~~~~~~~~~~~ | LLVM_PRETTY_FUNCTIONIn file included from /usr/local/include/clang/AST/NestedNameSpecifier.h:21, from /usr/local/include/clang/AST/Type.h:21, from /usr/local/include/clang/AST/DeclarationName.h:16, from /usr/local/include/clang/AST/DeclBase.h:18, from /usr/local/include/clang/Analysis/AnalysisDeclContext.h:20, from /usr/local/include/clang/Analysis/PathDiagnostic.h:17, from /usr/local/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h:17, from /usr/local/include/clang/Frontend/CompilerInvocation.h:22, from /usr/local/include/clang/Frontend/CompilerInstance.h:15, from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:25:/usr/local/include/llvm/ADT/FoldingSet.h:261:8: error: redeclared with 2 template parameters 261 | struct FoldingSetTrait : public DefaultFoldingSetTrait<T> {}; | ^~~~~~~~~~~~~~~In file included from /usr/local/include/clang/Basic/Diagnostic.h:19, from /usr/local/include/clang/Frontend/CompilerInstance.h:13, from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:25:/usr/local/include/clang/Basic/SourceLocation.h:27:30: note: previous declaration ‘template<class T> struct llvm::FoldingSetTrait’ used 1 template parameter 27 | template <typename T> struct FoldingSetTrait; | ^~~~~~~~~~~~~~~In file included from /usr/local/include/clang/AST/NestedNameSpecifier.h:21, from /usr/local/include/clang/AST/Type.h:21, from /usr/local/include/clang/AST/DeclarationName.h:16, from /usr/local/include/clang/AST/DeclBase.h:18, from /usr/local/include/clang/Analysis/AnalysisDeclContext.h:20, from /usr/local/include/clang/Analysis/PathDiagnostic.h:17, from /usr/local/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h:17, from /usr/local/include/clang/Frontend/CompilerInvocation.h:22, from /usr/local/include/clang/Frontend/CompilerInstance.h:15, from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:25:/usr/local/include/llvm/ADT/FoldingSet.h:833:75: error: wrong number of template arguments (2, should be 1) 833 | struct FoldingSetTrait<T, typename std::enable_if_t<std::is_enum<T>::value>> { | ^~In file included from /usr/local/include/clang/Basic/Diagnostic.h:19, from /usr/local/include/clang/Frontend/CompilerInstance.h:13, from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:25:/usr/local/include/clang/Basic/SourceLocation.h:27:30: note: provided for ‘template<class T> struct llvm::FoldingSetTrait’ 27 | template <typename T> struct FoldingSetTrait; | ^~~~~~~~~~~~~~~make[2]: *** [src/liboslcomp/CMakeFiles/oslcomp.dir/build.make:121: src/liboslcomp/CMakeFiles/oslcomp.dir/oslcomp.cpp.o] Error 1make[2]: Leaving directory '....../OpenShadingLanguage/build'make[1]: *** [CMakeFiles/Makefile2:387: src/liboslcomp/CMakeFiles/oslcomp.dir/all] Error 2make[1]: *** Waiting for unfinished jobs....In file included from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:24:/usr/local/include/clang/Basic/TargetInfo.h: In member function ‘virtual bool clang::TargetInfo::shouldDLLImportComdatSymbols() const’:/usr/local/include/clang/Basic/TargetInfo.h:1192:69: error: ‘const class llvm::Triple’ has no member named ‘isPS4CPU’; did you mean ‘isPS4’? 1192 | getTriple().isWindowsItaniumEnvironment() || getTriple().isPS4CPU(); | ^~~~~~~~ | isPS4/usr/local/include/clang/Basic/TargetInfo.h: In member function ‘virtual bool clang::TargetInfo::hasPS4DLLImportExport() const’:/usr/local/include/clang/Basic/TargetInfo.h:1197:24: error: ‘const class llvm::Triple’ has no member named ‘isPS4CPU’; did you mean ‘isPS4’? 1197 | return getTriple().isPS4CPU() || | ^~~~~~~~ | isPS4In file included from /usr/local/include/clang/Basic/FileEntry.h:17, from /usr/local/include/clang/Basic/SourceManager.h:38, from /usr/local/include/clang/Frontend/CompilerInstance.h:14, from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:25:/usr/local/include/clang/Basic/DirectoryEntry.h: At global scope:/usr/local/include/clang/Basic/DirectoryEntry.h:131:19: error: expected ‘;’ at end of member declaration 131 | RefTy &getValue() LLVM_LVALUE_FUNCTION { | ^ | ;/usr/local/include/clang/Basic/DirectoryEntry.h:131:21: error: ‘LLVM_LVALUE_FUNCTION’ does not name a type; did you mean ‘LLVM_PRETTY_FUNCTION’? 131 | RefTy &getValue() LLVM_LVALUE_FUNCTION { | ^~~~~~~~~~~~~~~~~~~~ | LLVM_PRETTY_FUNCTION/usr/local/include/clang/Basic/DirectoryEntry.h:135:27: error: expected ‘;’ at end of member declaration 135 | RefTy const &getValue() const LLVM_LVALUE_FUNCTION { | ^~~~~ | ;/usr/local/include/clang/Basic/DirectoryEntry.h:135:33: error: ‘LLVM_LVALUE_FUNCTION’ does not name a type; did you mean ‘LLVM_PRETTY_FUNCTION’? 135 | RefTy const &getValue() const LLVM_LVALUE_FUNCTION { | ^~~~~~~~~~~~~~~~~~~~ | LLVM_PRETTY_FUNCTIONIn file included from /usr/local/include/clang/AST/NestedNameSpecifier.h:21, from /usr/local/include/clang/AST/Type.h:21, from /usr/local/include/clang/AST/DeclarationName.h:16, from /usr/local/include/clang/AST/DeclBase.h:18, from /usr/local/include/clang/Analysis/AnalysisDeclContext.h:20, from /usr/local/include/clang/Analysis/PathDiagnostic.h:17, from /usr/local/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h:17, from /usr/local/include/clang/Frontend/CompilerInvocation.h:22, from /usr/local/include/clang/Frontend/CompilerInstance.h:15, from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:25:/usr/local/include/llvm/ADT/FoldingSet.h:261:8: error: redeclared with 2 template parameters 261 | struct FoldingSetTrait : public DefaultFoldingSetTrait<T> {}; | ^~~~~~~~~~~~~~~In file included from /usr/local/include/clang/Basic/Diagnostic.h:19, from /usr/local/include/clang/Frontend/CompilerInstance.h:13, from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:25:/usr/local/include/clang/Basic/SourceLocation.h:27:30: note: previous declaration ‘template<class T> struct llvm::FoldingSetTrait’ used 1 template parameter 27 | template <typename T> struct FoldingSetTrait; | ^~~~~~~~~~~~~~~In file included from /usr/local/include/clang/AST/NestedNameSpecifier.h:21, from /usr/local/include/clang/AST/Type.h:21, from /usr/local/include/clang/AST/DeclarationName.h:16, from /usr/local/include/clang/AST/DeclBase.h:18, from /usr/local/include/clang/Analysis/AnalysisDeclContext.h:20, from /usr/local/include/clang/Analysis/PathDiagnostic.h:17, from /usr/local/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h:17, from /usr/local/include/clang/Frontend/CompilerInvocation.h:22, from /usr/local/include/clang/Frontend/CompilerInstance.h:15, from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:25:/usr/local/include/llvm/ADT/FoldingSet.h:833:75: error: wrong number of template arguments (2, should be 1) 833 | struct FoldingSetTrait<T, typename std::enable_if_t<std::is_enum<T>::value>> { | ^~In file included from /usr/local/include/clang/Basic/Diagnostic.h:19, from /usr/local/include/clang/Frontend/CompilerInstance.h:13, from ....../OpenShadingLanguage/src/liboslcomp/oslcomp.cpp:25:/usr/local/include/clang/Basic/SourceLocation.h:27:30: note: provided for ‘template<class T> struct llvm::FoldingSetTrait’ 27 | template <typename T> struct FoldingSetTrait; | ^~~~~~~~~~~~~~~make[2]: *** [src/liboslexec/CMakeFiles/oslexec.dir/build.make:1016: src/liboslexec/CMakeFiles/oslexec.dir/__/liboslcomp/oslcomp.cpp.o] Error 1make[2]: *** Waiting for unfinished jobs........../OpenShadingLanguage/src/liboslexec/llvm_util.cpp: In member function ‘void OSL_v1_12_5::pvt::LLVM_Util::setup_optimization_passes(int, bool)’:....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:1771:23: error: ‘createLoopUnswitchPass’ is not a member of ‘llvm’; did you mean ‘createLowerSwitchPass’? 1771 | mpm.add(llvm::createLoopUnswitchPass(false)); | ^~~~~~~~~~~~~~~~~~~~~~ | createLowerSwitchPass....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:1888:23: error: ‘createLoopUnswitchPass’ is not a member of ‘llvm’; did you mean ‘createLowerSwitchPass’? 1888 | mpm.add(llvm::createLoopUnswitchPass(false)); | ^~~~~~~~~~~~~~~~~~~~~~ | createLowerSwitchPass....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp: In member function ‘llvm::Value* OSL_v1_12_5::pvt::LLVM_Util::call_function(llvm::Value*, OpenImageIO_v2_4_1::cspan<llvm::Value*>)’:....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:3473:78: error: ‘llvm::Type* llvm::Type::getPointerElementType() const’ is deprecated: Deprecated without replacement, see https://llvm.org/docs/OpaquePointers.html for context and migration instructions [-Werror=deprecated-declarations] 3473 | llvm::cast<llvm::FunctionType>(func->getType()->getPointerElementType()), func, | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~In file included from /usr/local/include/llvm/IR/DerivedTypes.h:23, from /usr/local/include/llvm/IR/Constants.h:31, from ....../OpenShadingLanguage/src/liboslexec/llvm_passes.h:10, from ....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:20:/usr/local/include/llvm/IR/Type.h:375:9: note: declared here 375 | Type *getPointerElementType() const { | ^~~~~~~~~~~~~~~~~~~~~....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp: In member function ‘llvm::Value* OSL_v1_12_5::pvt::LLVM_Util::op_load(llvm::Value*)’:....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:3604:57: error: ‘llvm::Type* llvm::Type::getPointerElementType() const’ is deprecated: Deprecated without replacement, see https://llvm.org/docs/OpaquePointers.html for context and migration instructions [-Werror=deprecated-declarations] 3604 | return op_load(ptr->getType()->getPointerElementType(), ptr); | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~In file included from /usr/local/include/llvm/IR/DerivedTypes.h:23, from /usr/local/include/llvm/IR/Constants.h:31, from ....../OpenShadingLanguage/src/liboslexec/llvm_passes.h:10, from ....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:20:/usr/local/include/llvm/IR/Type.h:375:9: note: declared here 375 | Type *getPointerElementType() const { | ^~~~~~~~~~~~~~~~~~~~~....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp: In member function ‘llvm::Value* OSL_v1_12_5::pvt::LLVM_Util::GEP(llvm::Value*, llvm::Value*)’:....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:5087:70: error: ‘llvm::Type* llvm::Type::getPointerElementType() const’ is deprecated: Deprecated without replacement, see https://llvm.org/docs/OpaquePointers.html for context and migration instructions [-Werror=deprecated-declarations] 5087 | return GEP(ptr->getType()->getScalarType()->getPointerElementType(), ptr, | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~In file included from /usr/local/include/llvm/IR/DerivedTypes.h:23, from /usr/local/include/llvm/IR/Constants.h:31, from ....../OpenShadingLanguage/src/liboslexec/llvm_passes.h:10, from ....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:20:/usr/local/include/llvm/IR/Type.h:375:9: note: declared here 375 | Type *getPointerElementType() const { | ^~~~~~~~~~~~~~~~~~~~~....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp: In member function ‘llvm::Value* OSL_v1_12_5::pvt::LLVM_Util::GEP(llvm::Value*, int)’:....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:5104:70: error: ‘llvm::Type* llvm::Type::getPointerElementType() const’ is deprecated: Deprecated without replacement, see https://llvm.org/docs/OpaquePointers.html for context and migration instructions [-Werror=deprecated-declarations] 5104 | return GEP(ptr->getType()->getScalarType()->getPointerElementType(), ptr, | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~In file included from /usr/local/include/llvm/IR/DerivedTypes.h:23, from /usr/local/include/llvm/IR/Constants.h:31, from ....../OpenShadingLanguage/src/liboslexec/llvm_passes.h:10, from ....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:20:/usr/local/include/llvm/IR/Type.h:375:9: note: declared here 375 | Type *getPointerElementType() const { | ^~~~~~~~~~~~~~~~~~~~~....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp: In member function ‘llvm::Value* OSL_v1_12_5::pvt::LLVM_Util::GEP(llvm::Value*, int, int)’:....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:5121:70: error: ‘llvm::Type* llvm::Type::getPointerElementType() const’ is deprecated: Deprecated without replacement, see https://llvm.org/docs/OpaquePointers.html for context and migration instructions [-Werror=deprecated-declarations] 5121 | return GEP(ptr->getType()->getScalarType()->getPointerElementType(), ptr, | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~In file included from /usr/local/include/llvm/IR/DerivedTypes.h:23, from /usr/local/include/llvm/IR/Constants.h:31, from ....../OpenShadingLanguage/src/liboslexec/llvm_passes.h:10, from ....../OpenShadingLanguage/src/liboslexec/llvm_util.cpp:20:/usr/local/include/llvm/IR/Type.h:375:9: note: declared here 375 | Type *getPointerElementType() const { | ^~~~~~~~~~~~~~~~~~~~~cc1plus: all warnings being treated as errorsmake[2]: *** [src/liboslexec/CMakeFiles/oslexec.dir/build.make:960: src/liboslexec/CMakeFiles/oslexec.dir/llvm_util.cpp.o] Error 1make[2]: Leaving directory '....../OpenShadingLanguage/build'make[1]: *** [CMakeFiles/Makefile2:466: src/liboslexec/CMakeFiles/oslexec.dir/all] Error 2make[1]: Leaving directory '....../OpenShadingLanguage/build'make: *** [Makefile:159: all] Error 2
➜ build git:(main)
➜ build git:(main) gcc --versiongcc (Ubuntu 11.2.0-19ubuntu1) 11.2.0Copyright (C) 2021 Free Software Foundation, Inc.This is free software; see the source for copying conditions. There is NOwarranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
LLVM version:
➜ build git:(main) clang --versionclang version 14.0.3Target: x86_64-unknown-linux-gnuThread model: posixInstalledDir: /usr/local/bin
➜ build git:(main) apt show llvmPackage: llvmVersion: 1:14.0-55~exp2.......
OIIO version: 2.3.16 (successfully and manually installed)
The text was updated successfully, but these errors were encountered:
Those errors are all inside the LLVM headers, not in the OSL source code.
I was going to hypothesize that maybe you had either a very old llvm, or were working from their main branch and something had changed. You say you are using llvm 14, which we have tested against, so I'm not sure how that could go wrong.
Is it possible that you somehow have two different llvm/clang versions installed, and it's getting a mix so the headers are seeing an inconsistent set of declarations?
Failed to build
Problem
Steps to Reproduce
Just
make
afterconfigure
.Versions
The text was updated successfully, but these errors were encountered: