I had a teeny pet project using GNU assembly that was going to target two platforms.

Instead of keeping my handwritten worst-practices Makefile I decided to try GNU Autotools for the educated reasons of:

  • Text scrolling by looks pretty
  • Vague memories of ./configure make make install tarballs

I got hit with mysterious macro errors, recompile with -fPIE errors (didn’t need this before?), autotools trying to run gcc on a .o file w/ the same options as an .s file, “no rule for all:”, and other things a noob would run into. (I don’t need a bugfix, since my handspun Makefile is “working on my machine” with uname -m.) So there’s a bit of a learning curve here, inhibited by old documentation and more quietly, genAI being shittier than normal in this department

With this I ask:

Do people still use Autotools for non-legacy stuff? If not, what do people choose for a new project’s build system and why?

edit: trimmed an aside

  • callcc@lemmy.world
    link
    fedilink
    arrow-up
    2
    ·
    2 days ago

    Are you building a C/C++ project that should run on BSD, Gnu/Linux and other platforms? Then maybe use autotools. All distro tooling will easily be able to handle it.

    Are you just building some small project that will never make it into a distro, maybe just use something simpler. Or even just a plain makefile.

  • algernon@lemmy.ml
    link
    fedilink
    arrow-up
    6
    ·
    edit-2
    2 days ago

    Meson and CMake are the two major players I’ve seen along autotools. Are they better? In some respects, yes (especially Meson, imo), in others… not really. For a pet project that only targets two platforms, I’d just stick to handwritten worst-practices Makefile. You will likely have less trouble with that than any of the others, simply because you know it already.

    • fool@programming.devOP
      link
      fedilink
      arrow-up
      2
      ·
      2 days ago

      Yeah I was considering using one of these two, out of curiosity.

      I’ve heard complaints about CMake… on pre-2015 forums, so I don’t know where it’s at now.

      I’ve done very little from the developer side of Meson but I do recall having tried a sound theme that, inexplicably, had a Meson-based installer. (It was just .ogg files iirc.) That’s probably a good sign if someone picked it over an install.sh

      Though you’re right, there’s probably little advantage in me not using a Makefile here, except again, curiosity

  • Magister@lemmy.world
    link
    fedilink
    arrow-up
    5
    arrow-down
    1
    ·
    2 days ago

    autoconf and stuff like this? Not anymore. Since ~5 years here it’s cmake everywhere, Conan, ninja.

  • Eugenia@lemmy.ml
    link
    fedilink
    English
    arrow-up
    1
    ·
    2 days ago

    It doesn’t matter if we “people use it in new projects”, but rather, we often have to compile stuff that use them. So they need to be around, regardless of how bad they are. Just last week my husband had to compile two emulators that used autotools.