Dan Horák <dan <at> danny.cz> writes:
> there is some clash in min/max macros/functions, but I've not done any
> detailed investigation yet, Tom has been notified.

I asked Stan Cox, who said he was using the following workaround:

On Wed, 2011-01-19 at 10:48 -0500, Stan Cox wrote:
> mysql defines min and max to be macros in my_global.h which conflicts
> with the definition of max and min in numeric_limits in <limits>.
> This use of max and min is described in the WG14 c++ standard under
> 18.3.1 Numeric limits.  Perhaps the mysql maintainers wouldn't mind
> renaming theirs to MIN/MAX.  systemtap uses the following workaround for
> the mysql build in the systemtap testsuite:
 
 # mysql erroneously defines min/max which c++ limits (via sdt.h) also defines
 sed -i -e '/HAVE_DTRACE/i\
 #pragma push_macro(\"max\")\
 #pragma push_macro(\"min\")\
 #undef max\
 #undef min' -e '/endif.*PROBES_MYSQL_H/i\
 #pragma pop_macro(\"max\")\
 #pragma pop_macro(\"min\")' ../src/include/probes_mysql.h

Hope that helps,

Mark

-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Reply via email to