From 1caf766f2407ca8db0a7c0dd50cc14a8194f5be6 Mon Sep 17 00:00:00 2001 From: Tobias Simetsreiter Date: Tue, 22 Oct 2024 21:57:16 +0200 Subject: [PATCH 1/3] rename os.getVersionRange to os.versionRange (zig 0.14.0-dev.1954+2d888a8e6) --- build.zig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.zig b/build.zig index 092930b..dd66a8f 100644 --- a/build.zig +++ b/build.zig @@ -125,7 +125,7 @@ pub fn build(b: *std.Build) void { fn target_has_sys_siglist(t: std.Build.ResolvedTarget) bool { if (t.result.isDarwin()) return true; if (t.result.isGnuLibC()) { - const vr = t.result.os.getVersionRange(); + const vr = t.result.os.versionRange(); // newer glibc does not allow linking with sys_siglist // https://lists.gnu.org/archive/html/info-gnu/2020-08/msg00002.html if (vr == .linux and vr.linux.glibc.major >= 2 and vr.linux.glibc.minor >= 32) From 4b716a255dfada8079153864f19ba4ccdb487d59 Mon Sep 17 00:00:00 2001 From: Tobias Simetsreiter Date: Fri, 20 Dec 2024 16:37:19 +0100 Subject: [PATCH 2/3] zig 0.14.0-dev.2545+e2e363361 --- build.zig | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/build.zig b/build.zig index dd66a8f..1ab7ded 100644 --- a/build.zig +++ b/build.zig @@ -43,7 +43,7 @@ pub fn build(b: *std.Build) void { config_header.addValues(.{ .HAVE_DECL_SYS_SIGLIST = 1, }); - exe.defineCMacro("SYS_SIGLIST_DECLARED", "1"); + exe.root_module.addCMacro("SYS_SIGLIST_DECLARED", "1"); } else { config_header.addValues(.{ .HAVE_DECL_SYS_SIGLIST = 0, @@ -51,21 +51,21 @@ pub fn build(b: *std.Build) void { } if (target.result.os.tag == .windows) { - exe.defineCMacro("_POSIX_", "1"); - exe.defineCMacro("putenv", "_putenv"); - exe.defineCMacro("getpid", "_getpid"); - exe.defineCMacro("fdopen", "_fdopen"); - exe.defineCMacro("environ", "(*__p__environ())"); + exe.root_module.addCMacro("_POSIX_", "1"); + exe.root_module.addCMacro("putenv", "_putenv"); + exe.root_module.addCMacro("getpid", "_getpid"); + exe.root_module.addCMacro("fdopen", "_fdopen"); + exe.root_module.addCMacro("environ", "(*__p__environ())"); } else { // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - exe.defineCMacro("LOCALEDIR", "\".\""); + exe.root_module.addCMacro("LOCALEDIR", "\".\""); // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - exe.defineCMacro("LIBDIR", "\"lib\""); + exe.root_module.addCMacro("LIBDIR", "\"lib\""); } if (target.result.isGnuLibC()) { // TODO: only do this if we are compiling against gnu - //exe.defineCMacro("__USE_GNU", "1"); - exe.defineCMacro("_GNU_SOURCE", "1"); + //exe.root_module.addCMacro("__USE_GNU", "1"); + exe.root_module.addCMacro("_GNU_SOURCE", "1"); } const write_files = b.addWriteFiles(); _ = write_files.addCopyFile(b.path("mkcustom.h"), "src/mkcustom.h"); @@ -170,7 +170,7 @@ fn linkGlob( const write_files = b.addWriteFiles(); _ = write_files.addCopyFile(make_dep.path("src/config.h.W32"), "src/config.h"); - lib.defineCMacro("HAVE_CONFIG_H", "1"); + lib.root_module.addCMacro("HAVE_CONFIG_H", "1"); lib.addIncludePath(make_dep.path("src")); lib.addIncludePath(make_dep.path("lib")); lib.addIncludePath(write_files.getDirectory().path(b, "src")); From 5ea895c985b9668f4a0f3a676b2a36ab4c227c14 Mon Sep 17 00:00:00 2001 From: Tobias Simetsreiter Date: Fri, 7 Mar 2025 11:58:31 +0100 Subject: [PATCH 3/3] zig 0.14.0 --- build.zig | 2 +- build.zig.zon | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/build.zig b/build.zig index 1ab7ded..da37b35 100644 --- a/build.zig +++ b/build.zig @@ -123,7 +123,7 @@ pub fn build(b: *std.Build) void { } fn target_has_sys_siglist(t: std.Build.ResolvedTarget) bool { - if (t.result.isDarwin()) return true; + if (t.result.os.tag.isDarwin()) return true; if (t.result.isGnuLibC()) { const vr = t.result.os.versionRange(); // newer glibc does not allow linking with sys_siglist diff --git a/build.zig.zon b/build.zig.zon index 9347724..3c94e54 100644 --- a/build.zig.zon +++ b/build.zig.zon @@ -1,11 +1,12 @@ .{ - .name = "gnumake", - .version = "0.0.0", - .minimum_zig_version = "0.12.0", + .name = .gnumake, + .version = "4.4.1", + .minimum_zig_version = "0.14.0", + .fingerprint = 0xeb3905f275fdb840, .dependencies = .{ .make = .{ .url = "https://ftp.gnu.org/gnu/make/make-4.4.1.tar.gz", - .hash = "12205f66cba6fc33b91195339f50617f28b1de62806ad556247e34bb3e8a7fa4c382", + .hash = "N-V-__8AAO76hQBfZsum_DO5EZUzn1Bhfyix3mKAatVWJH40", }, }, .paths = .{