Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/config.h.in b/config.h.in
- index ef62766..f21295d 100644
- --- a/config.h.in
- +++ b/config.h.in
- @@ -177,6 +177,9 @@
- /* Define to 1 if you have the <string.h> header file. */
- #undef HAVE_STRING_H
- +/* strlcpy */
- +#undef HAVE_STRLCPY
- +
- /* strptime */
- #undef HAVE_STRPTIME
- diff --git a/configure b/configure
- index 9354bbd..1563778 100755
- --- a/configure
- +++ b/configure
- @@ -25136,7 +25136,11 @@ fi
- echo "$as_me:$LINENO: result: $ac_cv_func_strlcpy" >&5
- echo "${ECHO_T}$ac_cv_func_strlcpy" >&6
- if test $ac_cv_func_strlcpy = yes; then
- - :
- +
- +cat >>confdefs.h <<\_ACEOF
- +#define HAVE_STRLCPY 1
- +_ACEOF
- +
- else
- aclo_strlcpy=yes;
- HXDLIBLDADD="$HXDLIBLDADD ../lib/strlcpy.o";
- diff --git a/configure.in b/configure.in
- index 5bca77e..5d124cb 100644
- --- a/configure.in
- +++ b/configure.in
- @@ -768,7 +768,8 @@ if test "$ac_cv_coreservices" = "yes"; then
- HXLDFLAGS="$HXLDFLAGS -framework coreservices"
- fi
- -AC_CHECK_FUNC(strlcpy, , aclo_strlcpy=yes;
- +AC_CHECK_FUNC(strlcpy, AC_DEFINE(HAVE_STRLCPY, 1, [strlcpy]),
- + aclo_strlcpy=yes;
- HXDLIBLDADD="$HXDLIBLDADD ../lib/strlcpy.o";
- HXTRACKDLIBLDADD="$HXTRACKDLIBLDADD ../lib/strlcpy.o";
- HXLIBLDADD="$HXLIBLDADD ../lib/strlcpy.o")
- diff --git a/src/apple/api.h b/src/apple/api.h
- index 62eb52c..a25ea0d 100644
- --- a/src/apple/api.h
- +++ b/src/apple/api.h
- @@ -12,6 +12,26 @@
- /* system includes */
- #ifdef HAVE_CORESERVICES
- +/*
- + * Mac OS X 14 (Sonoma) has vector-literal compile-time errors. Avoid
- + * including all of CoreServices and instead piece-meal include elements
- + * directly from CarbonCore framework.
- + *
- + * However, it seems Sonoma did not bump __MAC_OS_X_VERSION_MIN_REQUIRED
- + * and while it should be something like 140000+ in Mac OS X 14.0+, what I am
- + * observing is that Mac OS X 14.3 (for example) thinks it is 13.1.
- + *
- + * We'll just have to piece-meal include on any Mac OS X later than 13.0 while
- + * continuing to perform legacy whole-framework inclusion on 13.1+.
- + */
- +#if __MAC_OS_X_VERSION_MIN_REQUIRED < __MAC_13_1
- #include <CoreServices/CoreServices.h>
- +#else
- +#include <MacTypes.h>
- +#include <CoreServices/../Frameworks/CarbonCore.framework/Headers/Files.h>
- +#include <CoreServices/../Frameworks/CarbonCore.framework/Headers/Aliases.h>
- +#include <CoreServices/../Frameworks/CarbonCore.framework/Headers/Resources.h>
- +#include <CoreServices/../Frameworks/CarbonCore.framework/Headers/UnicodeConverter.h>
- +#endif
- #endif
- diff --git a/src/common/hxd.c b/src/common/hxd.c
- index 726b03b..273a2c0 100644
- --- a/src/common/hxd.c
- +++ b/src/common/hxd.c
- @@ -106,7 +106,7 @@ inaddr2str (char abuf[HOSTLEN+1], struct SOCKADDR_IN *sa)
- #ifdef CONFIG_IPV6
- inet_ntop(AFINET, (char *)&sa->SIN_ADDR, abuf, HOSTLEN+1);
- #else
- - inet_ntoa(sa->SIN_ADDR, abuf, 16);
- + inet_ntoa_r(sa->SIN_ADDR, abuf, 16);
- #endif
- }
- diff --git a/src/hxd/htxf.c b/src/hxd/htxf.c
- index 52db133..b6f9a2a 100644
- --- a/src/hxd/htxf.c
- +++ b/src/hxd/htxf.c
- @@ -16,6 +16,9 @@
- #if defined(CONFIG_HFS)
- #include "hfs.h"
- #endif
- +#if defined(HAVE_CORESERVICES)
- +#include "apple/alias.h"
- +#endif
- #include "threads.h"
- #define HTXF_BUFSIZE 0xf000
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement