GTK2 & Cairo "Quartz" Variant
Hi. I noticed the following lines in GTK2's Portfile: pre-configure { if {[variant_isset quartz]} { if { ![file exists ${prefix}/include/cairo/cairo-quartz.h] } { ui_msg "\nYou must first build cairo with the quartz variant enabled. Please\nuninstall (or deactivate) the cairo port and reinstall by running:\n\n\"port install cairo +quartz\"\n" exit 1 } } ... variant quartz { configure.args-append --enable-gdktarget=quartz } Does this mean if I enable the quartz variant, I can compile GTK applications w/o X11?
On 19 Mar 2007, at 03:00, Nathan Brazil wrote:
Does this mean if I enable the quartz variant, I can compile GTK applications w/o X11?
In theory :) Randall Wood rhwood@mac.com "The rules are simple: The ball is round. The game lasts 90 minutes. All the rest is just philosophy."
On Mar 19, 2007, at 02:00, Nathan Brazil wrote:
Hi. I noticed the following lines in GTK2's Portfile:
pre-configure { if {[variant_isset quartz]} { if { ![file exists ${prefix}/include/cairo/cairo-quartz.h] } { ui_msg "\nYou must first build cairo with the quartz variant enabled. Please\nuninstall (or deactivate) the cairo port and reinstall by running:\n\n\"port install cairo +quartz\"\n" exit 1 } }
...
variant quartz { configure.args-append --enable-gdktarget=quartz }
Does this mean if I enable the quartz variant, I can compile GTK applications w/o X11?
Note that cairo 1.4.0 has been released and that the cairo portfile will soon be updated -- just as soon as we can figure out how to enable the quartz backend without having to disable the xlib backend, which is unfortunately the current situation with 1.4.0 [1]. 1.4.0 has completely replaced the quartz backend with what used to be called the nquartz (or "new quartz") backend. You'll have to see whether this new 1.4.0 quartz is still compatible with gtk2's quartz requirements. [1] http://lists.freedesktop.org/archives/cairo/2007-March/010015.html
This is quite exciting. GTK apps running on top of Quartz. Imagine that... -- On Mar 19, 2007, at 1:57 AM, Ryan Schmidt wrote:
On Mar 19, 2007, at 02:00, Nathan Brazil wrote:
Hi. I noticed the following lines in GTK2's Portfile:
pre-configure { if {[variant_isset quartz]} { if { ![file exists ${prefix}/include/cairo/cairo- quartz.h] } { ui_msg "\nYou must first build cairo with the quartz variant enabled. Please\nuninstall (or deactivate) the cairo port and reinstall by running:\n\n\"port install cairo +quartz\"\n" exit 1 } }
...
variant quartz { configure.args-append --enable-gdktarget=quartz }
Does this mean if I enable the quartz variant, I can compile GTK applications w/o X11?
Note that cairo 1.4.0 has been released and that the cairo portfile will soon be updated -- just as soon as we can figure out how to enable the quartz backend without having to disable the xlib backend, which is unfortunately the current situation with 1.4.0 [1]. 1.4.0 has completely replaced the quartz backend with what used to be called the nquartz (or "new quartz") backend. You'll have to see whether this new 1.4.0 quartz is still compatible with gtk2's quartz requirements.
[1] http://lists.freedesktop.org/archives/cairo/2007-March/010015.html
I was pleased to read about the possibility of running gtk2 apps without X11; one of the things that always bugs me about using the Gimp is having to click on a window to give it focus, then click again on a control in the window, for example the tools palette. Anyway I saw the Cairo update hit today, 1.4.2_0, so I rebuilt cairo +quartz and pango, and tried to rebuild gtk2 +quartz. I get an error during the build: gcc -DHAVE_CONFIG_H -I. -I. -I../.. -DG_LOG_DOMAIN=\"Gdk\" - DGDK_COMPILATION -I../.. -I../../gdk -I../../gdk - DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED - DG_DISABLE_CAST_CHECKS -D_REENTRANT -DXTHREADS -I/opt/local/include/ glib-2.0 -I/opt/local/lib/glib-2.0/include -I/opt/local/include -I/ opt/local/include/pango-1.0 -I/opt/local/include/cairo -I/opt/local/ include/freetype2 -I/opt/local/include/libpng12 -I/usr/X11R6/include - xobjective-c -I/opt/local/include -no-cpp-precomp -DX_LOCALE -I/usr/ X11R6/include -MT gdkdrawable-quartz.lo -MD -MP -MF .deps/gdkdrawable- quartz.Tpo -c gdkdrawable-quartz.c -fno-common -DPIC -o .libs/ gdkdrawable-quartz.o gdkdrawable-quartz.c: In function 'gdk_quartz_ref_cairo_surface': gdkdrawable-quartz.c:64: error: incompatible type for argument 1 of 'cairo_quartz_surface_create' gdkdrawable-quartz.c:64: error: too many arguments to function 'cairo_quartz_surface_create' make[4]: *** [gdkdrawable-quartz.lo] Error 1 make[3]: *** [all-recursive] Error 1 make[2]: *** [all] Error 2 make[1]: *** [all-recursive] Error 1 make: *** [all] Error 2 Warning: the following items did not execute (for gtk2): com.apple.activate com.apple.build com.apple.destroot com.apple.install Error: Status 1 encountered during processing. I have the rest of the build log if you're interested. Has anyone managed to build gtk2 +quartz atop the new cairo 1.4.2 +quartz? Thanks, Frank On Mar 19, 2007, at 04:57, Ryan Schmidt wrote:
On Mar 19, 2007, at 02:00, Nathan Brazil wrote:
Hi. I noticed the following lines in GTK2's Portfile:
pre-configure { if {[variant_isset quartz]} { if { ![file exists ${prefix}/include/cairo/cairo- quartz.h] } { ui_msg "\nYou must first build cairo with the quartz variant enabled. Please\nuninstall (or deactivate) the cairo port and reinstall by running:\n\n\"port install cairo +quartz\"\n" exit 1 } }
...
variant quartz { configure.args-append --enable-gdktarget=quartz }
Does this mean if I enable the quartz variant, I can compile GTK applications w/o X11?
Note that cairo 1.4.0 has been released and that the cairo portfile will soon be updated -- just as soon as we can figure out how to enable the quartz backend without having to disable the xlib backend, which is unfortunately the current situation with 1.4.0 [1]. 1.4.0 has completely replaced the quartz backend with what used to be called the nquartz (or "new quartz") backend. You'll have to see whether this new 1.4.0 quartz is still compatible with gtk2's quartz requirements.
[1] http://lists.freedesktop.org/archives/cairo/2007-March/010015.html
_______________________________________________ macports-users mailing list macports-users@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo/macports-users
On 23 mars 07, at 16:52, Frank McPherson wrote:
I was pleased to read about the possibility of running gtk2 apps without X11; one of the things that always bugs me about using the Gimp is having to click on a window to give it focus, then click again on a control in the window, for example the tools palette.
You can enable focus follow mouse for X11. This way, you won't have to click on a window to give it focus. defaults write com.apple.x11 wm_ffm -bool true
Has anyone managed to build gtk2 +quartz atop the new cairo 1.4.2 +quartz?
Yes, I fixed the problem you mentioned and I recompiled wireshark with gtk2 +quartz. The result is very far from being usable. You may have seen this warning if you installed with verbose output: *** The Quartz backend is still under active development and *** is included in this release only as a preview. It does not *** fully work yet and incompatible changes may yet be made *** to Quartz-backend specific API. This is very true, all you get is a preview but nothing really usable! I uninstalled gtk2 + quartz, installed the x11 version and recompiled wireshark so that I can use it. If your only concern is the focus follow mouse problem then I strongly advise to use the x11 preferences solution. Cheers, Cédric
On 23/03/07, Frank McPherson <frank.mcpherson@janusresearch.com> wrote:
I was pleased to read about the possibility of running gtk2 apps without X11; one of the things that always bugs me about using the Gimp is having to click on a window to give it focus, then click again on a control in the window, for example the tools palette.
Anyway I saw the Cairo update hit today, 1.4.2_0, so I rebuilt cairo +quartz and pango, and tried to rebuild gtk2 +quartz. I get an error during the build: gcc -DHAVE_CONFIG_H -I. -I. -I../.. -DG_LOG_DOMAIN=\"Gdk\" -DGDK_COMPILATION -I../.. -I../../gdk -I../../gdk -DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DG_DISABLE_CAST_CHECKS -D_REENTRANT -DXTHREADS -I/opt/local/include/glib-2.0 -I/opt/local/lib/glib-2.0/include -I/opt/local/include -I/opt/local/include/pango-1.0 -I/opt/local/include/cairo -I/opt/local/include/freetype2 -I/opt/local/include/libpng12 -I/usr/X11R6/include -xobjective-c -I/opt/local/include -no-cpp-precomp -DX_LOCALE -I/usr/X11R6/include -MT gdkdrawable-quartz.lo -MD -MP -MF .deps/gdkdrawable-quartz.Tpo -c gdkdrawable-quartz.c -fno-common -DPIC -o .libs/gdkdrawable-quartz.o gdkdrawable-quartz.c: In function 'gdk_quartz_ref_cairo_surface': gdkdrawable-quartz.c:64: error: incompatible type for argument 1 of 'cairo_quartz_surface_create' gdkdrawable-quartz.c:64: error: too many arguments to function 'cairo_quartz_surface_create' make[4]: *** [gdkdrawable-quartz.lo] Error 1 make[3]: *** [all-recursive] Error 1 make[2]: *** [all] Error 2 make[1]: *** [all-recursive] Error 1 make: *** [all] Error 2
Warning: the following items did not execute (for gtk2): com.apple.activate com.apple.build com.apple.destroot com.apple.install Error: Status 1 encountered during processing.
I have the rest of the build log if you're interested. Has anyone managed to build gtk2 +quartz atop the new cairo 1.4.2 +quartz?
I've also ran into this problem, does anyone have a solution or is it just a case of waiting for gtk2 to be fixed upstream? Cheers Adam
On 27 mars 07, at 17:37, Adam Mercer wrote:
I've also ran into this problem, does anyone have a solution or is it just a case of waiting for gtk2 to be fixed upstream?
This is the solution: --- gdk/quartz/gdkdrawable-quartz.c 2007-03-23 22:52:59.000000000 +0100 +++ gdk/quartz/gdkdrawable-quartz.c 2007-03-23 22:58:26.000000000 +0100 @@ -61,7 +61,7 @@ gdk_drawable_get_size (drawable, &width, &height); - surface = cairo_quartz_surface_create (context, width, height, TRUE); + surface = cairo_quartz_surface_create_for_cg_context (context, width, height); info = g_new (SurfaceInfo, 1); info->drawable = drawable; I think this is going to be fixed upstream (maybe it's even already fixed in cvs). But as I already told on this thread, gtk2+quartz is not usable. It's not even beta, it's a just a preview. Cheers, Cédric
participants (7)
-
Adam Mercer
-
Cédric Luthi
-
Frank McPherson
-
Nathan Brazil
-
Randall Wood
-
Ryan Schmidt
-
Une Bévue