Skip to content

Commit

Permalink
build.zig
Browse files Browse the repository at this point in the history
  • Loading branch information
herumi committed Oct 24, 2024
1 parent fb7095f commit 78e47e8
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions ffi/zig/build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,18 @@ pub fn build(b: *std.Build) void {
const target = b.standardTargetOptions(.{});
const optimize = b.standardOptimizeOption(.{});

const lib = b.addStaticLibrary(.{
.name = "bls-zig",
.root_source_file = b.path("bls.zig"),
.target = target,
.optimize = optimize,
});
lib.linkLibC();
lib.addLibraryPath(b.path("../../lib"));
lib.linkSystemLibrary("stdc++");
lib.linkSystemLibrary("bls384_256");
b.installArtifact(lib);

const exe = b.addExecutable(.{
.name = "sample",
.root_source_file = b.path("sample.zig"),
Expand Down

0 comments on commit 78e47e8

Please sign in to comment.