build: fix compilation errors
this should make linux CI green
This commit is contained in:
parent
62e00bfbd0
commit
9f6c4bf7b1
3 changed files with 17 additions and 9 deletions
|
|
@ -169,12 +169,12 @@ pub fn Sdk(comptime deps: anytype) type {
|
|||
}
|
||||
}
|
||||
|
||||
fn getGitHubBaseURLOwned(allocator: std.mem.Allocator) []const u8 {
|
||||
fn getGitHubBaseURLOwned(allocator: std.mem.Allocator) ![]const u8 {
|
||||
if (std.process.getEnvVarOwned(allocator, "MACH_GITHUB_BASE_URL")) |base_url| {
|
||||
std.log.info("mach: respecting MACH_GITHUB_BASE_URL: {s}\n", .{base_url});
|
||||
return base_url;
|
||||
} else |_| {
|
||||
return "https://github.com";
|
||||
return allocator.dupe(u8, "https://github.com");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -330,7 +330,7 @@ pub fn Sdk(comptime deps: anytype) type {
|
|||
|
||||
// Compose the download URL, e.g.:
|
||||
// https://github.com/hexops/mach-gpu-dawn/releases/download/release-6b59025/libdawn_x86_64-macos-none_debug.a.gz
|
||||
const github_base_url = getGitHubBaseURLOwned(allocator);
|
||||
const github_base_url = try getGitHubBaseURLOwned(allocator);
|
||||
defer allocator.free(github_base_url);
|
||||
const lib_prefix = if (is_windows) "dawn_" else "libdawn_";
|
||||
const lib_ext = if (is_windows) ".lib" else ".a";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue