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.rs: Remove DEBUG environment variable to prevent spurious build… #248

Merged
merged 1 commit into from
Aug 30, 2022

Conversation

vkleen
Copy link
Contributor

@vkleen vkleen commented Aug 29, 2022

This PR addresses #202.

When running build.rs, cargo sets the DEBUG environment variable to true or false depending on the build mode. However, the AFLplusplus makefiles only check if DEBUG is set or not. Hence, in either case, AFLplusplus will build in debug mode and append -Werror to CFLAGS.

@smoelius
Copy link
Member

Thank you very much for this analysis.

Could we make it that DEBUG is removed only when it is false?

@vkleen
Copy link
Contributor Author

vkleen commented Aug 30, 2022

Sure! I've force-pushed a change to that effect and also rebased onto the latest master.

build.rs Outdated Show resolved Hide resolved
The DEBUG variable is only removed it set to `false` by cargo. When
called with DEBUG set, AFLplusplus will set -Werror in CFLAGS and
sometimes fail to build spuriously.
@smoelius
Copy link
Member

Thanks a bunch!

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