Add meson as an alternative to autotools with corresponding CI#300
Add meson as an alternative to autotools with corresponding CI#300cgwalters merged 3 commits intocomposefs:mainfrom
Conversation
There was a problem hiding this comment.
Nice! Only superficially skimming this (and without knowing meson really...my path went autotools+c -> go+rust basically) it looks great! I'd be in favor of killing the autotools build actually.
The thing I'd like to cross-check at least manually (even in CI perhaps) is that the autotools and meson builds result in "identical" outputs...I am not aware of any reason they shouldn't actually be bit-for-bit compatible.
libcomposefs/meson.build
Outdated
| source_files, | ||
| c_args : composefs_hash_cflags + hidden_visibility_cflags, | ||
| dependencies : libcrypto_dep, | ||
| version : meson.project_version(), # FIXME: or libversion? |
There was a problem hiding this comment.
There was a problem hiding this comment.
I saw that you have different versions for the project itself and the libcomposefs.so links. The pkgconfig file also includes a version field. Which version should go where? :)
There was a problem hiding this comment.
I've changed it to match what autotools produces (project version 1.0.4 in composefs.pc, libversion 1.2.0 for the symlinks).
tools/meson.build
Outdated
|
|
||
| executable('composefs-info', | ||
| ['composefs-info.c', '../libcomposefs/hash.c'], | ||
| c_args : ['-DUSE_OBSTACK=0', '-DTESTING=0', '-DUSE_DIFF_HASH=0'], |
There was a problem hiding this comment.
We should be able to reference a variable for this to dedup with the top of https://github.com/containers/composefs/pull/300/files#diff-4f12b63e85afe8c8819073d64da906f24d8fe7ad05e0cc1db6fab193413e4410 right?
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
This prepares for testing with meson in CI. Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
|
I've noticed that autotools builds both a shared and a static library, so I've updated this PR to do that as well. |
|
Tried this out, it's so much faster than autotools! Nice! Doing a Which looks totally fine to me. Digging into the differences via
But that's all fine. Thanks so much for doing this! I'm still in favor of dropping autotools; will file a tracker issue where we can debate that. |
This adds support for meson as an alternative build system to autotools.