[Xquartz-changes] xserver: Branch 'for-keith' - 2 commits

Jeremy Huddleston jeremyhu at freedesktop.org
Wed Sep 28 13:32:09 PDT 2011


Rebased ref, commits from common ancestor:
commit 38e9e28ba2fbffee52ad9889ef6d4e94c7af3e10
Author: Jeremy Huddleston <jeremyhu at apple.com>
Date:   Tue Sep 20 20:39:06 2011 -0700

    XQuartz: Use set_front_process rather than X11ApplicationSetFrontProcess since we're already in the AppKit thread
    
    Signed-off-by: Jeremy Huddleston <jeremyhu at apple.com>

diff --git a/hw/xquartz/X11Application.m b/hw/xquartz/X11Application.m
index 7fd7dab..12ff53c 100644
--- a/hw/xquartz/X11Application.m
+++ b/hw/xquartz/X11Application.m
@@ -356,7 +356,7 @@ static void message_kit_thread (SEL selector, NSObject *arg) {
                          */
                         _appFlags._active = YES;
 
-                        X11ApplicationSetFrontProcess();
+                        [self set_front_process:nil];
 
                         /* Get the Spaces preference for SwitchOnActivate */
                         (void)CFPreferencesAppSynchronize(CFSTR("com.apple.dock"));
commit 206b30ebc608d29a91cc18665d89e887cac4dba3
Author: Jeremy Huddleston <jeremyhu at apple.com>
Date:   Thu Sep 22 18:55:19 2011 -0700

    Address regressions from e8ff555b95ba and d206d52f657c to work with other compilers
    
    1) The error attribute appeared in gcc-4.3
    2) The return type of __builtin_constant_p is int
    3) Sun Studio 12.0 and later builtin support for __builtin_constant_p
    
    Found by Tinderbox.
    
    Signed-off-by: Jeremy Huddleston <jeremyhu at apple.com>
    Reviewed-by: Matt Turner <mattst88 at gmail.com>
    Reviewed-by: Alan Coopersmith <alan.coopersmith at oracle.com>
    Reviewed-by: Aaron Plattner <aplattner at nvidia.com>

diff --git a/include/misc.h b/include/misc.h
index 1fea73e..0867746 100644
--- a/include/misc.h
+++ b/include/misc.h
@@ -261,14 +261,16 @@ version_compare(uint16_t a_major, uint16_t a_minor,
 #define SwapRestL(stuff) \
     SwapLongs((CARD32 *)(stuff + 1), LengthRestL(stuff))
 
-#ifdef __GNUC__
+#if defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))
 void __attribute__((error("wrong sized variable passed to swap"))) wrong_size(void);
 #else
 static inline void wrong_size(void)
 {
 }
+#endif
 
-static inline void __builtin_constant_p(int x)
+#if !(defined(__GNUC__) || (defined(__SUNPRO_C) && (__SUNPRO_C < 0x590)))
+static inline int __builtin_constant_p(int x)
 {
 	return 0;
 }


More information about the Xquartz-changes mailing list