aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2019-10-03 16:02:24 -0400
committerAndrew Kelley <andrew@ziglang.org>2019-10-03 16:02:24 -0400
commit7481a4ad089c0195fe238ef160ec667e3f604d22 (patch)
tree16680249dc356d56d05cc296e78bad75cab840e2 /lib
parentedef35bb57c3e205b5adb577828aa90681793151 (diff)
downloadzig-7481a4ad089c0195fe238ef160ec667e3f604d22.tar.gz
zig-7481a4ad089c0195fe238ef160ec667e3f604d22.zip
zig build: fix exe file ext to match target.cpp
Diffstat (limited to 'lib')
-rw-r--r--lib/std/build.zig13
1 files changed, 9 insertions, 4 deletions
diff --git a/lib/std/build.zig b/lib/std/build.zig
index 3b5299f523..c640f6e8f3 100644
--- a/lib/std/build.zig
+++ b/lib/std/build.zig
@@ -1163,10 +1163,15 @@ pub const Target = union(enum) {
}
pub fn exeFileExt(self: Target) []const u8 {
- return switch (self.getOs()) {
- .windows => ".exe",
- else => "",
- };
+ if (self.isWindows()) {
+ return ".exe";
+ } else if (self.isUefi()) {
+ return ".efi";
+ } else if (self.isWasm()) {
+ return ".wasm";
+ } else {
+ return "";
+ }
}
pub fn staticLibSuffix(self: Target) []const u8 {