Files
macports-ports/graphics/libxmi/files/patch-missing-stdlib.diff
Michael LassandKen d9b58e3696 libxmi: fix missing includes of stdlib.h
Without this patch, build fails on macOS 11 Big Sur.
2020-12-24 23:57:05 -08:00

24 lines
500 B
Diff

--- mi_alloc.c
+++ mi_alloc.c
@@ -9,6 +9,8 @@
#include "mi_spans.h"
#include "mi_api.h"
+#include <stdlib.h>
+
/* wrapper for malloc() */
voidptr_t
#ifdef _HAVE_PROTOS
--- mi_arc.c
+++ mi_arc.c
@@ -29,6 +29,8 @@
#include "mi_fply.h" /* for miFillSppPoly() */
#include "mi_fllarc.h" /* for MIWIDEARCSETUP, MIFILLINARCSTEP etc. */
+#include <stdlib.h>
+
/* undefine if cbrt(), a fast cube root function for non-negative
arguments, is available */
#define cbrt(x) pow((x), 1.0/3.0)