mirror of
https://github.com/apple/swift.git
synced 2026-10-02 10:58:03 +02:00
The Emscripten-host frontend and the wasi sysroot/stdlib bake the build machine's absolute source path into `__FILE__`/`#file` literals that ship in the served artifacts. When `TOOLCHAIN_FILE_PREFIX_MAP` is set, thread it through the C/C++/Swift compile flags as `-ffile-prefix-map`/`-file-prefix-map` to rewrite those paths to a neutral prefix. The wiring is a no-op when the variable is unset, so default builds are unchanged.