Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolve macOS linker errors #4

7 changes: 4 additions & 3 deletions build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ pub fn build(b: *std.Build) !void {
test5.addCSourceFiles(.{ .root = upstream.path("src/test/examples"), .files = &.{"testlo.c"} });

const tests = [_]*std.Build.Step.Compile{ test1, test2, test3, test4, test5 };
for (tests) |t| {
inline for (tests) |t| {
t.linkLibC();
for (libs) |lib|
t.linkLibrary(lib);
Expand All @@ -280,6 +280,7 @@ const libpq_sources = .{
};

const libport_sources = .{
"explicit_bzero.c",
"getpeereid.c",
"pg_crc32c_sb8.c",
"bsearch_arg.c",
Expand Down Expand Up @@ -801,7 +802,7 @@ const autoconf_darwin = .{
.HAVE_LONG_LONG_INT_64 = null,
.HAVE_MBARRIER_H = null,
.HAVE_MBSTOWCS_L = null,
.HAVE_MEMSET_S = 1,
.HAVE_MEMSET_S = null,
.HAVE_OSSP_UUID_H = null,
.HAVE_PAM_PAM_APPL_H = null,
.HAVE_PTHREAD_IS_THREADED_NP = null,
Expand Down Expand Up @@ -837,7 +838,7 @@ const autoconf_darwin = .{
.USE_LDAP = null,
.USE_LIBXML = null,
.USE_LIBXSLT = null,
.USE_LLVM = null,
.USE_LLVM = 1,
.USE_LZ4 = null,
.USE_NAMED_POSIX_SEMAPHORES = null,
.USE_PAM = null,
Expand Down