regression: build failure using cmake Xcode generator
Although the Xcode generator is slow, it has one great use case: which is to generate an Xcode project so that someone digging through VTK code can use the features of an IDE, like clicking a function name while reading code to jump to that function definition.
It used to be possible.
But now with a fresh checkout of today's git master (6b5b75f0), using a fresh folder:
mkdir VTK-Xcode
cd VTK-Xcode
cmake -G Xcode ../VTK
then after a (long) while:
CMake Error in Rendering/OpenGL2/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Error in ThirdParty/cgns/vtkcgns/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Error in ThirdParty/expat/vtkexpat/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Error in ThirdParty/libharu/vtklibharu/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Error in ThirdParty/ogg/vtkogg/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Error in ThirdParty/libxml2/vtklibxml2/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Error in ThirdParty/pugixml/vtkpugixml/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Error in ThirdParty/tiff/vtktiff/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Error in Utilities/MetaIO/vtkmetaio/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Error in Utilities/KWSys/vtksys/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Error in ThirdParty/zlib/vtkzlib/CMakeLists.txt:
The custom command generating
/Users/sean/external/VTK-Xcode/Rendering/OpenGL2/vtkTextureObjectVS.h
is attached to multiple targets:
RenderingOpenGL2
vtkRenderingOpenGL2-hierarchy
but none of these is a common dependency of the other(s). This is not
allowed by the Xcode "new build system".
CMake Generate step failed. Build files cannot be regenerated correctly.
This in on macOS 12, Xcode 14.2 (newest possible on macOS 12), and cmake 3.26.4.