aboutsummaryrefslogtreecommitdiff
path: root/test/standalone/empty_global_error_set/build.zig
blob: ad971aa6d113791521ee42afdfb06070d06d0cbb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
const std = @import("std");
const builtin = @import("builtin");

pub fn build(b: *std.Build) void {
    const test_step = b.step("test", "Test it");
    b.default_step = test_step;

    for ([_]bool{ false, true }) |use_llvm| {
        const main = b.addObject(.{
            .name = "main",
            .root_module = b.createModule(.{
                .root_source_file = b.path("main.zig"),
                .target = b.resolveTargetQuery(.{
                    .cpu_arch = .x86_64,
                    .os_tag = .linux,
                }),
            }),
            .use_llvm = use_llvm,
            .use_lld = use_llvm,
        });
        _ = main.getEmittedBin();
        test_step.dependOn(&main.step);
    }
}