Auto merge of #30417 - alexcrichton:better-detect-elf-tls, r=alexcrichton
Currently a compiler can be built with the `--disable-elf-tls` option for compatibility with OSX 10.6 which doesn't have ELF TLS. This is unfortunate, however, as a whole new compiler must be generated which can take some time. These commits add a new (feature gated) `cfg(target_thread_local)` annotation set by the compiler which indicates whether `#[thread_local]` is available for use. The compiler now interprets `MACOSX_DEPLOYMENT_TARGET` (a standard environment variable) to set this flag on OSX. With this we may want to start compiling our OSX nightlies with `MACOSX_DEPLOYMENT_TARGET` set to 10.6 which would allow the compiler out-of-the-box to generate 10.6-compatible binaries. For now the compiler still by default targets OSX 10.7 by allowing ELF TLS by default (e.g. if `MACOSX_DEPLOYMENT_TARGET` isn't set).
This commit is contained in:
commit
42c3ef8f9f
12 changed files with 103 additions and 84 deletions
|
@ -218,6 +218,7 @@
|
|||
#![feature(borrow_state)]
|
||||
#![feature(box_syntax)]
|
||||
#![feature(cfg_target_vendor)]
|
||||
#![feature(cfg_target_thread_local)]
|
||||
#![feature(char_internals)]
|
||||
#![feature(clone_from_slice)]
|
||||
#![feature(collections)]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue