occt: master 1bd04b5a

Author Committer Branch Timestamp Parent
abv abv master 2019-10-11 19:04:02 master 6466cc9e
Affected Issues  0031060: Configuration - Support building with CLang compiler under VS 2019
Changeset 0031060: Configuration - Support building with CLang compiler under VS 2019

Build tools are updated to support building with Visual Studion 2019 toolset ClangCL (LLVM clang-cl):
- In CMake builds, use of unsupported option "-std=c++0x" is avoided
- Tool genconf recognizes availability of ClangCL toolset and proposes it in the list
- Tool genproj recognizes new compiler specification VCVER=vclang and generates VS 2019 projects for it

Note that vclang configuration puts binaries to folder "vc14" as it is compatible with vc14 CRT.

Code is updated to build with Clang for Windows without errors and warnings:
- In BVH classes, pure virtual destructors are replaced by empty ones, to avoid bogus compiler warning
- In .lex files, pragmas are added to disable warnings in parser code
- In OSD, signature of function _osd_wnt_set_error() is corrected to avoid warning on incorrect use of va_args (undefined behavior)
- In OSD_Host, OSD_Parallel_TBB, warnings on usage of deprecated function are disabled
- In Quantity_ColorRGBA and ViewerTest_CmdParser, incorrect use of predefined macro __FUNCTION__ assuming it was a string literal is avoided
- In Standard_Macro.hxx, code is reordered to handle Clang for Windows appropriately
- In AdvApp2Var_SysBase.hxx, inclusion of obsolete (MSVC-specific) header file is replaced by Standard_TypeDef.hxx
- In Standard_ErrorHandler.hxx, empty statements added to avoid warning on unused class fields
- In IVtkDraw and ViewerTest, interface is corrected to use actual type avoiding unnecessary type casts

Off-topic: corrections of some errors (uninitialized class fields) reported by VS Code Analysis in TKernel
mod - adm/cmake/occt_defs_flags.cmake Diff File
mod - adm/genconf.tcl Diff File
mod - adm/genconfdeps.tcl Diff File
mod - adm/genproj.tcl Diff File
mod - adm/templates/env.bat Diff File
mod - dox/overview/overview.md Diff File
mod - src/AdvApp2Var/AdvApp2Var_SysBase.hxx Diff File
mod - src/BinLDrivers/BinLDrivers_DocumentStorageDriver.cxx Diff File
mod - src/BVH/BVH_Object.hxx Diff File
mod - src/BVH/BVH_QueueBuilder.hxx Diff File
mod - src/BVH/BVH_Set.hxx Diff File
mod - src/ExprIntrp/ExprIntrp.lex Diff File
mod - src/ExprIntrp/lex.ExprIntrp.c Diff File
mod - src/Image/Image_Texture.cxx Diff File
mod - src/IVtkDraw/IVtkDraw.cxx Diff File
mod - src/IVtkDraw/IVtkDraw.hxx Diff File
mod - src/IVtkDraw/IVtkDraw_Interactor.cxx Diff File
mod - src/NCollection/NCollection_AccAllocator.hxx Diff File
mod - src/NCollection/NCollection_SparseArrayBase.hxx Diff File
mod - src/OSD/OSD_Directory.cxx Diff File
mod - src/OSD/OSD_DirectoryIterator.cxx Diff File
mod - src/OSD/OSD_Disk.cxx Diff File
mod - src/OSD/OSD_File.cxx Diff File
mod - src/OSD/OSD_FileIterator.cxx Diff File
mod - src/OSD/OSD_FileNode.cxx Diff File
mod - src/OSD/OSD_Host.cxx Diff File
mod - src/OSD/OSD_Parallel_TBB.cxx Diff File
mod - src/OSD/OSD_Path.cxx Diff File
mod - src/OSD/OSD_Process.cxx Diff File
mod - src/OSD/OSD_Timer.cxx Diff File
mod - src/QABugs/QABugs_11.cxx Diff File
mod - src/QABugs/QABugs_19.cxx Diff File
mod - src/Quantity/Quantity_ColorRGBA.cxx Diff File
mod - src/Standard/Standard_ErrorHandler.hxx Diff File
mod - src/Standard/Standard_Macro.hxx Diff File
mod - src/StepFile/lex.step.c Diff File
mod - src/StepFile/step.lex Diff File
mod - src/Storage/Storage_Schema.cxx Diff File
mod - src/ViewerTest/ViewerTest.hxx Diff File
mod - src/ViewerTest/ViewerTest_CmdParser.cxx Diff File
mod - src/ViewerTest/ViewerTest_ViewerCommands.cxx Diff File