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

Sanitizer Disable Does Not Work #2678

Open
LeStarch opened this issue Apr 12, 2024 · 2 comments
Open

Sanitizer Disable Does Not Work #2678

LeStarch opened this issue Apr 12, 2024 · 2 comments
Labels

Comments

@LeStarch
Copy link
Collaborator

F´ Version
Affected Component

Problem Description

Generating with -DENABLE_SANITIZER_ADDRESS=OFF does not work. Only the --disable-sanitizer to disable everything. The culprit is:

https://github.com/fprime-community/fprime-tools/blob/c15253c98ffc816bcca24db43f24c4c070b7c5ff/src/fprime/fbuild/cli.py#L55-L59

Notice how the sanitizers are forced-on.

The fix is in several stages:

  1. In CMake default to sanitizers should be == BUILD_TESTING (default "ON" when testing).
  2. Above code should read "if disable" set the ENABLES "OFF"
  3. Take no action on disable sanitizers not set

This way the sanitizers are explicitly turned off, or left to defaults.

@LeStarch LeStarch added the bug label Apr 12, 2024
@thomas-bc
Copy link
Collaborator

thomas-bc commented Apr 15, 2024

Could it also work if in the 4 lines you linked, each value in the cmake_args dictionary would be set to ON only if they are not in the cmake_args dictionary already (so not passed in by the user)?

@LeStarch
Copy link
Collaborator Author

That could work too.

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

No branches or pull requests

2 participants