diff options
| author | tsne <tsne.dev@outlook.com> | 2026-05-13 11:33:08 +0200 |
|---|---|---|
| committer | tsne <tsne.dev@outlook.com> | 2026-05-22 08:25:27 +0200 |
| commit | c5b88c66ca8956df26ed87a7397862009e18cfc7 (patch) | |
| tree | 5a862bdacdeaa7fff73bf1bb2a423eee38f9b6e5 /build.zig | |
| parent | initial commit (diff) | |
| download | porteur-c5b88c66ca8956df26ed87a7397862009e18cfc7.tar.gz | |
upgrade to zig 0.16
Diffstat (limited to 'build.zig')
| -rw-r--r-- | build.zig | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -2,12 +2,14 @@ const std = @import("std"); pub fn build(b: *std.Build) void { const path_prefix = b.option([]const u8, "path-prefix", "The prefix which is set for porteur's data directories.") orelse b.getInstallPath(.prefix, "."); + const version = b.option([]const u8, "version", "The version used for porteur.") orelse "dev"; const target = b.standardTargetOptions(.{}); const optimize = b.standardOptimizeOption(.{}); const options = b.addOptions(); options.addOption([]const u8, "path_prefix", path_prefix); + options.addOption([]const u8, "version", version); const exe = b.addExecutable(.{ .name = "porteur", @@ -38,8 +40,4 @@ pub fn build(b: *std.Build) void { const run_test = b.addRunArtifact(tests); const test_step = b.step("test", "Run unit tests"); test_step.dependOn(&run_test.step); - - const clean_step = b.step("clean", "Clean up"); - clean_step.dependOn(&b.addRemoveDirTree(.{ .cwd_relative = b.install_path }).step); - clean_step.dependOn(&b.addRemoveDirTree(.{ .cwd_relative = b.pathFromRoot("zig-cache") }).step); } |