[Spice-devel] [PATCH spice-gtk v7 0/4] Repair macOS builds for spice-gtk

Christophe de Dinechin christophe at dinechin.org
Thu Jun 8 07:49:07 UTC 2017


From: Christophe de Dinechin <dinechin at redhat.com>

This patch set contains various fixes that repair macOS builds for
spice-gtk (and presumably clang builds as a side effect), notably:

- Fixes for clang-specific warnings, notably on alignment
- Addition of macOS detection in configure script
- A couple minor portablity fixes

This requires an update to spice-common, see
https://lists.freedesktop.org/archives/spice-devel/2017-May/037505.html.
The reference to submodule  in this patch serie is updated with a
reference that can be fetched from https://github.com/c3d/spice-common.git.

Version 2 takes into account comments by Frediano Ziglio and Pavel Grunt,
specifically:

- Clarify purpose and behavior of macros in patch commit message
- Change one case to 'unaligned'
- Improve way to avoid 'unused variable' warning

Acked by: Christophe Fergeau <cfergeau at redhat.com>

Version 3 takes into account comments made by Christophe Fergeau in
his ack message, specifically:

- Improve the log message description of SPICE_(UN)ALIGNED_CAST.
  Hopefully the new one is better.

- Make spaces after commas consistent

In addition, v3 re-enables ucontext on macOS, following comments
that this is the right thing to do for performance. This required the
elimination of one more alignment warning.

Version 4 takes into account comments made by Pavel and Frediano,
specifically:

- Reorder the previous iteration to group things more logically
- Add a TODO comment for macOS in set_mouse_accel

Version 5 adds the --enable-alignment-checks configuration option
and disables all runtime checks by default.

Version 6 groups the --enable-alignment-checks configuration option
with the warning detection, and addresses some of the alignment issues
as discussed with Frediano.

Version 7 modifies some comments (nits reported by Christophe Fergeau),
fixes a bogus array size change I had made earlier (seen by Frediano Ziglio),
and takes into account one additional cast introduced in master lately.

Christophe de Dinechin (4):
  Add check for macOS and macOS specific define to allow ucontext
  Avoid clang warnings on casts with stricter alignment requirements
  Remove warning about unused variable when building on macOS
  Address alignment warnings detected by clang

 configure.ac                | 23 +++++++++++++++++++++++
 spice-common                |  2 +-
 src/channel-cursor.c        |  6 ++++--
 src/channel-display-mjpeg.c |  2 +-
 src/channel-main.c          |  2 +-
 src/continuation.h          |  6 ++++--
 src/decode-glz-tmpl.c       |  2 +-
 src/spice-channel.c         | 26 ++++++++++++++++----------
 src/spice-widget.c          |  7 ++++---
 9 files changed, 55 insertions(+), 21 deletions(-)

-- 
2.11.0 (Apple Git-81)



More information about the Spice-devel mailing list