Skip to content

Commit

Permalink
Install graf.h as part of the static/shared library steps.
Browse files Browse the repository at this point in the history
  • Loading branch information
alexrp committed Jul 6, 2024
1 parent 8faf11c commit d605184
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -149,11 +149,6 @@ pub fn build(b: *std.Build) anyerror!void {
}
}

install_tls.dependOn(&b.addInstallHeaderFile(
b.path(b.pathJoin(&.{ "inc", "graf.h" })),
b.pathJoin(&.{ "graf", "graf.h" }),
).step);

const stlib_step = b.addStaticLibrary(.{
// Avoid name clash with the DLL import library on Windows.
.name = if (t.os.tag == .windows) "libgraf" else "graf",
Expand All @@ -175,6 +170,8 @@ pub fn build(b: *std.Build) anyerror!void {
shlib_step.linker_allow_shlib_undefined = false;

inline for (.{ stlib_step, shlib_step }) |step| {
step.installHeadersDirectory(b.path("inc"), "graf", .{});

b.installArtifact(step);
}

Expand Down

0 comments on commit d605184

Please sign in to comment.