diff options
| author | Isaac Freund <ifreund@ifreund.xyz> | 2021-03-22 12:10:10 +0100 |
|---|---|---|
| committer | Isaac Freund <ifreund@ifreund.xyz> | 2021-03-22 12:10:10 +0100 |
| commit | 979e64050780b6c7d40f372da7f3f4acdf16d822 (patch) | |
| tree | 49b51b6e4ead7a26eac7a4f53687ddd4b09d2c34 /build.zig | |
| parent | 6438f193ae709115dafb76a0c7488416ae78cee5 (diff) | |
| download | river-979e64050780b6c7d40f372da7f3f4acdf16d822.tar.gz river-979e64050780b6c7d40f372da7f3f4acdf16d822.tar.xz | |
build: fix config path if DESTDIR is set without --prefix
Diffstat (limited to 'build.zig')
| -rw-r--r-- | build.zig | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -56,7 +56,8 @@ pub fn build(b: *zbs.Builder) !void { }; b.installFile("example/init", rel_config_path); const abs_config_path = try fs.path.resolve(b.allocator, &[_][]const u8{ - b.install_prefix orelse b.cache_root, + // This logic must match std.build.resolveInstallPrefix() + b.install_prefix orelse if (b.dest_dir) |_| "/usr" else b.cache_root, rel_config_path, }); |
