I am trying to add an external project to ParaView Superbuild and I am having some difficulty due to the project layout. I have created a project file projects/unix/<name>.cmake and added the project to versions.cmake.
The project has a makefile that is located within a “src” subdirectory of the project, i.e. it gets extracted to superbuild/<name>/src/src/Makefile. The project does not support out of source builds.
How can I add a project to paraview superbuild using the superbuild_add_project command so that it will work with this my project layout? Is there a way to set the working/build directory to superbuild/<name>/src/src? Or is there a way to do cd src before running make in the BUILD_COMMAND?
I had tried adding BUILD_IN_SOURCE 1 but the problem I had was that the make command is run in superbuild/<name>/src and I need it to run in a src subdirectory, i.e. superbuild/<name>/src/src.
Can I use BUILD_IN_SOURCE 1 then somehow move to a subdirectory before running the build command?
The superbuild is basically a layer on top of ExternalProject which does some enable/disable toggling and add support for PROCESS_ENVIRONMENT, so anything mentioned in those docs are supported in the superbuild as well. The superbuild currently carries 3.9’s ExternalProject module, but uses the one with your CMake if it is at least 3.9.
I tried adding SOURCE_SUBDIR src to my superbuild_add_project command, but my build command seems to run in the same directory as before. Perhaps the SOURCE_SUBDIR option only works with CMake projects and not Makefile projects?