cedric pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=d00643fcc4ebe2de3d9abf21edd0a7f55d99972c

commit d00643fcc4ebe2de3d9abf21edd0a7f55d99972c
Author: Cedric BAIL <[email protected]>
Date:   Mon May 9 16:56:38 2016 -0700

    eina: add MIN/MAX redefine as we use it everywhere.
    
    This is done on an attempt to permanently fix our Windows port. Windows
    doesn't have MIN/MAX, so we should always do a ifndef/define in every
    piece of code that use it. Of course we always forget and it take times
    to notice and fix. We have over the year added it in many private
    headers, but as the issue continue to raise again and again, I prefer
    to get this fixed in our main header.
---
 src/lib/eina/eina_cpu.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/src/lib/eina/eina_cpu.h b/src/lib/eina/eina_cpu.h
index bb7082b..e97d614 100644
--- a/src/lib/eina/eina_cpu.h
+++ b/src/lib/eina/eina_cpu.h
@@ -122,6 +122,14 @@ static inline unsigned int eina_swap32(unsigned int x);
  */
 static inline unsigned long long eina_swap64(unsigned long long x);
 
+#ifndef MIN
+# define MIN(x, y)          (((x) > (y)) ? (y) : (x))
+#endif
+
+#ifndef MAX
+# define MAX(x, y)          (((x) > (y)) ? (x) : (y))
+#endif
+
 #include "eina_inline_cpu.x"
 
 /**

-- 


Reply via email to