Conversation
|
@keszybz, could you have a look at this, please? |
|
I really like this switch. But please, if we do the switch, remove the old configure script and Makefiles, maintaining two build systems is a nightmare. |
My initial plan was to make a release that still supports both build systems, but contains a deprecation warning, and remove autotools support right after the release. This would allow downstreams ample time to prepare for migration. Do you think this approach is overcautious and we should rather do the switch right away? |
I don't really see a need to prepare migration, in the end all distributions should meanwhile have packages using meson, so it's just replacing configure & make with the corresponding meson files. |
|
For what it's worth, as a Fedora maintainer I'm fine with just providing meson and changing the build system for a release. It's a big change that I think will pay off in the medium/long term. |
|
Well, if nobody sees any benefits in keeping autotools support for the next release, I'm fine with dropping it before the release. |
|
I'm trying to build our pam packages currently with meson and this PR. We build two packages: a very small one and a full features one. I see the following error: I have to explicit disable logind. But that is defined as "auto", so shouldn't meson skip libsystemd dependency if it does not find it? Similar for pam_userdb: It's irritating that you need to look at the meson.build script to find out which option you need to disable if you don't want a dependency. |
keszybz
left a comment
There was a problem hiding this comment.
This is a lot of lines to review ;) I gave it a quick scan, and it looks all very nice. There probably are some minor things that'll need to be adjusted, but I think it's best to just merge this and use it.
I made some small suggestions. The only bigger issue I wonder about is whether it makes sense to symlink a shared meson.build file into multiple subdirectories. IIUC, this was done to allow the outputs to be produced in those subdirectories. If that is not necessary, I'd consider just using a single file. But maybe that's not feasible…
|
BTW, I get this: Maybe this is related to bison version? (I have |
|
There are missing options which we used with configure:
|
I didn't expect this behavior. I definitely tested this, and I get the following instead without any errors: I expect that would make libsystemd dependency optional. I wonder why it doesn't work this way on your side. This is meson 1.5.1. @keszybz, any ideas why this check would behave so differently? |
Indeed, these are provided by autoconf. Added. |
This (no libsystemd, no error) also happens in github CI. |
|
The cc.find_library() calls are missing "required=false" as argument. From meson documentation: |
Indeed, but this affects only the pam_userdb case. The use of crypt library doesn't seem to be optional because it's used unconditionally by pam_pwhistory, and other libraries are not looked up using cc.find_library(). |
|
Of course not all find_library() calls require "required: false" as argument. Some have it already (like 'util'), other don't need it, but the three ones in the userdb case are missing it. |
According to the meson documentation the libsystemd check is correct and should work. But I see the error on all systems with meson 1.3.1 and 1.5.1. Need to try to debug that later... |
|
Between, I updated our PAM package with this PR and adjusted the spec file, this was really simple. |
On my non-representative hardware, the full build using autotools (./autogen.sh && CFLAGS=-O2 ./configure && make -j`nproc` && make -j`nproc` install) takes about 45 seconds. On the same hardware, the full build using meson (meson setup -Doptimization=2 dir && meson compile -C dir && meson install -C dir) takes just about 7.5 seconds.
Mark a few files and directories with export-ignore attribute so that they won't be added to archive files.
Found it, ignore it. It's a "feature" of our build system. |
033ff2c to
26a5ac8
Compare
|
The only remaining issue I'm aware of is what do we do with the The idea of distributing pre-built documentation became flawed when we started to use profile-docbook.xsl to generate parametrized manual pages. All that goes slightly beyond the scope of this PR, but should be decided upon before the final removal of autotools build support. |
OK, I've submitted a PR that drops autotools support for the next release: #839. |
On my non-representative hardware, the full build using autotools
(
./autogen.sh && CFLAGS=-O2 ./configure && make -j$(nproc) && make -j$(nproc) install)takes about 45 seconds.
On the same hardware, the full build using meson
(
meson setup -Doptimization=2 dir && meson compile -C dir && meson install -C dir)takes just about 7.5 seconds.