Contribute to development in case I find a bug or possible enhancement
So far I have gone through the following steps:
Forked VTK to own GitLab account
Did a git clone own_account_url on local machine
Downloaded and installed CMake
Downloaded and installed Mingw-w64 from sourceforge
added Mingw-w64 directory to PATH
Created a \bin folder inside local clone of VTK repo
Ran CMake with .\vtk as source folder and .\vtk\bin as binary folder, using Code Blocks Mingw generator
This seemed to work, generating a VTK.cbp file which I was able to open using CodeBlocks. I then built the project by hitting Ctrl+F9. After building for 40 minutes I got an error:
C:\Users\aboufira\AppData\Local\Temp\ccrGE4Ag.s: Fatal error: can't write 40 bytes to section .text of CMakeFiles\CommonCore.dir\vtkDataArray.cxx.obj: 'File too big'
C:/PROGRA~2/MINGW-~1/I686-8~1.0-P/mingw32/bin/../lib/gcc/i686-w64-mingw32/8.1.0/../../../../i686-w64-mingw32/bin/as.exe: CMakeFiles\CommonCore.dir\vtkDataArray.cxx.obj: too many sections (42814)
C:\Users\aboufira\AppData\Local\Temp\ccrGE4Ag.s: Fatal error: can't close CMakeFiles\CommonCore.dir\vtkDataArray.cxx.obj: File too big
mingw32-make.exe[2]: *** [Common\Core\CMakeFiles\CommonCore.dir\build.make:996: Common/Core/CMakeFiles/CommonCore.dir/vtkDataArray.cxx.obj] Error 1
mingw32-make.exe[1]: *** [CMakeFiles\Makefile2:8126: Common/Core/CMakeFiles/CommonCore.dir/all] Error 2
mingw32-make.exe: *** [D:/github_projects/vtk/bin/Makefile:157: all] Error 2
Does anyone know why this occurs and how I can fix it? Thanks.
You will notice that Mingw is not listed as a supported compiler.
On windows we recommend visual studio + ninja. But pure visual studio is also supported.
They are not tested, so we assume they don’t work, but maybe they do.
You will be on your own though, which I will not recommend as it looks like this is your first time compiling VTK.
As for the .cbp file, CMake doesn’t care that VTK is not supporting it officially.
If you are looking to work in a Unix-like environment, why not using Linux directly ?
I see. No I’m not looking to work in a Unix-like environment as I use Windows. I was able to build the project again using CMake and now have a working VS2019 solution. A couple of follow up questions:
I do notice that the repository already contains an “Examples” directory, but that the examples in here do not correspond with the examples shown in https://lorensen.github.io/VTKExamples/site/Cxx/