Live data from Hacker News

Show HN: Xmake, a modern C/C++ build utility

github.com

51–60 of 190 posts

Re: Show HN: Xmake, a modern C/C++ build utility

#51

Earlier quoted context omitted.

In my experience the primary reason people migrate is that it is significantly simpler for ordinary developers to maintain and configure builds in Meson. They both target ninja but the learning curve for CMake is definitely steeper.

Cmake has tooling and is supported by IDEs. Does Meson have anything comparable?

A better question is does it need to have tooling or IDE support to be worked with?

It's good to have tooling and IDEs for CMake because CMake is complicated and hand-editing the files is very tedious. But if Meson eliminates the tedium of CMake by providing you with different abstractions then you don't actually need the IDEs or tooling.

Re: Show HN: Xmake, a modern C/C++ build utility

#53
post #38

mmh. cflags and cxxflags are command line options ? i would expect them to be defined as part of build file.

Not even that. Compiler flags are compiler/platform/library options, naturally, as build options need to be propagated from dependencies.

The people behind cmake already learned that lesson with their modern cmake approach, but it seems the xmake people didn't do a proper review of the state of the art.

Re: Show HN: Xmake, a modern C/C++ build utility

#54

Earlier quoted context omitted.

Cmake has tooling and is supported by IDEs. Does Meson have anything comparable?

A better question is does it need to have tooling or IDE support to be worked with? It's good to have tooling and IDEs for CMake because CMake is complicated and hand-editing the files is very tedious. But if Meson eliminates the tedium of CMake by providing you with different abstractions then you don't actually need the IDEs or tooling.

> A better question is does it need to have tooling or IDE support to be worked with?

No, that's the wrong question and one that's only purpose is to deflect attention from its shortcomings.

All build tools need tooling because if they are adequately integrated into development workflows they are transparent and easy to use. Cmake meets that requirement, and until other alternative build systems do then they will always be far more complicated.

Re: Show HN: Xmake, a modern C/C++ build utility

#55

Earlier quoted context omitted.

Cmake has tooling and is supported by IDEs. Does Meson have anything comparable?

A better question is does it need to have tooling or IDE support to be worked with? It's good to have tooling and IDEs for CMake because CMake is complicated and hand-editing the files is very tedious. But if Meson eliminates the tedium of CMake by providing you with different abstractions then you don't actually need the IDEs or tooling.

CMake is only complicated if you need to make use of its complicated features, which many build systems simply omit. Meson looks nice though.

Re: Show HN: Xmake, a modern C/C++ build utility

#56
post #12

cmake is NOT a build utility. It is dependency tracking and configuration utility

"CMake is an open-source, cross-platform family of tools designed to build, test and package software. CMake is used to control the software compilation process using simple platform and compiler independent configuration files, and generate native makefiles and workspaces that can be used in the compiler environment of your choice." They would disagree with you.

Cmake is a makefile generator. The output of cmake is a series of makefiles. That's it. If you need to build a project and you don't have make, nmake, jmake or whatevermake in your system them cmake does nothing to get your project built.

Re: Show HN: Xmake, a modern C/C++ build utility

#57
post #46

Earlier quoted context omitted.

Now we just need a better DSL that can generate Cmake files.

And CMake itself started as a simple DSL for generating Makefiles. We've gone full circle

CMake is still a DSL for generating makefiles.

Re: Show HN: Xmake, a modern C/C++ build utility

#58

For better or worse though, CMake has won! Many IDE's including Visual Studio can directly work with CMake files. In addition, even Google which is famous for doing things their own way, has now added official, first-class CMake support to their open source C++ library Abseil https://abseil.io/blog/20190402-cmake-support If you are writing an open source C++ library, even if you support some other C++ build system, c…

Cmake won against the incumbent, which was autotools. Still it's still far from being an enjoyable tool, whose experience is made even worse by its god-awful docs.

I find the docs to be fine...

Re: Show HN: Xmake, a modern C/C++ build utility

#60
post #14

Meson[0] has been gaining in popularity and has migration tools for cmake projects. Large projects such as systemd and gnome[1] have migrated or have been migrating for years [0] https://mesonbuild.com/ [1] https://wiki.gnome.org/Initiatives/GnomeGoals/MesonPorting

Why migrate from CMake to meson?

CMake feels a lot like C++89: Lots of things you can do, but there are problems:

* No standardization or opinionated design, so you can't share your work easily.

* No sane defaults, so your build system is always fragile, difficult to maintain, and done wrong.

* No best practices, so people keep making the same mistakes over and over.

* Misguided attempt to remain compatible with the steaming pile of legacy they've accumulated over the years.

* Bad documentation, so there's no way to learn how to do things better.

* Steep learning curve with limited payoff, so most people don't bother.

Meson does some of these things better. It's still not pretty, but it's nicer to use than CMake.

Post reply on HN