mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-06-01 17:37:39 +00:00
Fixed building SDL applications with Visual Studio and the clang toolset
Also fixed building 64-bit SDL with clang. 32-bit doesn't build because of the inline assembly for C runtime support.
This commit is contained in:
parent
12d33b33ca
commit
30d554e3d6
4 changed files with 11 additions and 3 deletions
|
@ -118,7 +118,7 @@ extern DECLSPEC void SDLCALL SDL_AtomicUnlock(SDL_SpinLock *lock);
|
|||
* The compiler barrier prevents the compiler from reordering
|
||||
* reads and writes to globally visible variables across the call.
|
||||
*/
|
||||
#if defined(_MSC_VER) && (_MSC_VER > 1200)
|
||||
#if defined(_MSC_VER) && (_MSC_VER > 1200) && !defined(__clang__)
|
||||
void _ReadWriteBarrier(void);
|
||||
#pragma intrinsic(_ReadWriteBarrier)
|
||||
#define SDL_CompilerBarrier() _ReadWriteBarrier()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue