pothosware / SoapyRTLSDR

SoapySDR RTL-SDR Support Module
https://github.com/pothosware/SoapyRTLSDR/wiki
MIT License
124 stars 29 forks source link

Add check if libatomic is needed #42

Closed zuckschwerdt closed 4 years ago

zuckschwerdt commented 4 years ago

Code from LLVM project under LLVM Release License

Discussion in #41

zuckschwerdt commented 4 years ago

This needs further testing. The CMake module blindly assumes that -latomic will work. The check to find libatomic is disabled as it couldn't find the lib in the compiler specific path. Perhaps we don't need to find the lib but just try if -latomic works? Guess I'll rewrite the module.

guruofquality commented 4 years ago

Does this PR need more testing? https://github.com/pothosware/SoapyRTLSDR/issues/47

zuckschwerdt commented 4 years ago

I'll tinker with it some more today. It's not great but seems to work. I'm not sure what combination of Atomic/Atomic64 might require -latomic. Anyway it's neatly contained in one cmake module and should suffice for now.

zuckschwerdt commented 4 years ago

Reworked and simplified the detection logic. Actually looks sane now, merging.