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

Wayland: Fix build config with so_wrap disabled #102673

Merged

Conversation

akien-mga
Copy link
Member

We should only include the vendored headers for Wayland and libdecor-0 when we use so_wrap, i.e. when we don't build against system libraries.

The libdecor-0 pkg-config file includes the libdecor-0/ prefix already, so its header should be included without it, and likewise in our so wrappers. Fixes #102671.

Didn't test much, CC @ArchercatNEO.

We should only include the vendored headers for Wayland and libdecor-0 when
we use `so_wrap`, i.e. when we *don't* build against system libraries.

The libdecor-0 pkg-config file includes the `libdecor-0/` prefix already,
so its header should be included without it, and likewise in our so wrappers.
Fixes godotengine#102671.

if env["libdecor"]:
env.Append(CPPDEFINES=["LIBDECOR_ENABLED"])

env.Prepend(CPPPATH=["#platform/linuxbsd", "#thirdparty/linuxbsd_headers/wayland/"])
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The #platform/linubsd was redundant, it's already included earlier.

Copy link
Contributor

@ArchercatNEO ArchercatNEO left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah lgtm.

Copy link
Contributor

@Riteo Riteo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code checks out! Can't test it easily either unfortunately but that's definitely how things should've been done in the first place.

@akien-mga akien-mga modified the milestones: 4.x, 4.4 Feb 10, 2025
@akien-mga akien-mga merged commit f9c233c into godotengine:master Feb 11, 2025
20 checks passed
@akien-mga akien-mga deleted the linux-wayland-so_wrap-disabled branch February 11, 2025 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

When compiling with so_wrap=false libdecor's pkg-config is incorrect
3 participants