Live data from Hacker News

Xmake: A cross-platform build utility based on Lua

xmake.io

21–30 of 41 posts

Re: Xmake: A cross-platform build utility based on Lua

#22
post #18

I apologise for this: What's wrong with premake which is also Lua based? when I meant: What advantage does this have over premake which is also Lua based?

What’s wrong with xmake which is also Lua based?

https://news.ycombinator.com/item?id=46511599 similar reasoning

Re: Xmake: A cross-platform build utility based on Lua

#23
post #22
post #18

Earlier quoted context omitted.

What’s wrong with xmake which is also Lua based?

https://news.ycombinator.com/item?id=46511599 similar reasoning

I honestly didn't mean it like that, but I can understand that it comes across that way.

A better wording would be "what advantage does this have over premake which is also Lua based".

Re: Xmake: A cross-platform build utility based on Lua

#24
A teammate evaluated this and the experience was night and day compared to cmake + vcpkg. However, there wasn’t a lot of motivation to cutover our existing large project over because of the unknown unknowns. I think projects like these looking to dethrone the status quo definitely need some case studies or examples of larger projects using it to increase confidence because I’d much rather use xmake over cmake if it can get the job done

Re: Xmake: A cross-platform build utility based on Lua

#25
post #17
post #9

Earlier quoted context omitted.

As far as I am aware, there no integrations available with Visual Studio, and not sure about C++20 modules and import std support.

It can generate a Visual Studio project, then use the xmake CLI to integrate and compile the project, and supports debugging and IntelliSense. https://xmake.io/guide/extensions/builtin-plugins.html#gener... C++ Modules examples: https://xmake.io/examples/cpp/cxx-modules.html https://github.com/xmake-io/xmake/tree/dev/tests/projects/c%...

Thanks for the information.

Re: Xmake: A cross-platform build utility based on Lua

#26
post #22

Earlier quoted context omitted.

https://news.ycombinator.com/item?id=46511599 similar reasoning

I honestly didn't mean it like that, but I can understand that it comes across that way. A better wording would be "what advantage does this have over premake which is also Lua based".

Tbh, why does it matter what it's written in? Does it do the job?

Re: Xmake: A cross-platform build utility based on Lua

#28
post #9
post #3

At my work we use MSBuild and vcpkg. What would a transition from that to XMake be like?

As far as I am aware, there no integrations available with Visual Studio, and not sure about C++20 modules and import std support.

A few weeks ago I decided to test C++ modules, but I had a hard time to figure out how to make them accepted by CMake. After a few days of struggle with `set(CMAKE_EXPERIMENTAL_CXX_IMPORT_STD "d0edc3af-4c50-42ea-a356-e2862fe7a444")` (it was so hard to find the right UUID that worked with my version) and errors on `import std;`, I decided to give XMake a chance.

It took just a couple of minutes to have a working example that fully supported C++ modules and `import std`:

    set_languages("c++23")

    add_rules("mode.debug", "mode.release")

    target("mytest")
        set_kind("static")
        add_files("src/*.cpp")
        add_files("src/*.cppm", {public = true})
        set_policy("build.c++.modules", true)

Re: Xmake: A cross-platform build utility based on Lua

#29

A teammate evaluated this and the experience was night and day compared to cmake + vcpkg. However, there wasn’t a lot of motivation to cutover our existing large project over because of the unknown unknowns. I think projects like these looking to dethrone the status quo definitely need some case studies or examples of larger projects using it to increase confidence because I’d much rather use xmake over cmake if it c…

I use it for personal projects and I find it substantially easier to mess around with compiling shaders to SPIRV, processing assets, etc... But some of my gripes are, although it _is_ lua, there is some magic fuckery going on. When you specify targets, things for that target need to be close to the definition, and it feels very odd in a lua language to not have `target("name", function (ctx) ... end)`.

Anyways, not going to die on that hill and I'll keep using it because it's simple and works well for my needs. One thing I do like is that I am not having to constantly keep a skeleton CMake project around to copy paste and setup.

Re: Xmake: A cross-platform build utility based on Lua

#30
post #26

Earlier quoted context omitted.

I honestly didn't mean it like that, but I can understand that it comes across that way. A better wording would be "what advantage does this have over premake which is also Lua based".

Tbh, why does it matter what it's written in? Does it do the job?

Lua is the syntax in the build configuration file, not how the tool is implemented internally. It’s part of the developer experience.
Post reply on HN