Page MenuHomePhabricator

[scudo][standalone] Link tests against libatomic

Authored by cryptoad on Jul 3 2019, 7:50 AM.



Some clang versions (< 6.0) do not inline the atomic builtin functions
leaving unresolved references to __atomic_load_8 and so on (seems to
be mostly 64-bit atomics on 32-bit platforms).
I tried without success to use some cmake magic to detect when that
would be the case, and decided to fall back to unconditionally
linking libatomic.

Diff Detail


Event Timeline

cryptoad created this revision.Jul 3 2019, 7:50 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptJul 3 2019, 7:50 AM
Herald added subscribers: Restricted Project, jfb, delcypher, mgorny. · View Herald Transcript
tejohnson accepted this revision.Jul 3 2019, 8:18 AM

LGTM. Confirmed this fixes my issue. FTR I am building on a 64-bit platform.

This revision is now accepted and ready to land.Jul 3 2019, 8:18 AM
This revision was automatically updated to reflect the committed changes.