Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build failing when using meson 1.4.0rc1 #228

Closed
DimStar77 opened this issue Feb 27, 2024 · 6 comments · Fixed by #229
Closed

Build failing when using meson 1.4.0rc1 #228

DimStar77 opened this issue Feb 27, 2024 · 6 comments · Fixed by #229

Comments

@DimStar77
Copy link

DimStar77 commented Feb 27, 2024

In order to test the impact of Meson 1.4.0 , I upgraded a test repository of openSUSE Tumbleweed to this new version,

Out of the builds, umockdev is failing (seems its failing similar to what that HACK commit addresses, which was done in Gentoo? Did Gentoo update to a 1.4 pre-release of meson?)

I get plenty of these errors:

[   12s] umockdev-record.p/src/umockdev-record.c:1141:22: error: unused variable ‘_line_collection_size_’ [-Werror=unused-variable]
[   12s]  1141 |                 gint _line_collection_size_ = 0;
[   12s]       |                      ^~~~~~~~~~~~~~~~~~~~~~

Simply going back to meson 1.3.2 makes umockdev build pass (CC @jpakkane / meson release maintainer)

(full build log can be found at https://build.opensuse.org/build/GNOME:Next/openSUSE_Factory/x86_64/umockdev/_log )

@DimStar77
Copy link
Author

git bisected this on the meson side to mesonbuild/meson@5f659af - aka mesonbuild/meson#12597

@martinpitt
Copy link
Owner

Oooh thanks @DimStar77 for figuring that out! 💯 I first saw this in the Gentoo build, and suspected gcc 14 or related, but couldn't find a meaningful difference. So I applied commit 539af0b.

So I suppose that should just become the new default. This makes sense at last!

@DimStar77
Copy link
Author

DimStar77 commented Feb 28, 2024

I first saw this in the Gentoo build, and suspected gcc 14 or related, but couldn't find a meaningful difference.

gentoo backported that vala fix from meson 1.4 into their package with gentoo/gentoo#34141

@DimStar77
Copy link
Author

So I suppose that should just become the new default. This makes sense at last!

on openSUSE, I added this to umockdev.spec:
export CFLAGS="-Wno-error=unused-function -Wno-error=unused-value -Wno-error=unused-variable %{optflags}"

martinpitt added a commit that referenced this issue Mar 1, 2024
meson 1.4 stopped hiding valac's warnings [1], which fails compilation
due to our `-Werror=` settings. There's not much that we can do at this
point, so stop making them non-fatal.

This reverts the `gentoo-hacks` option from commit 539af0b. Turns
out that this wasn't a compiler change in Gentoo after all, but that
Gentoo backported [2] that meson change at that time.

Many thanks to Dominique Leuenberger @DimStar77 for tracking down the
root cause!

Fixes #228

[1] mesonbuild/meson@5f659af870011e
[2] gentoo/gentoo#34141
martinpitt added a commit that referenced this issue Mar 1, 2024
meson 1.4 stopped hiding valac's warnings [1], which fails compilation
due to our `-Werror=` settings. There's not much that we can do at this
point, so stop making them non-fatal.

This reverts the `gentoo-hacks` option from commit 539af0b. Turns
out that this wasn't a compiler change in Gentoo after all, but that
Gentoo backported [2] that meson change at that time.

Many thanks to Dominique Leuenberger @DimStar77 for tracking down the
root cause!

Fixes #228

[1] mesonbuild/meson@5f659af870011e
[2] gentoo/gentoo#34141
martinpitt added a commit that referenced this issue Mar 1, 2024
meson 1.4 stopped hiding valac's warnings [1], which fails compilation
due to our `-Werror=` settings. There's not much that we can do at this
point, so stop making them non-fatal.

This reverts the `gentoo-hacks` option from commit 539af0b. Turns
out that this wasn't a compiler change in Gentoo after all, but that
Gentoo backported [2] that meson change at that time.

Many thanks to Dominique Leuenberger @DimStar77 for tracking down the
root cause!

Fixes #228

[1] mesonbuild/meson@5f659af870011e
[2] gentoo/gentoo#34141
@thesamesam
Copy link

By the way, feel free to CC me if there's anything like this which shows up for Gentoo which I might be able to give insight on. Happy to help!

@martinpitt
Copy link
Owner

Thanks @thesamesam It seems to be quite happy now, aside from the ugliness of #226.. (but that's not Gentoo specific at all).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants