aboutsummaryrefslogtreecommitdiff
path: root/src/main.zig
diff options
context:
space:
mode:
authorRyan Liptak <squeek502@hotmail.com>2023-10-14 23:29:34 -0700
committerRyan Liptak <squeek502@hotmail.com>2023-10-15 13:33:16 -0700
commitb51147889f1c44d380818977a4dbefebffb8d91f (patch)
tree04bf22a169367815892862e1f96a4f7a2fd009fc /src/main.zig
parent5f15acc463d39baedd8de367330286b91c8bafc8 (diff)
downloadzig-b51147889f1c44d380818977a4dbefebffb8d91f.tar.gz
zig-b51147889f1c44d380818977a4dbefebffb8d91f.zip
Add warning if .xml file is used, since it's likely intended to be a Windows manifest file
Example: > zig build-exe test.zig test.xml warning: embedded manifest files must have the extension '.manifest' error: unrecognized file extension of parameter 'test.xml'
Diffstat (limited to 'src/main.zig')
-rw-r--r--src/main.zig3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/main.zig b/src/main.zig
index 5d5223ddb5..f5f149746c 100644
--- a/src/main.zig
+++ b/src/main.zig
@@ -1653,6 +1653,9 @@ fn buildOutputType(
} else root_src_file = arg;
},
.def, .unknown => {
+ if (std.ascii.eqlIgnoreCase(".xml", std.fs.path.extension(arg))) {
+ std.log.warn("embedded manifest files must have the extension '.manifest'", .{});
+ }
fatal("unrecognized file extension of parameter '{s}'", .{arg});
},
}