← Back to context

Comment by cogman10

6 months ago

I'm not sure what you mean by this. Looking at a sample app [1] for the NDK, the tooling appears to be gradle and Cmake. Cmake isn't the newest of tools, but it's also not that dated.

[1] https://github.com/android/ndk-samples/tree/main/endless-tun...

Both Gradle and CMake have a strong late 1990's smell to them. While CMake is sort of a necessary evil in the C/C++ world, there's no excuse for dragging Gradle into the NDK, combining both build tools leads to a complexity explosion that rarely works and tends to break after either the NDK or SDK is updated, or somebody merely looks the wrong way at the build files.

  • CMake is the defacto tool adopted by the industry, regardless how many love to hate it.

    You can use BSD Make instead of Gradle, isn't UNIX great?

    • > You can use BSD Make instead of Gradle, isn't UNIX great?

      So the NDK officially supports creating an APK just with a Makefile? That would be news to me (and great news at that).

      It is possible to cobble together a build process that directly calls various Android SDK command line tools to build an APK directly from a C/C++ build tool without involving Gradle, but as far as I know, most of those invoked cmdline tools are deprecated and building APKs outside Gradle is not 'supported' by the Android SDK/NDK (e.g. it may stop working at any time).

      1 reply →