Browse Source

[cmake] use -mtls-dialect=gnu2 (#3948)

see: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120933

we use TLS very sparingly (which is a good thing), some of our dependencies, in turn, may not
we should be aware of that fact

allegedly, there are minor glibc issues and such, but most distros should be fine
additionally, this is only enabled for FreeBSD and Linux, if it works on FreeBSD, naturally every Linux distro should support it as well

Signed-off-by: lizzie <lizzie@eden-emu.dev>

Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3948
Reviewed-by: CamilleLaVey <camillelavey99@gmail.com>
Reviewed-by: Maufeat <sahyno1996@gmail.com>
pull/3504/head
lizzie 1 week ago
committed by crueter
parent
commit
d1ceeeca22
No known key found for this signature in database GPG Key ID: 425ACD2D4830EBC6
  1. 5
      src/CMakeLists.txt

5
src/CMakeLists.txt

@ -159,7 +159,10 @@ else()
endif() endif()
if (ARCHITECTURE_x86_64) if (ARCHITECTURE_x86_64)
add_compile_options(-mcx16)
add_compile_options($<$<COMPILE_LANGUAGE:C,CXX>:-mcx16>)
if (PLATFORM_LINUX OR PLATFORM_FREEBSD)
add_compile_options($<$<COMPILE_LANGUAGE:C,CXX>:-mtls-dialect=gnu2>)
endif()
endif() endif()
if (APPLE AND CXX_CLANG) if (APPLE AND CXX_CLANG)

Loading…
Cancel
Save