aboutsummaryrefslogtreecommitdiff
path: root/lib/std/build.zig
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2021-04-30 00:10:44 -0400
committerGitHub <noreply@github.com>2021-04-30 00:10:44 -0400
commit4e07755ce705066cdb4e20feebc5010c7e3e6d12 (patch)
treec1676ae89de0a886055c730a17c1336cd55f372b /lib/std/build.zig
parent585479500e1941da25bcc4c55a4c3abc69fec031 (diff)
parent5079d11b213a02e9d9465f3371d0833021cfc636 (diff)
downloadzig-4e07755ce705066cdb4e20feebc5010c7e3e6d12.tar.gz
zig-4e07755ce705066cdb4e20feebc5010c7e3e6d12.zip
Merge pull request #8638 from ifreund/build-default-prefix
std/build: change default install prefix to zig-out
Diffstat (limited to 'lib/std/build.zig')
-rw-r--r--lib/std/build.zig3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/std/build.zig b/lib/std/build.zig
index fce3a0bceb..1811073279 100644
--- a/lib/std/build.zig
+++ b/lib/std/build.zig
@@ -195,7 +195,8 @@ pub const Builder = struct {
self.install_prefix = install_prefix orelse "/usr";
self.install_path = fs.path.join(self.allocator, &[_][]const u8{ dest_dir, self.install_prefix }) catch unreachable;
} else {
- self.install_prefix = install_prefix orelse self.cache_root;
+ self.install_prefix = install_prefix orelse
+ (fs.path.join(self.allocator, &[_][]const u8{ self.build_root, "zig-out" }) catch unreachable);
self.install_path = self.install_prefix;
}
self.lib_dir = fs.path.join(self.allocator, &[_][]const u8{ self.install_path, "lib" }) catch unreachable;