Skip to content

Commit 0d52f10

Browse files
committed
Require Zig 0.14.0
1 parent cf50bc1 commit 0d52f10

File tree

2 files changed

+20
-14
lines changed

2 files changed

+20
-14
lines changed

build.zig

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,19 @@ pub fn build(b: *std.Build) void {
55
const optimize = b.standardOptimizeOption(.{});
66
const harfbuzz_enabled = b.option(bool, "enable-harfbuzz", "Use HarfBuzz to improve text shaping") orelse false;
77

8-
const upstream = b.dependency("sdl_ttf", .{});
8+
const upstream = b.dependency("SDL_ttf", .{});
99

10-
const lib = b.addStaticLibrary(.{
10+
const lib = b.addLibrary(.{
1111
.name = "SDL2_ttf",
12-
.target = target,
13-
.optimize = optimize,
12+
.version = .{ .major = 2, .minor = 24, .patch = 0 },
13+
.linkage = .static,
14+
.root_module = b.createModule(.{
15+
.target = target,
16+
.optimize = optimize,
17+
.link_libc = true,
18+
}),
1419
});
1520
lib.addCSourceFile(.{ .file = upstream.path("SDL_ttf.c") });
16-
lib.linkLibC();
1721

1822
if (harfbuzz_enabled) {
1923
const harfbuzz_dep = b.dependency("harfbuzz", .{
@@ -30,7 +34,7 @@ pub fn build(b: *std.Build) void {
3034
});
3135
lib.linkLibrary(freetype_dep.artifact("freetype"));
3236

33-
const sdl_dep = b.dependency("sdl", .{
37+
const sdl_dep = b.dependency("SDL", .{
3438
.target = target,
3539
.optimize = optimize,
3640
});

build.zig.zon

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,24 @@
11
.{
2-
.name = "SDL_ttf",
2+
.name = .SDL_ttf,
33
.version = "2.24.0",
4+
.fingerprint = 0xa98f7681c4b9d53c,
5+
.minimum_zig_version = "0.14.0",
46
.dependencies = .{
57
.harfbuzz = .{
68
.url = "git+https://github.com/allyourcodebase/harfbuzz#d642b5da200481be30a2e3518e7716722079d6a5",
7-
.hash = "122070f575e5d253373a1cb40352118f59b5934858a178370add2d3de9ad8819e149",
9+
.hash = "harfbuzz-8.4.0-AAAAAESZAABw9XXl0lM3Ohy0A1IRj1m1k0hYoXg3Ct0t",
810
},
911
.freetype = .{
1012
.url = "git+https://github.com/allyourcodebase/freetype#d0a748192f26bd20f9f339d0d7156b84e90eb4dc",
11-
.hash = "1220fb290c4071d0d889d27762282f473b5f9cb9a7e2b429bcb9acbd9172a6e2a1e4",
13+
.hash = "freetype-2.13.2-AAAAAByJAAD7KQxAcdDYidJ3YigvRztfnLmn4rQpvLms",
1214
},
13-
.sdl = .{
14-
.url = "git+https://github.com/allyourcodebase/SDL#0466e880e600b091940913b23d926d5ec5cfdec2",
15-
.hash = "122049871919faf5a46bb26f1664dc140f9fecdec0d7116ccbf536dc3379738e2096",
15+
.SDL = .{
16+
.url = "git+https://github.com/allyourcodebase/SDL#6f426d8f1bfbc796ff41e6fda2890790ed34f2c7",
17+
.hash = "SDL-2.32.2-JToi31GUEgGOf7m8tPCktmPE1Z0cO8bfst98IDm6xJw4",
1618
},
17-
.sdl_ttf = .{
19+
.SDL_ttf = .{
1820
.url = "git+https://github.com/libsdl-org/SDL_ttf#release-2.24.0",
19-
.hash = "1220cdf95cd4f290d47006c04c55c9fabbe73a44a00113438f225b940a2a2af2c685",
21+
.hash = "N-V-__8AAExyawHN-VzU8pDUcAbATFXJ-rvnOkSgARNDjyJb",
2022
},
2123
},
2224
.paths = .{

0 commit comments

Comments
 (0)