When configured with --without-ns, HAVE_NS is not defined on macOS,
thus 'memory-limit' calls the deprecated sbrk(2) function. Avoid that
by using the pre-defined __APPLE__ preprocessor macro.
* src/alloc.c (Fmemory_limit): Never use sbrk(2) on macOS.
{
Lisp_Object end;
-#if defined HAVE_NS || !HAVE_SBRK
+#if defined HAVE_NS || defined __APPLE__ || !HAVE_SBRK
/* Avoid warning. sbrk has no relation to memory allocated anyway. */
XSETINT (end, 0);
#else