[Mesa-dev] [PATCH] Fix compilation on cygwin after commit 762c9766c93697af8d7fbaa729aed118789dbe8e

2011-12-19 Thread Jon TURNEY
Fix compilation on cygwin after commit 762c9766c93697af8d7fbaa729aed118789dbe8e
Use VERT_ATTRIB_* indexed array in gl_array_object added the first non-driver
use of ffsll(), which exposes the fact that this isn't provided on cygwin.

Found by tinderbox, see [1]

[1] http://tinderbox.freedesktop.org/builds/2011-11-30-0017/logs/libGL/#build

Signed-off-by: Jon TURNEY jon.tur...@dronecode.org.uk
---
 src/mesa/main/imports.h |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/mesa/main/imports.h b/src/mesa/main/imports.h
index 797f357..d5e3859 100644
--- a/src/mesa/main/imports.h
+++ b/src/mesa/main/imports.h
@@ -568,7 +568,7 @@ _mesa_init_sqrt_table(void);
 
 #ifdef __GNUC__
 
-#if defined(__MINGW32__) || defined(ANDROID)
+#if defined(__MINGW32__) || defined(__CYGWIN__) || defined(ANDROID)
 #define ffs __builtin_ffs
 #define ffsll __builtin_ffsll
 #endif
-- 
1.7.5.1

___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev


Re: [Mesa-dev] [PATCH] Fix compilation on cygwin after commit 762c9766c93697af8d7fbaa729aed118789dbe8e

2011-12-19 Thread Brian Paul

On 12/19/2011 10:45 AM, Jon TURNEY wrote:

Fix compilation on cygwin after commit 762c9766c93697af8d7fbaa729aed118789dbe8e
Use VERT_ATTRIB_* indexed array in gl_array_object added the first non-driver
use of ffsll(), which exposes the fact that this isn't provided on cygwin.

Found by tinderbox, see [1]

[1] http://tinderbox.freedesktop.org/builds/2011-11-30-0017/logs/libGL/#build

Signed-off-by: Jon TURNEYjon.tur...@dronecode.org.uk
---
  src/mesa/main/imports.h |2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/mesa/main/imports.h b/src/mesa/main/imports.h
index 797f357..d5e3859 100644
--- a/src/mesa/main/imports.h
+++ b/src/mesa/main/imports.h
@@ -568,7 +568,7 @@ _mesa_init_sqrt_table(void);

  #ifdef __GNUC__

-#if defined(__MINGW32__) || defined(ANDROID)
+#if defined(__MINGW32__) || defined(__CYGWIN__) || defined(ANDROID)
  #define ffs __builtin_ffs
  #define ffsll __builtin_ffsll
  #endif


LGTM.


Reviewed-by: Brian Paul bri...@vmware.com
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev