diff --git a/configure.ac b/configure.ac index 9985cdcbf8a0..12cb4b9bb33d 100644 --- a/configure.ac +++ b/configure.ac @@ -1180,9 +1180,6 @@ m4_define([FRR_INCLUDES], /* Required for MAXSIG */ #include #include -#ifdef __APPLE__ -# define __APPLE_USE_RFC_3542 -#endif #include #include #include diff --git a/lib/event.c b/lib/event.c index d3bc0205ae98..4121c0a448ce 100644 --- a/lib/event.c +++ b/lib/event.c @@ -55,11 +55,6 @@ static int event_timer_cmp(const struct event *a, const struct event *b) DECLARE_HEAP(event_timer_list, struct event, timeritem, event_timer_cmp); -#if defined(__APPLE__) -#include -#include -#endif - #define AWAKEN(m) \ do { \ const unsigned char wakebyte = 0x01; \ diff --git a/lib/ntop.c b/lib/ntop.c index 49e1b152c931..89b4d5ecdcab 100644 --- a/lib/ntop.c +++ b/lib/ntop.c @@ -158,7 +158,7 @@ const char *frr_inet_ntop(int af, const void * restrict src, return dst; } -#if !defined(INET_NTOP_NO_OVERRIDE) && !defined(__APPLE__) +#if !defined(INET_NTOP_NO_OVERRIDE) /* we want to override libc inet_ntop, but make sure it shows up in backtraces * as frr_inet_ntop (to avoid confusion while debugging) */ diff --git a/lib/sockopt.c b/lib/sockopt.c index 0c4adb0b7c22..ed681710e5c7 100644 --- a/lib/sockopt.c +++ b/lib/sockopt.c @@ -10,13 +10,12 @@ #include "sockunion.h" #include "lib_errors.h" -#if (defined(__FreeBSD__) \ - && ((__FreeBSD_version >= 500022 && __FreeBSD_version < 700000) \ - || (__FreeBSD_version < 500000 && __FreeBSD_version >= 440000))) \ - || (defined(__NetBSD__) && defined(__NetBSD_Version__) \ - && __NetBSD_Version__ >= 106010000) \ - || defined(__OpenBSD__) || defined(__APPLE__) \ - || defined(__DragonFly__) || defined(__sun) +#if (defined(__FreeBSD__) && \ + ((__FreeBSD_version >= 500022 && __FreeBSD_version < 700000) || \ + (__FreeBSD_version < 500000 && __FreeBSD_version >= 440000))) || \ + (defined(__NetBSD__) && defined(__NetBSD_Version__) && \ + __NetBSD_Version__ >= 106010000) || \ + defined(__OpenBSD__) || defined(__DragonFly__) || defined(__sun) #define HAVE_BSD_STRUCT_IP_MREQ_HACK #endif diff --git a/lib/zebra.h b/lib/zebra.h index 3fe61c801ee1..378ccd84d011 100644 --- a/lib/zebra.h +++ b/lib/zebra.h @@ -76,10 +76,6 @@ #include #endif /* HAVE_SYS_SOCKIO_H */ -#ifdef __APPLE__ -#define __APPLE_USE_RFC_3542 -#endif - #ifndef HAVE_LIBCRYPT #ifdef HAVE_LIBCRYPTO #include @@ -280,10 +276,9 @@ struct in_pktinfo { * OpenBSD: network byte order, apart from older versions which are as per * *BSD */ -#if defined(__NetBSD__) \ - || (defined(__FreeBSD__) && (__FreeBSD_version < 1100030)) \ - || (defined(__OpenBSD__) && (OpenBSD < 200311)) \ - || (defined(__APPLE__)) +#if defined(__NetBSD__) || \ + (defined(__FreeBSD__) && (__FreeBSD_version < 1100030)) || \ + (defined(__OpenBSD__) && (OpenBSD < 200311)) #define HAVE_IP_HDRINCL_BSD_ORDER #endif diff --git a/lib/zlog.c b/lib/zlog.c index 309a955fa90a..2a6189573fe7 100644 --- a/lib/zlog.c +++ b/lib/zlog.c @@ -32,9 +32,6 @@ #ifdef __DragonFly__ #include #endif -#ifdef __APPLE__ -#include -#endif #ifdef HAVE_LIBUNWIND #define UNW_LOCAL_ONLY diff --git a/zebra/kernel_socket.c b/zebra/kernel_socket.c index d897f4a1df2d..62adbc0c3e8a 100644 --- a/zebra/kernel_socket.c +++ b/zebra/kernel_socket.c @@ -48,11 +48,7 @@ extern struct zebra_privs_t zserv_privs; * 0). We follow this practice without questioning it, but it is a * bug if frr calls ROUNDUP with 0. */ -#ifdef __APPLE__ -#define ROUNDUP_TYPE int -#else -#define ROUNDUP_TYPE long -#endif +#define ROUNDUP_TYPE long /* * Because of these varying conventions, the only sane approach is for