odin-lang / Odin

Odin Programming Language
https://odin-lang.org
BSD 3-Clause "New" or "Revised" License
6.55k stars 570 forks source link

`-no-crt` hello world does not compile because of thread local usage #4016

Open laytan opened 1 month ago

laytan commented 1 month ago

I am on MacOS but I believe this would show everywhere.

package main

import "base:runtime"

main :: proc() {
    runtime.print_string("Hellope!\n")
}
odin run test-minimal.odin -file -no-crt -default-to-nil-allocator -no-thread-local
Undefined symbols for architecture arm64:
  "__tlv_bootstrap", referenced from:
      _runtime.default_random_generator_proc-.global_rand_seed-2721 in test-minimal.o
ld: symbol(s) not found for architecture arm64
clang-15 error: linker command failed with exit code 1 (use -v to see invocation)
gingerBill commented 3 weeks ago

Can we just not add this manually and provide our own "crt" for darwin?