mirror of
https://github.com/ziglang/zig.git
synced 2026-01-04 12:33:19 +00:00
build system: pass dyn lib artifacts as positionals
This commit is contained in:
parent
f7d0a32045
commit
9d1816111d
@ -1980,13 +1980,10 @@ pub const LibExeObjStep = struct {
|
||||
try zig_args.append(other.getOutputPath());
|
||||
},
|
||||
.Lib => {
|
||||
if (!other.is_dynamic or self.target.isWindows()) {
|
||||
try zig_args.append(other.getOutputLibPath());
|
||||
} else {
|
||||
const full_path_lib = other.getOutputPath();
|
||||
try zig_args.append("--library");
|
||||
try zig_args.append(full_path_lib);
|
||||
const full_path_lib = other.getOutputPath();
|
||||
try zig_args.append(full_path_lib);
|
||||
|
||||
if (other.is_dynamic and !self.target.isWindows()) {
|
||||
if (fs.path.dirname(full_path_lib)) |dirname| {
|
||||
try zig_args.append("-rpath");
|
||||
try zig_args.append(dirname);
|
||||
|
||||
@ -1402,7 +1402,7 @@ fn buildOutputType(
|
||||
continue;
|
||||
}
|
||||
if (std.fs.path.isAbsolute(lib_name)) {
|
||||
fatal("cannot use absolute path as a system library: {}", .{lib_name});
|
||||
fatal("cannot use absolute path as a system library: {s}", .{lib_name});
|
||||
}
|
||||
i += 1;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user