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

cmake: make gprof optional for debug builds #6120

Merged
merged 1 commit into from
May 17, 2024
Merged

Conversation

cnt0
Copy link
Contributor

@cnt0 cnt0 commented May 17, 2024

Hyprland can't be built with cmake in debug mode on musl systems, because musl doesn't support the -pg flag.

This PR fixes that by making this flag optional (enabled by default).

Also, fix PIE flags: it should be -fno-pie for compilation, -no-pie for linking.

This fixes the debug build on musl systems, as -pg option is specific to
glibc. Now we can build the project on such systems with -DUSE_GPROF=OFF
Copy link
Member

@vaxerski vaxerski left a comment

Choose a reason for hiding this comment

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

lgtm

@vaxerski vaxerski merged commit f914314 into hyprwm:main May 17, 2024
10 checks passed
@cnt0 cnt0 deleted the musl-build branch May 17, 2024 12:41
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 this pull request may close these issues.

2 participants