From: Bruno Haible Date: Sat, 17 Oct 2020 19:55:47 +0000 (+0200) Subject: Fix "warning: 'max' macro redefined". X-Git-Tag: v0.21.1~40 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ca4252280333b3e248c98f19f11dee76124a1e9d;p=thirdparty%2Fgettext.git Fix "warning: 'max' macro redefined". * gettext-tools/src/x-javascript.c (max): Undefine first. * gettext-tools/src/x-python.c (max): Likewise. --- diff --git a/gettext-tools/src/x-javascript.c b/gettext-tools/src/x-javascript.c index 7545adafb..3f2e2ac7e 100644 --- a/gettext-tools/src/x-javascript.c +++ b/gettext-tools/src/x-javascript.c @@ -56,6 +56,7 @@ #define _(s) gettext(s) +#undef max /* clean up after MSVC's */ #define max(a,b) ((a) > (b) ? (a) : (b)) #define SIZEOF(a) (sizeof(a) / sizeof(a[0])) diff --git a/gettext-tools/src/x-python.c b/gettext-tools/src/x-python.c index 4c95797f7..d7ac26f77 100644 --- a/gettext-tools/src/x-python.c +++ b/gettext-tools/src/x-python.c @@ -57,6 +57,7 @@ #define _(s) gettext(s) +#undef max /* clean up after MSVC's */ #define max(a,b) ((a) > (b) ? (a) : (b)) #define SIZEOF(a) (sizeof(a) / sizeof(a[0]))