-
-
Notifications
You must be signed in to change notification settings - Fork 169
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
git-svn-id: https://xpra.org/svn/Xpra/trunk@17918 3bb7dfac-3a0b-4e04-842a-767bc560f471
- Loading branch information
Showing
1 changed file
with
97 additions
and
278 deletions.
There are no files selected for viewing
375 changes: 97 additions & 278 deletions
375
osx/jhbuild/patches/0001-Bug747146-Build-cocoanotification-only-if-supported.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,279 +1,98 @@ | ||
<?xml version="1.0"?><!--*- mode: nxml; indent-tabs-mode: nil -*--> | ||
<!DOCTYPE moduleset SYSTEM "moduleset.dtd"> | ||
<?xml-stylesheet type="text/xsl" href="moduleset.xsl"?> | ||
<moduleset> | ||
<repository type="tarball" name="ftp.gnome.org" default="yes" | ||
href="http://ftp.gnome.org/pub/GNOME/sources/"/> | ||
<repository type="tarball" name="sourceforge" | ||
href="http://downloads.sourceforge.net/sourceforge/"/> | ||
<repository type="tarball" name="cairographics" | ||
href="http://cairographics.org/releases/"/> | ||
<repository type="tarball" name="ftp.gnu.org" | ||
href="http://ftp.gnu.org/gnu/"/> | ||
<repository type="tarball" name="sourceware.org" | ||
href="ftp://sourceware.org/pub/"/> | ||
<repository type="tarball" name="freedesktop" | ||
href="ftp://ftp.freedesktop.org/pub/"/> | ||
<repository type="git" name="github" href="git://github.com/"/> | ||
From 8003b800f63590d52b9b436f62337bc709c0f951 Mon Sep 17 00:00:00 2001 | ||
From: John Ralls <[email protected]> | ||
Date: Fri, 26 Feb 2016 14:16:46 -0800 | ||
Subject: [PATCH] Enable building gcocoanotification only if OS X min version | ||
>= 10.9. | ||
|
||
--- | ||
configure.ac | 19 ++++++++----------- | ||
gio/Makefile.am | 2 ++ | ||
gio/giomodule.c | 8 ++++++-- | ||
3 files changed, 16 insertions(+), 13 deletions(-) | ||
|
||
diff --git a/configure.ac b/configure.ac | ||
index 603f621..20c640b 100644 | ||
--- a/configure.ac | ||
+++ b/configure.ac | ||
@@ -221,22 +221,19 @@ AS_IF([test "x$glib_have_carbon" = "xyes"], [ | ||
], [CARBON_LIBS=""]) | ||
|
||
AC_SUBST([CARBON_LIBS]) | ||
- | ||
+ac_cv_have_os_x_9_or_later="no" | ||
AS_IF([test "x$glib_have_cocoa" = "xyes"], [ | ||
AC_DEFINE(HAVE_COCOA, 1, [define to 1 if Cocoa is available]) | ||
COCOA_LIBS="-Wl,-framework,Foundation" | ||
LDFLAGS="$LDFLAGS $COCOA_LIBS" | ||
- | ||
- osx_version=`sw_vers -productVersion` | ||
- osx_min_version="10.9.0" | ||
- AC_MSG_CHECKING([OSX version >= $osx_min_version]) | ||
- AS_VERSION_COMPARE([$osx_version], [$osx_min_version], [ | ||
- AC_MSG_RESULT([no]) | ||
- AC_MSG_ERROR([OSX version is too old!]) | ||
- ]) | ||
- AC_MSG_RESULT([yes]) | ||
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ | ||
+#include <AvailabilityMacros.h> | ||
+#if MAC_OS_X_VERSION_MIN_REQUIRED < 1090 | ||
+#error Compiling for minimum OS X version before 10.9 | ||
+#endif | ||
+ ]])],[ac_cv_have_os_x_9_or_later="yes"]) | ||
], [COCOA_LIBS=""]) | ||
- | ||
+AM_CONDITIONAL([MAC_OS_X_9], [test "x$ac_cv_have_os_x_9_or_later" = xyes]) | ||
AC_SUBST([COCOA_LIBS]) | ||
|
||
dnl declare --enable-* args and collect ac_help strings | ||
diff --git a/gio/Makefile.am b/gio/Makefile.am | ||
index e911d91..01d3711 100644 | ||
--- a/gio/Makefile.am | ||
+++ b/gio/Makefile.am | ||
@@ -266,8 +266,10 @@ unix_sources = \ | ||
$(NULL) | ||
|
||
if OS_COCOA | ||
+if MAC_OS_X_9 | ||
unix_sources += gcocoanotificationbackend.c | ||
endif | ||
+endif | ||
|
||
giounixincludedir=$(includedir)/gio-unix-2.0/gio | ||
giounixinclude_HEADERS = \ | ||
diff --git a/gio/giomodule.c b/gio/giomodule.c | ||
index da7c167..fec84ba 100644 | ||
--- a/gio/giomodule.c | ||
+++ b/gio/giomodule.c | ||
@@ -47,6 +47,10 @@ | ||
#include "gdesktopappinfo.h" | ||
#endif | ||
|
||
+#ifdef HAVE_COCOA | ||
+#include <AvailabilityMacros.h> | ||
+#endif | ||
+ | ||
/** | ||
* SECTION:giomodule | ||
* @short_description: Loadable GIO Modules | ||
@@ -911,7 +915,7 @@ extern GType g_fdo_notification_backend_get_type (void); | ||
extern GType g_gtk_notification_backend_get_type (void); | ||
#endif | ||
|
||
-#ifdef HAVE_COCOA | ||
+#ifdef AVAILABLE_MAC_OS_X_VERSION_10_9_AND_LATER | ||
extern GType g_cocoa_notification_backend_get_type (void); | ||
#endif | ||
|
||
@@ -1111,7 +1115,7 @@ _g_io_modules_ensure_loaded (void) | ||
g_type_ensure (g_fdo_notification_backend_get_type ()); | ||
g_type_ensure (g_gtk_notification_backend_get_type ()); | ||
#endif | ||
-#ifdef HAVE_COCOA | ||
+#ifdef AVAILABLE_MAC_OS_X_VERSION_10_9_AND_LATER | ||
g_type_ensure (g_cocoa_notification_backend_get_type ()); | ||
#endif | ||
#ifdef G_OS_WIN32 | ||
-- | ||
2.2.2 | ||
|
||
<!-- This module set works a bit differently than for example the | ||
GNOME ones do. It's split up in seperate pieces: | ||
|
||
- gtk-osx-bootstrap: contains bootstrap-like modules that you | ||
don't want to rebuild all the time. | ||
|
||
- gtk-osx.modules: contains the core GTK+ stack. This does not | ||
have a hard dependency on the bootstrap modules, in order to | ||
make it easy to rebuild the whole core stack without redoing | ||
the bootstrap parts. They have a soft, "after", depencency. | ||
|
||
The remaining modules are mostly for testing and might not work | ||
all the time: | ||
|
||
- gtk-osx-python.modules: self explaining. | ||
- gtk-osx-gtkmm.modules: self explaining. | ||
- gtk-osx-javascript.modules: GJS, associated tools, and the Mozilla JS | ||
library it depends on. | ||
- gtk-osx-gstreamer.modules: self explaining. | ||
- gtk-osx-themes.modules: self explaining. | ||
- gtk-osx-network.modules: The network/crypto stack and various | ||
configurations of WebKit. | ||
|
||
- gtk-osx-random.modules: "random stuff", has apps for testing GTK+. | ||
- gtk-osx-unsupported.modules: more testing stuff, competely unsupported. | ||
--> | ||
|
||
<include href="gtk-osx-bootstrap.modules"/> | ||
<include href="gtk-osx-gstreamer.modules"/> | ||
<include href="gtk-osx-gtkmm.modules"/> | ||
<include href="gtk-osx-javascript.modules"/> | ||
<include href="gtk-osx-network.modules"/> | ||
<include href="gtk-osx-python.modules"/> | ||
<include href="gtk-osx-random.modules"/> | ||
<include href="gtk-osx-themes.modules"/> | ||
<include href="gtk-osx-unsupported.modules"/> | ||
<include href="gtk-osx-universal.modules"/> | ||
|
||
<metamodule id="meta-gtk-osx-core"> | ||
<dependencies> | ||
<dep package="gtk+"/> | ||
<dep package="gtk-mac-integration"/> | ||
</dependencies> | ||
<after> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
</after> | ||
</metamodule> | ||
|
||
<metamodule id="meta-gtk-osx-gtk3"> | ||
<dependencies> | ||
<dep package="gtk+-3.0"/> | ||
<dep package="gtk-mac-integration"/> | ||
<dep package="meta-gtk-osx-gtk3-core-themes"/> | ||
</dependencies> | ||
<after> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
</after> | ||
</metamodule> | ||
|
||
<autotools id="glib" autogen-sh="autoreconf" | ||
autogenargs="--with-pcre=internal"> | ||
<branch module="glib/2.48/glib-2.48.0.tar.xz" version="2.48.0" | ||
hash="sha256:744be6931ca914c68af98dc38ff6b0cf8381d65e335060faddfbf04c17147c34"> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/0001-Fix-g_get_monotonic_time-on-non-Intel-Darwin.patch" strip="1"/> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/0001-Bug-724590-GSlice-slab_stack-corruption.patch" strip="1"/> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/gio-in-reserved-in-gcc-48.patch" strip="1"/> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/0001-Bug747146-Build-cocoanotification-only-if-supported.patch" strip="1"/> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/glib-gint64-long-long.patch" strip="1"/> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/glib-bug-772454-disable-kqueue.patch" strip="1"/> | ||
</branch> | ||
<dependencies> | ||
<dep package="libffi"/> | ||
</dependencies> | ||
<after> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
</after> | ||
</autotools> | ||
|
||
<autotools id="libffi" autogenargs="--disable-builddir" | ||
autogen-sh="configure"> | ||
<branch module="libffi/libffi-3.2.1.tar.gz" repo="sourceware.org" | ||
version="3.2.1"/> | ||
</autotools> | ||
|
||
<autotools id="xorg-util-macros"> | ||
<branch repo="freedesktop" version="1.19.0" | ||
module="xorg/individual/util/util-macros-1.19.0.tar.bz2"/> | ||
</autotools> | ||
|
||
<!-- There is no stable release yet that works here, but commit | ||
06fd4a27 breaks the build for gtk-osx, tag v1.3.1 builds | ||
fine. --> | ||
<autotools id="libepoxy"> | ||
<branch repo="github" module="anholt/libepoxy" revision="v1.3.1"/> | ||
<dependencies> | ||
<dep package="xorg-util-macros"/> | ||
</dependencies> | ||
</autotools> | ||
|
||
<autotools id="gobject-introspection" autogen-sh="configure"> | ||
<branch module="gobject-introspection/1.48/gobject-introspection-1.48.0.tar.xz" | ||
version="1.48.0" | ||
hash="sha256:fa275aaccdbfc91ec0bc9a6fd0562051acdba731e7d584b64a277fec60e75877"> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/girscanner-objc.patch" strip="1"/> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/gi_cairo_library_path.patch" strip="1"/> | ||
</branch> | ||
<dependencies> | ||
<dep package="glib"/> | ||
<dep package="cairo"/> | ||
<if condition-set='64-bit'> | ||
<dep package='python'/> | ||
</if> | ||
</dependencies> | ||
<if condition-unset='64-bit'> | ||
<after> | ||
<dep package='python'/> | ||
</after> | ||
</if> | ||
</autotools> | ||
|
||
<autotools id="pango" autogen-sh="autoreconf"> | ||
<branch version="1.38.1" module="pango/1.38/pango-1.38.1.tar.xz" | ||
hash="sha256:1320569f6c6d75d6b66172b2d28e59c56ee864ee9df202b76799c4506a214eb7"> | ||
</branch> | ||
<dependencies> | ||
<dep package="glib"/> | ||
<dep package="cairo"/> | ||
</dependencies> | ||
<after> | ||
<dep package="gobject-introspection"/> | ||
<dep package="meta-gtk-osx-freetype"/> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
</after> | ||
</autotools> | ||
|
||
<autotools id="atk" autogen-sh="configure"> | ||
<branch module="atk/2.20/atk-2.20.0.tar.xz" version="2.20.0" | ||
hash="sha256:493a50f6c4a025f588d380a551ec277e070b28a82e63ef8e3c06b3ee7c1238f0"/> | ||
<dependencies> | ||
</dependencies> | ||
<after> | ||
<dep package="glib"/> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
<dep package="gobject-introspection"/> | ||
</after> | ||
</autotools> | ||
|
||
<autotools id="gdk-pixbuf" autogen-sh="configure"> | ||
<branch module="gdk-pixbuf/2.34/gdk-pixbuf-2.34.0.tar.xz" version="2.34.0" | ||
hash="sha256:d55e5b383ee219bd0e23bf6ed4427d56a7db5379729a6e3e0a0e0eba9a8d8879"/> | ||
<after> | ||
<dep package="pango"/> | ||
<dep package="gobject-introspection"/> | ||
</after> | ||
</autotools> | ||
|
||
<autotools id="gtk+" autogen-sh="autoreconf" | ||
autogenargs="--with-gdktarget=quartz --enable-quartz-relocation --disable-introspection"> | ||
<branch module="gtk+/2.24/gtk+-2.24.30.tar.xz" version="2.24.30" | ||
hash="sha256:0d15cec3b6d55c60eac205b1f3ba81a1ed4eadd9d0f8e7c508bc7065d0c4ca50"> | ||
<!--patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/0004-Bug-571582-GtkSelection-implementation-for-quartz.patch" strip="1"/--> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/0008-Implement-GtkDragSourceOwner-pasteboardChangedOwner.patch" strip="1"/> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/0006-Bug-658722-Drag-and-Drop-sometimes-stops-working.patch" strip="1"/> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/gtk+-2-m4-creation.patch" strip="1"/> | ||
</branch> | ||
<dependencies> | ||
<dep package="glib"/> | ||
<dep package="pango"/> | ||
<dep package="atk"/> | ||
<dep package="gdk-pixbuf"/> | ||
<dep package="gobject-introspection"/> | ||
</dependencies> | ||
<after> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
</after> | ||
</autotools> | ||
|
||
<autotools id="gtk+-3.14" autogen-sh="autogen.sh" | ||
autogenargs="--enable-quartz-backend --enable-quartz-relocation"> | ||
<branch module="gtk+/3.14/gtk+-3.14.15.tar.xz" version="3.14.15" | ||
hash="sha256:3ac87659112ced9e5ee5bd55d055faa881aafd040f26ca40b0d8ba0fa6509c83"> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/0001-Bug-707945-GTK2-Quartz-typeahead-find-in-GtkTreeView.patch" strip="1"/> | ||
<!-- https://bugzilla.gnome.org/show_bug.cgi?id=763779 --> | ||
<patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/gtk-quartz-fix-pixelated-image-surfaces-in-retina-hidpi-.patch" strip="1"/> | ||
</branch> | ||
<dependencies> | ||
<dep package="glib"/> | ||
<dep package="pango"/> | ||
<dep package="atk"/> | ||
<dep package="cairo"/> | ||
<dep package="gdk-pixbuf"/> | ||
<dep package="gobject-introspection"/> | ||
</dependencies> | ||
<after> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
</after> | ||
</autotools> | ||
|
||
<autotools id="gtk+-3.0" autogen-sh="autogen.sh" | ||
autogenargs="--enable-quartz-backend --enable-quartz-relocation"> | ||
<branch module="gtk+/3.20/gtk+-3.20.9.tar.xz" version="3.20.9" | ||
hash="sha256:83a609ba2f3424b5509e73967c49c67833af466d6f91081b24ee5c64fce6ac17"> | ||
</branch> | ||
<dependencies> | ||
<dep package="glib"/> | ||
<dep package="pango"/> | ||
<dep package="atk"/> | ||
<dep package="gdk-pixbuf"/> | ||
<dep package="gobject-introspection"/> | ||
<dep package="libepoxy"/> | ||
</dependencies> | ||
<after> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
</after> | ||
</autotools> | ||
|
||
<autotools id="pixman" autogenargs="--disable-gtk --disable-mmx" | ||
autogen-sh="configure"> | ||
<branch version="0.34.0" module="pixman-0.34.0.tar.gz" | ||
repo="cairographics" | ||
hash="sha1:a1b1683c1a55acce9d928fea1ab6ceb79142ddc7"/> | ||
<after> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
</after> | ||
</autotools> | ||
|
||
<!-- Cairo will automatically enable freetype and fontconfig if | ||
meta-gtk-osx-freetype is built, so packages which require | ||
cairoft or cairofc should have meta-gtk-osx-freetype as a | ||
dependency. --> | ||
<autotools id="cairo" autogen-sh="configure" | ||
autogenargs="--enable-pdf --enable-quartz --disable-xlib --without-x"> | ||
<branch module="cairo-1.14.6.tar.xz" version="1.14.6" | ||
repo="cairographics" | ||
hash="sha1:0a59324e6cbe031b5b898ff8b9e2ffceb9d114f5"> | ||
</branch> | ||
<dependencies> | ||
<dep package="pixman"/> | ||
</dependencies> | ||
<after> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
<dep package="meta-gtk-osx-freetype"/> | ||
</after> | ||
</autotools> | ||
|
||
<autotools id="gtk-mac-integration" autogen-sh="configure" | ||
autogenargs="--disable-python"> | ||
<branch module="gtk-mac-integration/2.0/gtk-mac-integration-2.0.8.tar.xz" | ||
version="2.0.8" | ||
hash="sha256:74fce9dbc5efe4e3d07a20b24796be1b1d6c3ac10a0ee6b1f1d685c809071b79"> | ||
</branch> | ||
<dependencies> | ||
</dependencies> | ||
<after> | ||
<dep package="gtk+"/> | ||
<dep package="gtk+-3.0"/> | ||
<dep package="meta-gtk-osx-bootstrap"/> | ||
</after> | ||
</autotools> | ||
|
||
</moduleset> |