mirror of
https://codeberg.org/ziglang/zig.git
synced 2025-12-06 13:54:21 +00:00
CLI: delete dead option -femit-analysis
This used to do something with the old autodocs system. Now it does nothing.
This commit is contained in:
parent
d21d1d4ba2
commit
575a7cccc0
3 changed files with 0 additions and 35 deletions
|
|
@ -46,7 +46,6 @@ framework_dirs: ArrayList(FileSource),
|
||||||
frameworks: StringHashMap(FrameworkLinkInfo),
|
frameworks: StringHashMap(FrameworkLinkInfo),
|
||||||
verbose_link: bool,
|
verbose_link: bool,
|
||||||
verbose_cc: bool,
|
verbose_cc: bool,
|
||||||
emit_analysis: EmitOption = .default,
|
|
||||||
emit_asm: EmitOption = .default,
|
emit_asm: EmitOption = .default,
|
||||||
emit_bin: EmitOption = .default,
|
emit_bin: EmitOption = .default,
|
||||||
emit_implib: EmitOption = .default,
|
emit_implib: EmitOption = .default,
|
||||||
|
|
@ -1516,7 +1515,6 @@ fn make(step: *Step, prog_node: *std.Progress.Node) !void {
|
||||||
if (b.verbose_cc or self.verbose_cc) try zig_args.append("--verbose-cc");
|
if (b.verbose_cc or self.verbose_cc) try zig_args.append("--verbose-cc");
|
||||||
if (b.verbose_llvm_cpu_features) try zig_args.append("--verbose-llvm-cpu-features");
|
if (b.verbose_llvm_cpu_features) try zig_args.append("--verbose-llvm-cpu-features");
|
||||||
|
|
||||||
if (self.emit_analysis.getArg(b, "emit-analysis")) |arg| try zig_args.append(arg);
|
|
||||||
if (self.emit_asm.getArg(b, "emit-asm")) |arg| try zig_args.append(arg);
|
if (self.emit_asm.getArg(b, "emit-asm")) |arg| try zig_args.append(arg);
|
||||||
if (self.emit_bin.getArg(b, "emit-bin")) |arg| try zig_args.append(arg);
|
if (self.emit_bin.getArg(b, "emit-bin")) |arg| try zig_args.append(arg);
|
||||||
if (self.generated_docs != null) try zig_args.append("-femit-docs");
|
if (self.generated_docs != null) try zig_args.append("-femit-docs");
|
||||||
|
|
|
||||||
|
|
@ -179,7 +179,6 @@ test_name_prefix: ?[]const u8,
|
||||||
emit_asm: ?EmitLoc,
|
emit_asm: ?EmitLoc,
|
||||||
emit_llvm_ir: ?EmitLoc,
|
emit_llvm_ir: ?EmitLoc,
|
||||||
emit_llvm_bc: ?EmitLoc,
|
emit_llvm_bc: ?EmitLoc,
|
||||||
emit_analysis: ?EmitLoc,
|
|
||||||
|
|
||||||
work_queue_wait_group: WaitGroup = .{},
|
work_queue_wait_group: WaitGroup = .{},
|
||||||
astgen_wait_group: WaitGroup = .{},
|
astgen_wait_group: WaitGroup = .{},
|
||||||
|
|
@ -482,8 +481,6 @@ pub const InitOptions = struct {
|
||||||
emit_llvm_ir: ?EmitLoc = null,
|
emit_llvm_ir: ?EmitLoc = null,
|
||||||
/// `null` means to not emit LLVM module bitcode.
|
/// `null` means to not emit LLVM module bitcode.
|
||||||
emit_llvm_bc: ?EmitLoc = null,
|
emit_llvm_bc: ?EmitLoc = null,
|
||||||
/// `null` means to not emit semantic analysis JSON.
|
|
||||||
emit_analysis: ?EmitLoc = null,
|
|
||||||
/// `null` means to not emit docs.
|
/// `null` means to not emit docs.
|
||||||
emit_docs: ?EmitLoc = null,
|
emit_docs: ?EmitLoc = null,
|
||||||
/// `null` means to not emit an import lib.
|
/// `null` means to not emit an import lib.
|
||||||
|
|
@ -1590,7 +1587,6 @@ pub fn create(gpa: Allocator, options: InitOptions) !*Compilation {
|
||||||
.emit_asm = options.emit_asm,
|
.emit_asm = options.emit_asm,
|
||||||
.emit_llvm_ir = options.emit_llvm_ir,
|
.emit_llvm_ir = options.emit_llvm_ir,
|
||||||
.emit_llvm_bc = options.emit_llvm_bc,
|
.emit_llvm_bc = options.emit_llvm_bc,
|
||||||
.emit_analysis = options.emit_analysis,
|
|
||||||
.work_queue = std.fifo.LinearFifo(Job, .Dynamic).init(gpa),
|
.work_queue = std.fifo.LinearFifo(Job, .Dynamic).init(gpa),
|
||||||
.anon_work_queue = std.fifo.LinearFifo(Job, .Dynamic).init(gpa),
|
.anon_work_queue = std.fifo.LinearFifo(Job, .Dynamic).init(gpa),
|
||||||
.c_object_work_queue = std.fifo.LinearFifo(*CObject, .Dynamic).init(gpa),
|
.c_object_work_queue = std.fifo.LinearFifo(*CObject, .Dynamic).init(gpa),
|
||||||
|
|
@ -2329,7 +2325,6 @@ fn addNonIncrementalStuffToCacheManifest(comp: *Compilation, man: *Cache.Manifes
|
||||||
cache_helpers.addOptionalEmitLoc(&man.hash, comp.emit_asm);
|
cache_helpers.addOptionalEmitLoc(&man.hash, comp.emit_asm);
|
||||||
cache_helpers.addOptionalEmitLoc(&man.hash, comp.emit_llvm_ir);
|
cache_helpers.addOptionalEmitLoc(&man.hash, comp.emit_llvm_ir);
|
||||||
cache_helpers.addOptionalEmitLoc(&man.hash, comp.emit_llvm_bc);
|
cache_helpers.addOptionalEmitLoc(&man.hash, comp.emit_llvm_bc);
|
||||||
cache_helpers.addOptionalEmitLoc(&man.hash, comp.emit_analysis);
|
|
||||||
|
|
||||||
man.hash.addListOfBytes(comp.clang_argv);
|
man.hash.addListOfBytes(comp.clang_argv);
|
||||||
|
|
||||||
|
|
|
||||||
28
src/main.zig
28
src/main.zig
|
|
@ -384,8 +384,6 @@ const usage_build_generic =
|
||||||
\\ -fno-emit-h (default) Do not generate a C header file (.h)
|
\\ -fno-emit-h (default) Do not generate a C header file (.h)
|
||||||
\\ -femit-docs[=path] Create a docs/ dir with html documentation
|
\\ -femit-docs[=path] Create a docs/ dir with html documentation
|
||||||
\\ -fno-emit-docs (default) Do not produce docs/ dir with html documentation
|
\\ -fno-emit-docs (default) Do not produce docs/ dir with html documentation
|
||||||
\\ -femit-analysis[=path] Write analysis JSON file with type information
|
|
||||||
\\ -fno-emit-analysis (default) Do not write analysis JSON file with type information
|
|
||||||
\\ -femit-implib[=path] (default) Produce an import .lib when building a Windows DLL
|
\\ -femit-implib[=path] (default) Produce an import .lib when building a Windows DLL
|
||||||
\\ -fno-emit-implib Do not produce an import .lib when building a Windows DLL
|
\\ -fno-emit-implib Do not produce an import .lib when building a Windows DLL
|
||||||
\\ --show-builtin Output the source of @import("builtin") then exit
|
\\ --show-builtin Output the source of @import("builtin") then exit
|
||||||
|
|
@ -755,7 +753,6 @@ fn buildOutputType(
|
||||||
var emit_llvm_ir: Emit = .no;
|
var emit_llvm_ir: Emit = .no;
|
||||||
var emit_llvm_bc: Emit = .no;
|
var emit_llvm_bc: Emit = .no;
|
||||||
var emit_docs: Emit = .no;
|
var emit_docs: Emit = .no;
|
||||||
var emit_analysis: Emit = .no;
|
|
||||||
var emit_implib: Emit = .yes_default_path;
|
var emit_implib: Emit = .yes_default_path;
|
||||||
var emit_implib_arg_provided = false;
|
var emit_implib_arg_provided = false;
|
||||||
var target_arch_os_abi: []const u8 = "native";
|
var target_arch_os_abi: []const u8 = "native";
|
||||||
|
|
@ -1336,12 +1333,6 @@ fn buildOutputType(
|
||||||
emit_docs = .{ .yes = arg["-femit-docs=".len..] };
|
emit_docs = .{ .yes = arg["-femit-docs=".len..] };
|
||||||
} else if (mem.eql(u8, arg, "-fno-emit-docs")) {
|
} else if (mem.eql(u8, arg, "-fno-emit-docs")) {
|
||||||
emit_docs = .no;
|
emit_docs = .no;
|
||||||
} else if (mem.eql(u8, arg, "-femit-analysis")) {
|
|
||||||
emit_analysis = .yes_default_path;
|
|
||||||
} else if (mem.startsWith(u8, arg, "-femit-analysis=")) {
|
|
||||||
emit_analysis = .{ .yes = arg["-femit-analysis=".len..] };
|
|
||||||
} else if (mem.eql(u8, arg, "-fno-emit-analysis")) {
|
|
||||||
emit_analysis = .no;
|
|
||||||
} else if (mem.eql(u8, arg, "-femit-implib")) {
|
} else if (mem.eql(u8, arg, "-femit-implib")) {
|
||||||
emit_implib = .yes_default_path;
|
emit_implib = .yes_default_path;
|
||||||
emit_implib_arg_provided = true;
|
emit_implib_arg_provided = true;
|
||||||
|
|
@ -2824,24 +2815,6 @@ fn buildOutputType(
|
||||||
};
|
};
|
||||||
defer emit_llvm_bc_resolved.deinit();
|
defer emit_llvm_bc_resolved.deinit();
|
||||||
|
|
||||||
const default_analysis_basename = try std.fmt.allocPrint(arena, "{s}-analysis.json", .{root_name});
|
|
||||||
var emit_analysis_resolved = emit_analysis.resolve(default_analysis_basename, output_to_cache) catch |err| {
|
|
||||||
switch (emit_analysis) {
|
|
||||||
.yes => |p| {
|
|
||||||
fatal("unable to open directory from argument '-femit-analysis', '{s}': {s}", .{
|
|
||||||
p, @errorName(err),
|
|
||||||
});
|
|
||||||
},
|
|
||||||
.yes_default_path => {
|
|
||||||
fatal("unable to open directory from arguments 'name' or 'soname', '{s}': {s}", .{
|
|
||||||
default_analysis_basename, @errorName(err),
|
|
||||||
});
|
|
||||||
},
|
|
||||||
.no => unreachable,
|
|
||||||
}
|
|
||||||
};
|
|
||||||
defer emit_analysis_resolved.deinit();
|
|
||||||
|
|
||||||
var emit_docs_resolved = emit_docs.resolve("docs", output_to_cache) catch |err| {
|
var emit_docs_resolved = emit_docs.resolve("docs", output_to_cache) catch |err| {
|
||||||
switch (emit_docs) {
|
switch (emit_docs) {
|
||||||
.yes => |p| {
|
.yes => |p| {
|
||||||
|
|
@ -3096,7 +3069,6 @@ fn buildOutputType(
|
||||||
.emit_llvm_ir = emit_llvm_ir_resolved.data,
|
.emit_llvm_ir = emit_llvm_ir_resolved.data,
|
||||||
.emit_llvm_bc = emit_llvm_bc_resolved.data,
|
.emit_llvm_bc = emit_llvm_bc_resolved.data,
|
||||||
.emit_docs = emit_docs_resolved.data,
|
.emit_docs = emit_docs_resolved.data,
|
||||||
.emit_analysis = emit_analysis_resolved.data,
|
|
||||||
.emit_implib = emit_implib_resolved.data,
|
.emit_implib = emit_implib_resolved.data,
|
||||||
.link_mode = link_mode,
|
.link_mode = link_mode,
|
||||||
.dll_export_fns = dll_export_fns,
|
.dll_export_fns = dll_export_fns,
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue