diff options
-rw-r--r-- | ext/gd/config.m4 | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ext/gd/config.m4 b/ext/gd/config.m4 index 77a446008e..e58a7eb3be 100644 --- a/ext/gd/config.m4 +++ b/ext/gd/config.m4 @@ -248,9 +248,10 @@ dnl AC_TRY_COMPILE([ #include <gd.h> -], [gdIOCtx *ctx; ctx->ctx.gd_free = 1;],[], -[AC_DEFINE(HAVE_LIBGD204, 1, [ ])] -) + #include <stdlib.h> +], [gdIOCtx *ctx; ctx = malloc(sizeof(gdIOCtx)); ctx->gd_free = 1], + AC_DEFINE(HAVE_LIBGD204, 1, [ ]) +]) dnl dnl Main GD configure |