aboutsummaryrefslogtreecommitdiff
path: root/src/main.zig
diff options
context:
space:
mode:
authorRobin Voetter <robin@voetter.nl>2021-01-19 00:34:44 +0100
committerRobin Voetter <robin@voetter.nl>2021-01-19 15:28:17 +0100
commitb2b87b590011d8df52874e3f9bd1f88d1b0189d1 (patch)
tree3cccc8d6f0424ef50361a9eec66b1ef021e3330d /src/main.zig
parentab607d455e47c35b980c3281ef5c3fb433a770a7 (diff)
downloadzig-b2b87b590011d8df52874e3f9bd1f88d1b0189d1.tar.gz
zig-b2b87b590011d8df52874e3f9bd1f88d1b0189d1.zip
SPIR-V: Linking and codegen setup
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 13bea13a5e..a86ec4ccf5 100644
--- a/src/main.zig
+++ b/src/main.zig
@@ -302,6 +302,7 @@ const usage_build_generic =
\\ pe Portable Executable (Windows)
\\ coff Common Object File Format (Windows)
\\ macho macOS relocatables
+ \\ spirv Standard, Portable Intermediate Representation V (SPIR-V)
\\ hex (planned) Intel IHEX
\\ raw (planned) Dump machine code directly
\\ -dirafter [dir] Add directory to AFTER include search path
@@ -1515,6 +1516,8 @@ fn buildOutputType(
break :blk .hex;
} else if (mem.eql(u8, ofmt, "raw")) {
break :blk .raw;
+ } else if (mem.eql(u8, ofmt, "spirv")) {
+ break :blk .spirv;
} else {
fatal("unsupported object format: {s}", .{ofmt});
}