Skip to content

Consider moving back to git submodules #2

@derselbst

Description

@derselbst

While I do comprehend the benefit and simplicity of using CMake to keep track of all dependencies, it does cause problems. For example, many build systems do not provide an installation of git. This causes the build to fail, see fluidsynth as an example:

[   59s] CMake Error at /usr/share/cmake/Modules/ExternalProject.cmake:2910 (message):
[   59s]   error: could not find git for clone of signalsmith-linear-populate
[   59s] Call Stack (most recent call first):
[   59s]   /usr/share/cmake/Modules/ExternalProject.cmake:4418 (_ep_add_download_command)
[   59s]   CMakeLists.txt:29 (ExternalProject_Add)
[   59s] 
[   59s] 
[   59s] -- Configuring incomplete, errors occurred!

Installing git as part of the build-requirements may not fix the issue, since some build systems impose network restrictions, e.g.:

[   70s] gmake[3]: Entering directory '/usr/src/packages/BUILD/_deps/signalsmith-linear-subbuild'
[   70s] [ 11%] Creating directories for 'signalsmith-linear-populate'
[   70s] [ 22%] Performing download step (git clone) for 'signalsmith-linear-populate'
[   70s] Cloning into 'signalsmith-linear-src'...
[   70s] fatal: unable to access 'https://github.com/Signalsmith-Audio/linear.git/': Could not resolve host: github.com
[   70s] Cloning into 'signalsmith-linear-src'...
[   70s] fatal: unable to access 'https://github.com/Signalsmith-Audio/linear.git/': Could not resolve host: github.com
[   70s] Cloning into 'signalsmith-linear-src'...
[   70s] fatal: unable to access 'https://github.com/Signalsmith-Audio/linear.git/': Could not resolve host: github.com
[   70s] -- Had to git clone more than once: 3 times.
[   70s] CMake Error at signalsmith-linear-subbuild/signalsmith-linear-populate-prefix/tmp/signalsmith-linear-populate-gitclone.cmake:39 (message):
[   70s]   Failed to clone repository:
[   70s]   'https://github.com/Signalsmith-Audio/linear.git'
[   70s] 
[   70s] 
[   70s] gmake[3]: *** [CMakeFiles/signalsmith-linear-populate.dir/build.make:102: signalsmith-linear-populate-prefix/src/signalsmith-linear-populate-stamp/signalsmith-linear-populate-download] Error 1
[   70s] gmake[3]: Leaving directory '/usr/src/packages/BUILD/_deps/signalsmith-linear-subbuild'
[   70s] gmake[2]: *** [CMakeFiles/Makefile2:83: CMakeFiles/signalsmith-linear-populate.dir/all] Error 2
[   70s] gmake[2]: Leaving directory '/usr/src/packages/BUILD/_deps/signalsmith-linear-subbuild'
[   70s] gmake[1]: *** [Makefile:91: all] Error 2
[   70s] gmake[1]: Leaving directory '/usr/src/packages/BUILD/_deps/signalsmith-linear-subbuild'
[   70s] 
[   70s] CMake Error at /usr/share/cmake-3.28/Modules/FetchContent.cmake:1679 (message):
[   70s]   Build step for signalsmith-linear failed: 2
[   70s] Call Stack (most recent call first):
[   70s]   /usr/share/cmake-3.28/Modules/FetchContent.cmake:1819:EVAL:2 (__FetchContent_directPopulate)
[   70s]   /usr/share/cmake-3.28/Modules/FetchContent.cmake:1819 (cmake_language)
[   70s]   /usr/share/cmake-3.28/Modules/FetchContent.cmake:2033 (FetchContent_Populate)
[   70s]   signalsmith-audio-basics/CMakeLists.txt:16 (FetchContent_MakeAvailable)

Would you consider migrating back to git-submodules? This would allow for a recursive checkout, before the entering the limitation of the build environment.

More logs can be found here:

https://build.opensuse.org/package/show/home:derselbst:anmp/fluidsynth
https://dev.azure.com/tommbrt/tommbrt/_build?definitionId=12

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions