Skip to content

Commit

Permalink
install libpython in zig-out/python
Browse files Browse the repository at this point in the history
  • Loading branch information
Rexicon226 committed Jun 29, 2024
1 parent 7657801 commit 1cfd7e3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.zig-cache/
zig-cache/
.vscode/
zig-out/

Expand Down
5 changes: 4 additions & 1 deletion build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,10 @@ pub fn build(b: *std.Build) !void {
exe_options.addOption([]const u8, "lib_path", lib_path);

b.installArtifact(exe);
b.installArtifact(libpython);
const libpython_install = b.addInstallArtifact(libpython, .{
.dest_dir = .{ .override = .{ .custom = "python" } },
});
b.getInstallStep().dependOn(&libpython_install.step);

const run_cmd = b.addRunArtifact(exe);
run_cmd.step.dependOn(b.getInstallStep());
Expand Down

0 comments on commit 1cfd7e3

Please sign in to comment.