refactor: rename pkgs
This commit is contained in:
parent
2b5f1a0024
commit
ca64dae639
15 changed files with 5 additions and 22 deletions
|
|
@ -6,7 +6,7 @@ pub fn build(b: *std.Build) !void {
|
|||
const is_wasm_freestanding = target.result.cpu.arch.isWasm() and target.result.os.tag == .freestanding;
|
||||
|
||||
// --- Rust C ABI & Pre-built via temporal-rs subpackage --- //
|
||||
const libtemporal_src = b.dependency("libtemporal_src", .{
|
||||
const temporal = b.dependency("temporal", .{
|
||||
.target = target,
|
||||
.optimize = optimize,
|
||||
});
|
||||
|
|
@ -17,9 +17,7 @@ pub fn build(b: *std.Build) !void {
|
|||
.target = target,
|
||||
.optimize = optimize,
|
||||
});
|
||||
|
||||
// Use the comprehensive mod from the package
|
||||
mod.addImport("temporal_rs", libtemporal_src.module("temporal_rs"));
|
||||
mod.addImport("temporal_rs", temporal.module("temporal_rs"));
|
||||
|
||||
// --- Zig Executable: temporalz --- //
|
||||
const exe_root = if (is_wasm_freestanding)
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@
|
|||
.fingerprint = 0xd8d79d59acc4faae,
|
||||
.minimum_zig_version = "0.16.0-dev.2860+9c5460316",
|
||||
.dependencies = .{
|
||||
.libtemporal_src = .{
|
||||
.path = "pkg/temporal-rs",
|
||||
.temporal = .{
|
||||
.path = "pkg/temporal",
|
||||
},
|
||||
},
|
||||
.paths = .{
|
||||
|
|
|
|||
|
|
@ -1,15 +0,0 @@
|
|||
const fs = require('fs');
|
||||
|
||||
const app_zon = fs.readFileSync('build.zig.zon', 'utf8');
|
||||
function extractDep(name) {
|
||||
const regex = new RegExp(`\\.${name}\\s*=\\s*\\{([\\s\\S]*?)\\},`);
|
||||
return app_zon.match(regex)[0];
|
||||
}
|
||||
|
||||
const p1 = extractDep('temporal_rs');
|
||||
const p2 = extractDep('libtemporal_prebuilt');
|
||||
|
||||
const pkg_zon = fs.readFileSync('pkg/temporal-rs/build.zig.zon', 'utf8');
|
||||
const new_pkg_zon = pkg_zon.replace(' .dependencies = .{', ` .dependencies = .{\n ${p1}\n ${p2}`);
|
||||
|
||||
fs.writeFileSync('pkg/temporal-rs/build.zig.zon', new_pkg_zon);
|
||||
Loading…
Add table
Reference in a new issue