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

Add sanitizers support to project #581

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

winterheart
Copy link
Collaborator

Supported sanitizers controlled by configure options SANITIZE_ADDRESS, SANITIZE_MEMORY, SANITIZE_THREAD and SANITIZE_UNDEFINED. Sanitizers support added to main executable, shared script libraries and netcon libraries.

Pull Request Type

  • GitHub Workflow changes
  • Documentation or Wiki changes
  • Build and Dependency changes
  • Runtime changes
    • Render changes
    • Audio changes
    • Input changes
    • Network changes
    • Other changes

Description

Related Issues

Screenshots (if applicable)

Checklist

  • I have tested my changes locally and verified that they work as intended.
  • I have documented any new or modified functionality.
  • I have reviewed the changes to ensure they do not introduce any unnecessary complexity or duplicate code.
  • I understand that by submitting this pull request, I am agreeing to license my contributions under the project's license.

Additional Comments

@jengelh
Copy link
Contributor

jengelh commented Sep 10, 2024

That is quite a lot of a code for something as simple as (the ideal case of desktoplinux):

x="-g -fsanitize=address,undefined"; cmake . -DCMAKE_CXX_FLAGS="$x" -DCMAKE_SHARED_LINKER_FLAGS="$x" -DCMAKE_EXE_LINKER_FLAGS="$x"

Supported sanitizers controlled by configure options `SANITIZE_ADDRESS`, `SANITIZE_MEMORY`, `SANITIZE_THREAD` and `SANITIZE_UNDEFINED`. Sanitizers support added to main executable, shared script libraries and netcon libraries.
@Lgt2x
Copy link
Member

Lgt2x commented Sep 16, 2024

I agree that it's a lot of infrastructure and CMake code to maintain to add compiler flags, not sure it's a great addition. We have little incentive to have a flawless cross-platform ASAN integration

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.

3 participants