diff options
| author | _ov4 <ov4@ov4.org> | 2026-10-16 07:54:06 +0000 |
|---|---|---|
| committer | _ov4 <ov4@ov4.org> | 2026-10-16 07:54:06 +0000 |
| commit | 9226e87baacece10ea4971a9588d46e30cc23492 (patch) | |
| tree | fe2729d2bf6c07366e71a6d39421ff05b239b713 /tools/driver/NativeCompiler.h | |
| parent | c4565386553ea86308a9487650d2435804893ed0 (diff) | |
feat(driver): embed native compilation and link resources
Link LLVM, the Clang driver and LLD statically, and embed native link inputs
so executable generation needs no installed development toolchain.
Keep glibc dynamically linked on Linux.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Diffstat (limited to 'tools/driver/NativeCompiler.h')
| -rw-r--r-- | tools/driver/NativeCompiler.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tools/driver/NativeCompiler.h b/tools/driver/NativeCompiler.h new file mode 100644 index 0000000..17933e9 --- /dev/null +++ b/tools/driver/NativeCompiler.h @@ -0,0 +1,9 @@ +#pragma once + +#include "llvm/ADT/StringRef.h" + +namespace cps { class CodeGen; } + +// Generate a host executable without an external compiler, linker or SDK. +// Failure leaves any existing output intact and reports a diagnostic. +bool compileNative(const cps::CodeGen &CG, llvm::StringRef OutputPath); |
