mirror of
https://github.com/zigzap/zap.git
synced 2025-10-20 15:14:08 +00:00
update to latest zig & adapt to new stdlib changes
This commit is contained in:
parent
151a011c24
commit
977fa41225
3 changed files with 13 additions and 13 deletions
14
build.zig
14
build.zig
|
@ -33,7 +33,7 @@ pub fn build(b: *std.build.Builder) !void {
|
||||||
// we install the facil dependency, just to see what it's like
|
// we install the facil dependency, just to see what it's like
|
||||||
// zig build with the default (install) step will install it
|
// zig build with the default (install) step will install it
|
||||||
facil_lib.installLibraryHeaders(facil_dep.artifact("facil.io"));
|
facil_lib.installLibraryHeaders(facil_dep.artifact("facil.io"));
|
||||||
const facil_install_step = b.addInstallArtifact(facil_lib);
|
const facil_install_step = b.addInstallArtifact(facil_lib, .{});
|
||||||
b.getInstallStep().dependOn(&facil_install_step.step);
|
b.getInstallStep().dependOn(&facil_install_step.step);
|
||||||
|
|
||||||
const all_step = b.step("all", "build all examples");
|
const all_step = b.step("all", "build all examples");
|
||||||
|
@ -96,7 +96,7 @@ pub fn build(b: *std.build.Builder) !void {
|
||||||
example_run_step.dependOn(&example_run.step);
|
example_run_step.dependOn(&example_run.step);
|
||||||
|
|
||||||
// install the artifact - depending on the "example"
|
// install the artifact - depending on the "example"
|
||||||
const example_build_step = b.addInstallArtifact(example);
|
const example_build_step = b.addInstallArtifact(example, .{});
|
||||||
example_step.dependOn(&example_build_step.step);
|
example_step.dependOn(&example_build_step.step);
|
||||||
all_step.dependOn(&example_build_step.step);
|
all_step.dependOn(&example_build_step.step);
|
||||||
}
|
}
|
||||||
|
@ -125,7 +125,7 @@ pub fn build(b: *std.build.Builder) !void {
|
||||||
auth_tests.addModule("zap", zap_module);
|
auth_tests.addModule("zap", zap_module);
|
||||||
|
|
||||||
const run_auth_tests = b.addRunArtifact(auth_tests);
|
const run_auth_tests = b.addRunArtifact(auth_tests);
|
||||||
const install_auth_tests = b.addInstallArtifact(auth_tests);
|
const install_auth_tests = b.addInstallArtifact(auth_tests, .{});
|
||||||
|
|
||||||
// http paramters (qyery, body) tests
|
// http paramters (qyery, body) tests
|
||||||
const httpparams_tests = b.addTest(.{
|
const httpparams_tests = b.addTest(.{
|
||||||
|
@ -142,7 +142,7 @@ pub fn build(b: *std.build.Builder) !void {
|
||||||
// dependencies have changed.
|
// dependencies have changed.
|
||||||
// So, for now, we just force the exe to be built, so in order that
|
// So, for now, we just force the exe to be built, so in order that
|
||||||
// we can call it again when needed.
|
// we can call it again when needed.
|
||||||
const install_httpparams_tests = b.addInstallArtifact(httpparams_tests);
|
const install_httpparams_tests = b.addInstallArtifact(httpparams_tests, .{});
|
||||||
|
|
||||||
// http paramters (qyery, body) tests
|
// http paramters (qyery, body) tests
|
||||||
const sendfile_tests = b.addTest(.{
|
const sendfile_tests = b.addTest(.{
|
||||||
|
@ -155,7 +155,7 @@ pub fn build(b: *std.build.Builder) !void {
|
||||||
sendfile_tests.linkLibrary(facil_dep.artifact("facil.io"));
|
sendfile_tests.linkLibrary(facil_dep.artifact("facil.io"));
|
||||||
sendfile_tests.addModule("zap", zap_module);
|
sendfile_tests.addModule("zap", zap_module);
|
||||||
const run_sendfile_tests = b.addRunArtifact(sendfile_tests);
|
const run_sendfile_tests = b.addRunArtifact(sendfile_tests);
|
||||||
const install_sendfile_tests = b.addInstallArtifact(sendfile_tests);
|
const install_sendfile_tests = b.addInstallArtifact(sendfile_tests, .{});
|
||||||
|
|
||||||
// test commands
|
// test commands
|
||||||
const run_auth_test_step = b.step("test-authentication", "Run auth unit tests [REMOVE zig-cache!]");
|
const run_auth_test_step = b.step("test-authentication", "Run auth unit tests [REMOVE zig-cache!]");
|
||||||
|
@ -188,7 +188,7 @@ pub fn build(b: *std.build.Builder) !void {
|
||||||
.optimize = optimize,
|
.optimize = optimize,
|
||||||
});
|
});
|
||||||
var pkghash_step = b.step("pkghash", "Build pkghash");
|
var pkghash_step = b.step("pkghash", "Build pkghash");
|
||||||
const pkghash_build_step = b.addInstallArtifact(pkghash_exe);
|
const pkghash_build_step = b.addInstallArtifact(pkghash_exe, .{});
|
||||||
pkghash_step.dependOn(&pkghash_build_step.step);
|
pkghash_step.dependOn(&pkghash_build_step.step);
|
||||||
all_step.dependOn(&pkghash_build_step.step);
|
all_step.dependOn(&pkghash_build_step.step);
|
||||||
|
|
||||||
|
@ -202,7 +202,7 @@ pub fn build(b: *std.build.Builder) !void {
|
||||||
.optimize = optimize,
|
.optimize = optimize,
|
||||||
});
|
});
|
||||||
var announceybot_step = b.step("announceybot", "Build announceybot");
|
var announceybot_step = b.step("announceybot", "Build announceybot");
|
||||||
const announceybot_build_step = b.addInstallArtifact(announceybot_exe);
|
const announceybot_build_step = b.addInstallArtifact(announceybot_exe, .{});
|
||||||
announceybot_step.dependOn(&announceybot_build_step.step);
|
announceybot_step.dependOn(&announceybot_build_step.step);
|
||||||
all_step.dependOn(&announceybot_build_step.step);
|
all_step.dependOn(&announceybot_build_step.step);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
.{
|
.{
|
||||||
.name = "zap",
|
.name = "zap",
|
||||||
.version = "0.1.9-pre",
|
.version = "0.1.10-pre",
|
||||||
|
|
||||||
.dependencies = .{
|
.dependencies = .{
|
||||||
.@"facil.io" = .{
|
.@"facil.io" = .{
|
||||||
.url = "https://github.com/zigzap/facil.io/archive/refs/tags/zap-0.0.11.tar.gz",
|
.url = "https://github.com/zigzap/facil.io/archive/refs/tags/zap-0.0.12.tar.gz",
|
||||||
.hash = "1220aeeb78554b41e8b4a61eca7f29031cca7cb31d935c5583db17c0bb1439b87334",
|
.hash = "12200301960bbde64052db068cf31a64091ce1f671898513d9b8d9e2be5b0e4b13a3",
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
6
flake.lock
generated
6
flake.lock
generated
|
@ -166,11 +166,11 @@
|
||||||
"nixpkgs": "nixpkgs_2"
|
"nixpkgs": "nixpkgs_2"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1690114050,
|
"lastModified": 1690891715,
|
||||||
"narHash": "sha256-dxVJqVgxQO2ryI92OHhWFVmUaPw+JpJ1tkDDlwZKec4=",
|
"narHash": "sha256-0y4ua6XQ+3gJgt0UmlwLS9Lw1fXRk4YYYmQ4huyMzec=",
|
||||||
"owner": "mitchellh",
|
"owner": "mitchellh",
|
||||||
"repo": "zig-overlay",
|
"repo": "zig-overlay",
|
||||||
"rev": "b6ce76ff966c5c5ca62ba6d961ef9dedace1ce96",
|
"rev": "baf7f3af81a249d72ad51feabb32e05125cbfcd5",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
Loading…
Add table
Reference in a new issue