From 41f5ccb496703144de14e816adb3d490186468d5 Mon Sep 17 00:00:00 2001 From: Antoine Date: Sat, 28 Sep 2024 01:03:44 +0200 Subject: [PATCH] Refactor build.zig to reduce duplication, test on apple silicon --- README.md | 5 +- build.zig | 401 ++++++++++-------------------------------------------- 2 files changed, 78 insertions(+), 328 deletions(-) diff --git a/README.md b/README.md index 7b1a774..e1d68ff 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,10 @@ Provides a package to be used by the zig package manager for C programs. ## Status -For now the only target is linux. +| Architecture \ OS | Linux | MacOS | +|:------------------|:------|-----------------| +| x86_64 | ✅ | ? | +| arm 64 | X | `-Ddisable-ssl` | Optional dependencies used by default: - openssl diff --git a/build.zig b/build.zig index bb4326d..f661749 100644 --- a/build.zig +++ b/build.zig @@ -3,15 +3,17 @@ const std = @import("std"); const version = .{ .major = 16, .minor = 4 }; const libpq_path = "src/interfaces/libpq"; -const libPQBuildErrors = error{ - OsNotSupported, - OsConfigNotCreated, -}; - pub fn build(b: *std.Build) !void { const target = b.standardTargetOptions(.{}); const optimize = b.standardOptimizeOption(.{}); + const os_header = switch (target.result.os.tag) { + .linux => "src/include/port/linux.h", + .windows => "src/include/port/win32.h", + .macos => "src/include/port/darwin.h", + else => return error.OsNotSupported, + }; + const disable_ssl = b.option(bool, "disable-ssl", "Remove OpenSSL as a dependency and disallow encrypted communications") orelse false; const disable_zlib = b.option(bool, "disable-zlib", "Remove zlib as a dependency") orelse false; const disable_zstd = b.option(bool, "disable-zstd", "Remove zstd as a dependency") orelse false; @@ -22,25 +24,10 @@ pub fn build(b: *std.Build) !void { .{ .style = .{ .autoconf = upstream.path("src/include/pg_config_ext.h.in") }, .include_path = "pg_config_ext.h" }, .{ .PG_INT64_TYPE = .@"long int" }, ); - const pg_config = switch (target.result.os.tag) { - .linux => b.addConfigHeader( - .{ .style = .{ .autoconf = upstream.path("src/include/pg_config.h.in") }, .include_path = "pg_config.h" }, - autoconf_linux, - ), - .macos => b.addConfigHeader( - .{ .style = .{ .autoconf = upstream.path("src/include/pg_config.h.in") }, .include_path = "pg_config.h" }, - autoconf_darwin, - ), - else => return libPQBuildErrors.OsConfigNotCreated, - }; - - const os_header = switch (target.result.os.tag) { - .linux => "src/include/port/linux.h", - .windows => "src/include/port/win32.h", - .macos => "src/include/port/darwin.h", - else => return libPQBuildErrors.OsNotSupported, - }; - + const pg_config = b.addConfigHeader( + .{ .style = .{ .autoconf = upstream.path("src/include/pg_config.h.in") }, .include_path = "pg_config.h" }, + autoconf, + ); const config_os = b.addConfigHeader( .{ .style = .{ .autoconf = upstream.path(os_header) }, .include_path = "pg_config_os.h" }, .{}, @@ -113,21 +100,6 @@ pub fn build(b: *std.Build) !void { }, .flags = &CFLAGS, }); - pg_config.addValues(.{ - .USE_OPENSSL = 1, - .OPENSSL_API_COMPAT = .@"0x10001000L", - .HAVE_LIBCRYPTO = 1, - .HAVE_LIBSSL = 1, - .HAVE_OPENSSL_INIT_SSL = 1, - .HAVE_SSL_CTX_SET_CERT_CB = 1, - .HAVE_SSL_CTX_SET_NUM_TICKETS = 1, - .HAVE_X509_GET_SIGNATURE_INFO = 1, - .HAVE_X509_GET_SIGNATURE_NID = 1, - .HAVE_BIO_METH_NEW = 1, - .HAVE_HMAC_CTX_FREE = 1, - .HAVE_HMAC_CTX_NEW = 1, - .HAVE_ASN1_STRING_GET0_DATA = 1, - }); } else { common.addCSourceFiles(.{ .root = upstream.path("src/common"), @@ -140,22 +112,23 @@ pub fn build(b: *std.Build) !void { }, .flags = &CFLAGS, }); - pg_config.addValues(.{ - .USE_OPENSSL = null, - .OPENSSL_API_COMPAT = null, - .HAVE_LIBCRYPTO = null, - .HAVE_LIBSSL = null, - .HAVE_OPENSSL_INIT_SSL = null, - .HAVE_SSL_CTX_SET_CERT_CB = null, - .HAVE_SSL_CTX_SET_NUM_TICKETS = null, - .HAVE_X509_GET_SIGNATURE_INFO = null, - .HAVE_X509_GET_SIGNATURE_NID = null, - .HAVE_BIO_METH_NEW = null, - .HAVE_HMAC_CTX_FREE = null, - .HAVE_HMAC_CTX_NEW = null, - .HAVE_ASN1_STRING_GET0_DATA = null, - }); } + const usessl: ?u8 = if (disable_ssl) null else 1; + pg_config.addValues(.{ + .USE_OPENSSL = usessl, + .OPENSSL_API_COMPAT = .@"0x10001000L", + .HAVE_LIBCRYPTO = usessl, + .HAVE_LIBSSL = usessl, + .HAVE_OPENSSL_INIT_SSL = usessl, + .HAVE_SSL_CTX_SET_CERT_CB = usessl, + .HAVE_SSL_CTX_SET_NUM_TICKETS = usessl, + .HAVE_X509_GET_SIGNATURE_INFO = usessl, + .HAVE_X509_GET_SIGNATURE_NID = usessl, + .HAVE_BIO_METH_NEW = usessl, + .HAVE_HMAC_CTX_FREE = usessl, + .HAVE_HMAC_CTX_NEW = usessl, + .HAVE_ASN1_STRING_GET0_DATA = usessl, + }); if (!disable_zlib) { if (b.lazyDependency("zlib", .{ .target = target, .optimize = optimize })) |zlib_dep| { @@ -164,10 +137,9 @@ pub fn build(b: *std.Build) !void { lib.linkLibrary(zlib); } } - pg_config.addValues(.{ .HAVE_LIBZ = 1 }); - } else { - pg_config.addValues(.{ .HAVE_LIBZ = null }); } + const use_z: ?u8 = if (disable_zlib) null else 1; + pg_config.addValues(.{ .HAVE_LIBZ = use_z }); if (!disable_zstd) { if (b.lazyDependency("zstd", .{ .target = target, .optimize = optimize })) |zstd_dep| { @@ -176,19 +148,15 @@ pub fn build(b: *std.Build) !void { lib.linkLibrary(zstd); } } - pg_config.addValues(.{ - .HAVE_LIBZSTD = 1, - .USE_ZSTD = 1, - }); - } else { - pg_config.addValues(.{ - .HAVE_LIBZSTD = null, - .USE_ZSTD = null, - }); } + const use_zstd: ?u8 = if (disable_zstd) null else 1; + pg_config.addValues(.{ + .HAVE_LIBZSTD = use_zstd, + .USE_ZSTD = use_zstd, + }); - // if (target.glibc_version < 2.38) // ??? - if (target.result.os.tag != .macos) { + const have_strlcat: bool = target.result.os.tag == .macos; // or linux with glibc >= 2.38, how can I test that ? + if (!have_strlcat) { libport.addCSourceFiles(.{ .root = upstream.path("src/port"), .files = &.{ @@ -197,20 +165,47 @@ pub fn build(b: *std.Build) !void { }, .flags = &CFLAGS, }); + } + const have_decl: u8 = if (have_strlcat) 1 else 0; + const have_impl: ?u8 = if (have_strlcat) 1 else null; + pg_config.addValues(.{ + .HAVE_DECL_STRLCAT = have_decl, + .HAVE_DECL_STRLCPY = have_decl, + .HAVE_STRLCAT = have_impl, + .HAVE_STRLCPY = have_impl, + }); + + const is_amd64: ?u8 = if (target.result.cpu.arch == .x86_64) 1 else null; + pg_config.addValues(.{ + .HAVE__GET_CPUID = is_amd64, + .HAVE_X86_64_POPCNTQ = is_amd64, + }); + + if (target.result.os.tag == .linux) { pg_config.addValues(.{ - .HAVE_DECL_STRLCAT = 0, - .HAVE_DECL_STRLCPY = 0, - .HAVE_STRLCAT = null, - .HAVE_STRLCPY = null, + .HAVE_EXPLICIT_BZERO = 1, + .HAVE_STRCHRNUL = 1, + .HAVE_STRERROR_R = 1, + .HAVE_STRINGS_H = 1, + .HAVE_SYNC_FILE_RANGE = 1, + .HAVE_MEMSET_S = null, + .HAVE_SYS_UCRED_H = null, }); - } else { + } else if (target.result.os.tag == .macos) { pg_config.addValues(.{ - .HAVE_DECL_STRLCAT = 1, - .HAVE_DECL_STRLCPY = 1, - .HAVE_STRLCAT = 1, - .HAVE_STRLCPY = 1, + .HAVE_EXPLICIT_BZERO = null, + .HAVE_STRCHRNUL = null, + .HAVE_STRERROR_R = null, + .HAVE_STRINGS_H = 0, + .HAVE_SYNC_FILE_RANGE = null, + .HAVE_MEMSET_S = 1, + .HAVE_SYS_UCRED_H = 1, }); - } + libport.addCSourceFile(.{ + .file = upstream.path("src/port/explicit_bzero.c"), + .flags = &CFLAGS, + }); + } else return error.ConfigUnknown; // Export public headers libpq.installHeadersDirectory( @@ -378,246 +373,7 @@ const default_paths = .{ .MANDIR = "/usr/local/pgsql/share/man", }; -const autoconf_linux = .{ - .ALIGNOF_DOUBLE = @alignOf(f64), - .ALIGNOF_INT = @alignOf(c_int), - .ALIGNOF_LONG = @alignOf(c_long), - .ALIGNOF_PG_INT128_TYPE = @alignOf(i128), - .ALIGNOF_SHORT = @alignOf(c_short), - .MAXIMUM_ALIGNOF = @alignOf(c_longlong), - - .SIZEOF_BOOL = @sizeOf(bool), - .SIZEOF_LONG = @sizeOf(c_long), - .SIZEOF_OFF_T = @sizeOf(c_long), - .SIZEOF_SIZE_T = @sizeOf(usize), - .SIZEOF_VOID_P = @sizeOf(*void), - - .BLCKSZ = 8192, - .CONFIGURE_ARGS = " '--with-ssl=openssl' 'CC=zig cc' 'CXX=zig c++'", - .DEF_PGPORT = 5432, - .DEF_PGPORT_STR = "5432", - .DLSUFFIX = ".so", - .ENABLE_THREAD_SAFETY = 1, - .HAVE_APPEND_HISTORY = 1, - .HAVE_ATOMICS = 1, - .HAVE_BACKTRACE_SYMBOLS = 1, - .HAVE_COMPUTED_GOTO = 1, - .HAVE_DECL_FDATASYNC = 1, - .HAVE_DECL_F_FULLFSYNC = 0, - .HAVE_DECL_POSIX_FADVISE = 1, - .HAVE_DECL_PREADV = 1, - .HAVE_DECL_PWRITEV = 1, - .HAVE_DECL_STRNLEN = 1, - .HAVE_EXECINFO_H = 1, - .HAVE_EXPLICIT_BZERO = 1, - .HAVE_FSEEKO = 1, - .HAVE_GCC__ATOMIC_INT32_CAS = 1, - .HAVE_GCC__ATOMIC_INT64_CAS = 1, - .HAVE_GCC__SYNC_CHAR_TAS = 1, - .HAVE_GCC__SYNC_INT32_CAS = 1, - .HAVE_GCC__SYNC_INT32_TAS = 1, - .HAVE_GCC__SYNC_INT64_CAS = 1, - .HAVE_GETIFADDRS = 1, - .HAVE_GETOPT = 1, - .HAVE_GETOPT_H = 1, - .HAVE_GETOPT_LONG = 1, - .HAVE_HISTORY_TRUNCATE_FILE = 1, - .HAVE_IFADDRS_H = 1, - .HAVE_INET_ATON = 1, - .HAVE_INET_PTON = 1, - .HAVE_INTTYPES_H = 1, - .HAVE_INT_OPTERR = 1, - .HAVE_INT_TIMEZONE = 1, - .HAVE_LANGINFO_H = 1, - .HAVE_LIBM = 1, - .HAVE_LIBREADLINE = 1, - .HAVE_LOCALE_T = 1, - .HAVE_LONG_INT_64 = 1, - .HAVE_MEMORY_H = 1, - .HAVE_MKDTEMP = 1, - .HAVE_POSIX_FADVISE = 1, - .HAVE_POSIX_FALLOCATE = 1, - .HAVE_PPOLL = 1, - .HAVE_PTHREAD = 1, - .HAVE_PTHREAD_BARRIER_WAIT = 1, - .HAVE_PTHREAD_PRIO_INHERIT = 1, - .HAVE_READLINE_HISTORY_H = 1, - .HAVE_READLINE_READLINE_H = 1, - .HAVE_RL_COMPLETION_MATCHES = 1, - .HAVE_RL_COMPLETION_SUPPRESS_QUOTE = 1, - .HAVE_RL_FILENAME_COMPLETION_FUNCTION = 1, - .HAVE_RL_FILENAME_QUOTE_CHARACTERS = 1, - .HAVE_RL_FILENAME_QUOTING_FUNCTION = 1, - .HAVE_RL_RESET_SCREEN_SIZE = 1, - .HAVE_RL_VARIABLE_BIND = 1, - .HAVE_SOCKLEN_T = 1, - .HAVE_SPINLOCKS = 1, - .HAVE_STDBOOL_H = 1, - .HAVE_STDINT_H = 1, - .HAVE_STDLIB_H = 1, - .HAVE_STRCHRNUL = 1, - .HAVE_STRERROR_R = 1, - .HAVE_STRINGS_H = 1, - .HAVE_STRING_H = 1, - .HAVE_STRNLEN = 1, - .HAVE_STRSIGNAL = 1, - .HAVE_STRUCT_OPTION = 1, - .HAVE_STRUCT_TM_TM_ZONE = 1, - .HAVE_SYNCFS = 1, - .HAVE_SYNC_FILE_RANGE = 1, - .HAVE_SYSLOG = 1, - .HAVE_SYS_EPOLL_H = 1, - .HAVE_SYS_PERSONALITY_H = 1, - .HAVE_SYS_PRCTL_H = 1, - .HAVE_SYS_SIGNALFD_H = 1, - .HAVE_SYS_STAT_H = 1, - .HAVE_SYS_TYPES_H = 1, - .HAVE_TERMIOS_H = 1, - .HAVE_TYPEOF = 1, - .HAVE_UNISTD_H = 1, - .HAVE_USELOCALE = 1, - .HAVE_VISIBILITY_ATTRIBUTE = 1, - .HAVE_X86_64_POPCNTQ = 1, - .HAVE__BOOL = 1, - .HAVE__BUILTIN_BSWAP16 = 1, - .HAVE__BUILTIN_BSWAP32 = 1, - .HAVE__BUILTIN_BSWAP64 = 1, - .HAVE__BUILTIN_CLZ = 1, - .HAVE__BUILTIN_CONSTANT_P = 1, - .HAVE__BUILTIN_CTZ = 1, - .HAVE__BUILTIN_FRAME_ADDRESS = 1, - .HAVE__BUILTIN_OP_OVERFLOW = 1, - .HAVE__BUILTIN_POPCOUNT = 1, - .HAVE__BUILTIN_TYPES_COMPATIBLE_P = 1, - .HAVE__BUILTIN_UNREACHABLE = 1, - .HAVE__GET_CPUID = 1, - .HAVE__STATIC_ASSERT = 1, - .MEMSET_LOOP_LIMIT = 1024, - .PG_INT128_TYPE = .__int128, - .PG_INT64_TYPE = .@"long int", - .PG_KRB_SRVNAM = "postgres", - .PG_PRINTF_ATTRIBUTE = .printf, - .INT64_MODIFIER = "l", - .PG_USE_STDBOOL = 1, - .PG_VERSION_NUM = version.major * 10000 + version.minor, - .RELSEG_SIZE = 131072, - .STDC_HEADERS = 1, - .USE_ICU = 1, - .USE_SLICING_BY_8_CRC32C = 1, - .USE_SYSV_SHARED_MEMORY = 1, - .USE_UNNAMED_POSIX_SEMAPHORES = 1, - .XLOG_BLCKSZ = 8192, - .pg_restrict = .__restrict, - .restrict = .__restrict, - - .PACKAGE_BUGREPORT = "pgsql-bugs@lists.postgresql.org", - .PACKAGE_NAME = "PostgreSQL", - .PACKAGE_STRING = std.fmt.comptimePrint("PostgreSQL {}.{}", .{ version.major, version.minor }), - .PACKAGE_TARNAME = "postgresql", - .PACKAGE_URL = "https://www.postgresql.org/", - .PACKAGE_VERSION = std.fmt.comptimePrint("{}.{}", .{ version.major, version.minor }), - - .PG_MAJORVERSION_NUM = version.major, - .PG_MINORVERSION_NUM = version.minor, - .PG_MAJORVERSION = std.fmt.comptimePrint("{}", .{version.major}), - .PG_VERSION = std.fmt.comptimePrint("{}.{}", .{ version.major, version.minor }), - .PG_VERSION_STR = std.fmt.comptimePrint("PostgreSQL {}.{}", .{ version.major, version.minor }), - - .AC_APPLE_UNIVERSAL_BUILD = null, - .ALIGNOF_LONG_LONG_INT = null, - .ENABLE_GSS = null, - .ENABLE_NLS = null, - .HAVE_ATOMIC_H = null, - .HAVE_COPYFILE = null, - .HAVE_COPYFILE_H = null, - .HAVE_CRTDEFS_H = null, - .HAVE_CRYPTO_LOCK = null, - .HAVE_DECL_LLVMCREATEGDBREGISTRATIONLISTENER = null, - .HAVE_DECL_LLVMCREATEPERFJITEVENTLISTENER = null, - .HAVE_DECL_LLVMGETHOSTCPUFEATURES = null, - .HAVE_DECL_LLVMGETHOSTCPUNAME = null, - .HAVE_DECL_LLVMORCGETSYMBOLADDRESSIN = null, - .HAVE_EDITLINE_HISTORY_H = null, - .HAVE_EDITLINE_READLINE_H = null, - .HAVE_GETPEEREID = null, - .HAVE_GETPEERUCRED = null, - .HAVE_GSSAPI_EXT_H = null, - .HAVE_GSSAPI_GSSAPI_EXT_H = null, - .HAVE_GSSAPI_GSSAPI_H = null, - .HAVE_GSSAPI_H = null, - .HAVE_HISTORY_H = null, - .HAVE_INT64 = null, - .HAVE_INT8 = null, - .HAVE_INT_OPTRESET = null, - .HAVE_I_CONSTRAINT__BUILTIN_CONSTANT_P = null, - .HAVE_KQUEUE = null, - .HAVE_LDAP_INITIALIZE = null, - .HAVE_LIBLDAP = null, - .HAVE_LIBLZ4 = null, - .HAVE_LIBPAM = null, - .HAVE_LIBSELINUX = null, - .HAVE_LIBWLDAP32 = null, - .HAVE_LIBXML2 = null, - .HAVE_LIBXSLT = null, - .HAVE_LONG_LONG_INT_64 = null, - .HAVE_MBARRIER_H = null, - .HAVE_MBSTOWCS_L = null, - .HAVE_MEMSET_S = null, - .HAVE_OSSP_UUID_H = null, - .HAVE_PAM_PAM_APPL_H = null, - .HAVE_PTHREAD_IS_THREADED_NP = null, - .HAVE_READLINE_H = null, - .HAVE_SECURITY_PAM_APPL_H = null, - .HAVE_SETPROCTITLE = null, - .HAVE_SETPROCTITLE_FAST = null, - .HAVE_STRUCT_SOCKADDR_SA_LEN = null, - .HAVE_SYS_EVENT_H = null, - .HAVE_SYS_PROCCTL_H = null, - .HAVE_SYS_UCRED_H = null, - .HAVE_UCRED_H = null, - .HAVE_UINT64 = null, - .HAVE_UINT8 = null, - .HAVE_UNION_SEMUN = null, - .HAVE_UUID_BSD = null, - .HAVE_UUID_E2FS = null, - .HAVE_UUID_H = null, - .HAVE_UUID_OSSP = null, - .HAVE_UUID_UUID_H = null, - .HAVE_WCSTOMBS_L = null, - .HAVE__CONFIGTHREADLOCALE = null, - .HAVE__CPUID = null, - .LOCALE_T_IN_XLOCALE = null, - .PROFILE_PID_DIR = null, - .PTHREAD_CREATE_JOINABLE = null, - .STRERROR_R_INT = null, // 1 if not _GNU_SOURCE - .USE_ARMV8_CRC32C = null, - .USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK = null, - .USE_ASSERT_CHECKING = null, - .USE_BONJOUR = null, - .USE_BSD_AUTH = null, - .USE_LDAP = null, - .USE_LIBXML = null, - .USE_LIBXSLT = null, - .USE_LLVM = null, - .USE_LZ4 = null, - .USE_NAMED_POSIX_SEMAPHORES = null, - .USE_PAM = null, - .USE_SSE42_CRC32C = null, - .USE_SSE42_CRC32C_WITH_RUNTIME_CHECK = null, - .USE_SYSTEMD = null, - .USE_SYSV_SEMAPHORES = null, - .USE_WIN32_SEMAPHORES = null, - .USE_WIN32_SHARED_MEMORY = null, - .WCSTOMBS_L_IN_XLOCALE = null, - .WORDS_BIGENDIAN = null, - ._FILE_OFFSET_BITS = null, - ._LARGEFILE_SOURCE = null, - ._LARGE_FILES = null, - .@"inline" = null, - .typeof = null, -}; - -const autoconf_darwin = .{ +const autoconf = .{ .ALIGNOF_DOUBLE = @alignOf(f64), .ALIGNOF_INT = @alignOf(c_int), .ALIGNOF_LONG = @alignOf(c_long), @@ -648,7 +404,6 @@ const autoconf_darwin = .{ .HAVE_DECL_PWRITEV = 1, .HAVE_DECL_STRNLEN = 1, .HAVE_EXECINFO_H = 1, - .HAVE_EXPLICIT_BZERO = null, .HAVE_FSEEKO = 1, .HAVE_GCC__ATOMIC_INT32_CAS = 1, .HAVE_GCC__ATOMIC_INT64_CAS = 1, @@ -694,16 +449,12 @@ const autoconf_darwin = .{ .HAVE_STDBOOL_H = 1, .HAVE_STDINT_H = 1, .HAVE_STDLIB_H = 1, - .HAVE_STRCHRNUL = null, - .HAVE_STRERROR_R = null, - .HAVE_STRINGS_H = 0, .HAVE_STRING_H = 1, .HAVE_STRNLEN = 1, .HAVE_STRSIGNAL = 1, .HAVE_STRUCT_OPTION = 1, .HAVE_STRUCT_TM_TM_ZONE = 1, .HAVE_SYNCFS = 1, - .HAVE_SYNC_FILE_RANGE = null, .HAVE_SYSLOG = 1, .HAVE_SYS_EPOLL_H = 1, .HAVE_SYS_PERSONALITY_H = 1, @@ -716,7 +467,6 @@ const autoconf_darwin = .{ .HAVE_UNISTD_H = 1, .HAVE_USELOCALE = 1, .HAVE_VISIBILITY_ATTRIBUTE = 1, - .HAVE_X86_64_POPCNTQ = 1, .HAVE__BOOL = 1, .HAVE__BUILTIN_BSWAP16 = 1, .HAVE__BUILTIN_BSWAP32 = 1, @@ -729,7 +479,6 @@ const autoconf_darwin = .{ .HAVE__BUILTIN_POPCOUNT = 1, .HAVE__BUILTIN_TYPES_COMPATIBLE_P = 1, .HAVE__BUILTIN_UNREACHABLE = 1, - .HAVE__GET_CPUID = 1, .HAVE__STATIC_ASSERT = 1, .MEMSET_LOOP_LIMIT = 1024, .PG_INT128_TYPE = .__int128, @@ -801,7 +550,6 @@ const autoconf_darwin = .{ .HAVE_LONG_LONG_INT_64 = null, .HAVE_MBARRIER_H = null, .HAVE_MBSTOWCS_L = null, - .HAVE_MEMSET_S = 1, .HAVE_OSSP_UUID_H = null, .HAVE_PAM_PAM_APPL_H = null, .HAVE_PTHREAD_IS_THREADED_NP = null, @@ -812,7 +560,6 @@ const autoconf_darwin = .{ .HAVE_STRUCT_SOCKADDR_SA_LEN = null, .HAVE_SYS_EVENT_H = null, .HAVE_SYS_PROCCTL_H = null, - .HAVE_SYS_UCRED_H = 1, .HAVE_UCRED_H = null, .HAVE_UINT64 = null, .HAVE_UINT8 = null,