diff options
| author | 2023-07-04 03:16:51 +0300 | |
|---|---|---|
| committer | 2023-07-04 03:16:51 +0300 | |
| commit | f59c9dbb71153d0be62f7afcf4a1c9e8a4d59619 (patch) | |
| tree | 2d93bea4367cae2a5eb473411a32d59444480b1c | |
| parent | Use build.zig.zon for fetching curl (diff) | |
| download | zup-f59c9dbb71153d0be62f7afcf4a1c9e8a4d59619.tar.gz zup-f59c9dbb71153d0be62f7afcf4a1c9e8a4d59619.tar.xz zup-f59c9dbb71153d0be62f7afcf4a1c9e8a4d59619.zip | |
Use build.zig.zon for fetching libarchive
| -rw-r--r-- | build.zig | 5 | ||||
| -rw-r--r-- | build.zig.zon | 4 | ||||
| m--------- | libs/libarchive | 0 |
3 files changed, 6 insertions, 3 deletions
| @@ -15,6 +15,7 @@ pub fn build(b: *Build) void { | |||
| 15 | 15 | ||
| 16 | const clap = b.dependency("clap", .{}); | 16 | const clap = b.dependency("clap", .{}); |
| 17 | const curl = b.dependency("curl", .{}); | 17 | const curl = b.dependency("curl", .{}); |
| 18 | const libarchive = b.dependency("libarchive", .{}); | ||
| 18 | 19 | ||
| 19 | const exe = b.addExecutable(.{ | 20 | const exe = b.addExecutable(.{ |
| 20 | .name = "zup", | 21 | .name = "zup", |
| @@ -26,9 +27,7 @@ pub fn build(b: *Build) void { | |||
| 26 | exe.addOptions("zup-config", config); | 27 | exe.addOptions("zup-config", config); |
| 27 | exe.addModule("clap", clap.module("clap")); | 28 | exe.addModule("clap", clap.module("clap")); |
| 28 | exe.addModule("curl", curl.module("curl")); | 29 | exe.addModule("curl", curl.module("curl")); |
| 29 | exe.addModule("libarchive", b.createModule(.{ | 30 | exe.addModule("libarchive", libarchive.module("libarchive")); |
| 30 | .source_file = .{ .path = "libs/libarchive/libarchive.zig" }, | ||
| 31 | })); | ||
| 32 | exe.addModule("xdg", b.createModule(.{ .source_file = .{ .path = "libs/xdg/xdg.zig" } })); | 31 | exe.addModule("xdg", b.createModule(.{ .source_file = .{ .path = "libs/xdg/xdg.zig" } })); |
| 33 | exe.linkLibC(); | 32 | exe.linkLibC(); |
| 34 | exe.linkSystemLibrary("libarchive"); | 33 | exe.linkSystemLibrary("libarchive"); |
diff --git a/build.zig.zon b/build.zig.zon index 276ecef..72d7b61 100644 --- a/build.zig.zon +++ b/build.zig.zon | |||
| @@ -11,5 +11,9 @@ | |||
| 11 | .url = "https://git.sr.ht/~ukko/zig-curl/archive/aa55a3d061fceebf737c0af25a6df2d05f83bcad.tar.gz", | 11 | .url = "https://git.sr.ht/~ukko/zig-curl/archive/aa55a3d061fceebf737c0af25a6df2d05f83bcad.tar.gz", |
| 12 | .hash = "12208fc84cbd67383b6fe7e3f65a965cead4577ca27cd59660a2812c9f4edc545c5e", | 12 | .hash = "12208fc84cbd67383b6fe7e3f65a965cead4577ca27cd59660a2812c9f4edc545c5e", |
| 13 | }, | 13 | }, |
| 14 | .libarchive = .{ | ||
| 15 | .url = "https://git.sr.ht/~ukko/zig-libarchive/archive/b70c51b8555e68e73c36b0e691dff65c0092baf6.tar.gz", | ||
| 16 | .hash = "12206a8120d9a7550112f2fcc908c46900d6882c95156f900d5e0b39fcdb6a64a065", | ||
| 17 | }, | ||
| 14 | }, | 18 | }, |
| 15 | } | 19 | } |
diff --git a/libs/libarchive b/libs/libarchive deleted file mode 160000 | |||
| Subproject 50747939555b62e3b830c1ec307f746e35b94ec | |||