commit
c55984b58f
|
@ -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);
|
||||
|
|
|
@ -3809,6 +3809,7 @@ pub fn faccessatW(dirfd: fd_t, sub_path_w: [*:0]const u16, mode: u32, flags: u32
|
|||
.SUCCESS => return,
|
||||
.OBJECT_NAME_NOT_FOUND => return error.FileNotFound,
|
||||
.OBJECT_PATH_NOT_FOUND => return error.FileNotFound,
|
||||
.OBJECT_NAME_INVALID => unreachable,
|
||||
.INVALID_PARAMETER => unreachable,
|
||||
.ACCESS_DENIED => return error.PermissionDenied,
|
||||
.OBJECT_PATH_SYNTAX_BAD => unreachable,
|
||||
|
|
|
@ -1401,6 +1401,9 @@ fn buildOutputType(
|
|||
_ = system_libs.orderedRemove(i);
|
||||
continue;
|
||||
}
|
||||
if (std.fs.path.isAbsolute(lib_name)) {
|
||||
fatal("cannot use absolute path as a system library: {s}", .{lib_name});
|
||||
}
|
||||
i += 1;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue