head 1.1; access; symbols; locks; strict; comment @# @; 1.1 date 2026.07.19.11.17.42; author adam; state Exp; branches; next ; commitid FhXjPkGd9j9WSfOG; desc @@ 1.1 log @gcc15: updated to 15.3 15.3 This release is a bug-fix release, containing fixes for regressions in GCC 15.2 relative to previous releases of GCC. PkgSrc: Allow building on Darwin/aarch64. @ text @$NetBSD$ Support Darwin/aarch64. https://github.com/Homebrew/homebrew-core/blob/main/Patches/gcc/gcc-15.3.0.diff --- fixincludes/inclhack.def.orig 2026-06-12 06:09:05.643510851 +0000 +++ fixincludes/inclhack.def @@@@ -195,33 +195,6 @@@@ fix = { }; /* - * SDKs for 10.13 and 10.14 omit the definitions for API_AVAILABLE where - * __attribute__((availability)) is not supported. - */ -fix = { - hackname = darwin_api_availability; - mach = "*-*-darwin*"; - files = os/availability.h; - bypass = "__IPHONE_OS_VERSION_MIN_REQUIRED"; - select = - " *#define __API_AVAILABLE.*\n" - " *#define __API_DEPRECATED.*\n" - " *#define __API_DEPRECATED_WITH_REPLACEMENT.*\n" - " *#define __API_UNAVAILABLE.*\n"; - c_fix = format; - c_fix_arg = - " #define API_AVAILABLE(...)\n" - " #define API_DEPRECATED(...)\n" - " #define API_DEPRECATED_WITH_REPLACEMENT(...)\n" - " #define API_UNAVAILABLE(...)\n"; - test_text = - "#define __API_AVAILABLE(...)\n" - "#define __API_DEPRECATED(...)\n" - "#define __API_DEPRECATED_WITH_REPLACEMENT(...)\n" - "#define __API_UNAVAILABLE(...)\n"; -}; - -/* * This fixes __FD_ZERO bug for linux 2.x.y (x <= 2 && y <= some n) */ fix = { @@@@ -1352,32 +1325,6 @@@@ fix = { }; /* - * macOS 10.12 uses __attribute__((availability)) - * unconditionally. - */ -fix = { - hackname = darwin_availabilityinternal; - mach = "*-*-darwin*"; - files = AvailabilityInternal.h; - select = "#define[ \t]+(__API_[ADU]\\([^)]*\\)).*"; - c_fix = format; - c_fix_arg = <<- _EOFix_ - #if defined(__has_attribute) - #if __has_attribute(availability) - %0 - #else - #define %1 - #endif - #else - #define %1 - #endif - _EOFix_; - - test_text = "#define __API_A(x) __attribute__((availability(__API_AVAILABLE_PLATFORM_##x)))\n" - "#define __API_D(msg,x) __attribute__((availability(__API_DEPRECATED_PLATFORM_##x,message=msg)))"; -}; - -/* * For the AAB_darwin7_9_long_double_funcs fix (and later fixes for long long) * to be useful, the main math.h must use <> and not "" includes. */ @@@@ -4473,13 +4420,13 @@@@ fix = { /* * Arrange for stdio.h to use stdarg.h to define __gnuc_va_list. - * On 4BSD-derived systems, stdio.h defers to machine/ansi.h; that's - * OK too. + * On 4BSD-derived systems, stdio.h defers to machine/ansi.h, that's + * OK too. Modern macOS includes _stdio.h, and does not need the fix. */ fix = { hackname = stdio_stdarg_h; files = stdio.h; - bypass = "include.*(stdarg\.h|machine/ansi\.h)"; + bypass = "include.*(stdarg\.h|machine/ansi\.h|_stdio\.h)"; /* * On Solaris 10, this fix is unncessary; includes * , which includes . @@@@ -4500,12 +4447,12 @@@@ fix = { * of __gnuc_va_list, __DJ_va_list, or _G_va_list is taken to * indicate that the header knows what it's doing -- under SUSv2, * stdio.h is required to define va_list, and we shouldn't break - * that. + * that. Modern macOS includes _stdio.h, and does not need the fix. */ fix = { hackname = stdio_va_list; files = stdio.h; - bypass = '__gnuc_va_list|_BSD_VA_LIST_|__DJ_va_list|_G_va_list'; + bypass = '__gnuc_va_list|_BSD_VA_LIST_|__DJ_va_list|_G_va_list|_stdio.h'; /* * On Solaris 10, the definition in * is guarded appropriately by the _XPG4 feature macro; @