mirror of
https://codeberg.org/ziglang/zig.git
synced 2026-04-26 13:01:34 +03:00
compiler: delete dependency on LLVM ParseCommandLineOptions
This commit is contained in:
@@ -335,9 +335,6 @@ extern fn ZigLLVMWriteArchive(
|
|||||||
archive_kind: ArchiveKind,
|
archive_kind: ArchiveKind,
|
||||||
) bool;
|
) bool;
|
||||||
|
|
||||||
pub const ParseCommandLineOptions = ZigLLVMParseCommandLineOptions;
|
|
||||||
extern fn ZigLLVMParseCommandLineOptions(argc: usize, argv: [*]const [*:0]const u8) void;
|
|
||||||
|
|
||||||
pub const GetHostCPUName = LLVMGetHostCPUName;
|
pub const GetHostCPUName = LLVMGetHostCPUName;
|
||||||
extern fn LLVMGetHostCPUName() ?[*:0]u8;
|
extern fn LLVMGetHostCPUName() ?[*:0]u8;
|
||||||
|
|
||||||
|
|||||||
@@ -3446,12 +3446,6 @@ fn buildOutputType(
|
|||||||
src.src_path = try dirs.local_cache.join(arena, &.{sub_path});
|
src.src_path = try dirs.local_cache.join(arena, &.{sub_path});
|
||||||
}
|
}
|
||||||
|
|
||||||
if (build_options.have_llvm and emit_asm_resolved != .no) {
|
|
||||||
// LLVM has no way to set this non-globally.
|
|
||||||
const argv = [_][*:0]const u8{ "zig (LLVM option parsing)", "--x86-asm-syntax=intel" };
|
|
||||||
@import("codegen/llvm/bindings.zig").ParseCommandLineOptions(argv.len, &argv);
|
|
||||||
}
|
|
||||||
|
|
||||||
const clang_passthrough_mode = switch (arg_mode) {
|
const clang_passthrough_mode = switch (arg_mode) {
|
||||||
.cc, .cpp, .translate_c => true,
|
.cc, .cpp, .translate_c => true,
|
||||||
else => false,
|
else => false,
|
||||||
|
|||||||
@@ -468,10 +468,6 @@ bool ZigLLVMGetBrokenDebugInfo(LLVMContextRef context_ref) {
|
|||||||
unwrap(context_ref)->getDiagHandlerPtr())->BrokenDebugInfo;
|
unwrap(context_ref)->getDiagHandlerPtr())->BrokenDebugInfo;
|
||||||
}
|
}
|
||||||
|
|
||||||
void ZigLLVMParseCommandLineOptions(size_t argc, const char *const *argv) {
|
|
||||||
cl::ParseCommandLineOptions(argc, argv);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool ZigLLVMWriteArchive(const char *archive_name, const char **file_names, size_t file_name_count,
|
bool ZigLLVMWriteArchive(const char *archive_name, const char **file_names, size_t file_name_count,
|
||||||
ZigLLVMArchiveKind archive_kind)
|
ZigLLVMArchiveKind archive_kind)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user