I know little about gradle and have only just started exploring it, so this is just a question out of curiosity.

It’s supposedly a language agnostic dependency manager and builder, yet it seems to have only found its niche in Java. C/C++ projects could definitely do with dependency resolution…

  • e8d79@discuss.tchncs.de
    link
    fedilink
    arrow-up
    37
    ·
    edit-2
    21 hours ago

    Here are a couple of reasons:

    • C and C++ projects often predate Gradle by decades they will not change their build system without a compelling reason.
    • Gradle is written in Java and requires a Java Runtime.
    • At least for C++, CMake has pretty much become the standard build tool.
    • Dependency resolution on Linux was ‘solved’ by relying on the distribution. Today, there also exist package managers for C and C++ like vcpkg or conan and they also integrate with CMake.
    • 0x0
      link
      fedilink
      arrow-up
      13
      ·
      21 hours ago

      Cmake tends to be the upgrade path for sure, gradle is… hideous, i have having to use it for android.

    • onlinepersonaOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      20 hours ago

      Are vcpkg and conan widespread in your experience? Mine has still been majorly “works on my machine with unnamed debian version and unrestricted library version”, which still breaks like 90% of the time.

      Anti Commercial-AI license

      • paperplane@lemmy.world
        link
        fedilink
        arrow-up
        4
        ·
        20 hours ago

        I know a bunch of larger C++ apps that use vcpkg for cross-platform (Windows/macOS/Linux) builds of their dependencies and it seems to work pretty well

      • e8d79@discuss.tchncs.de
        link
        fedilink
        arrow-up
        3
        ·
        20 hours ago

        I worked on a couple commercial C++ applications that used vcpkg. It’s not as convenient as nuget, cargo or npm but it think it is a massive improvement over manually hunting for dependencies.