diff options
author | minskim <minskim@pkgsrc.org> | 2006-12-05 21:26:58 +0000 |
---|---|---|
committer | minskim <minskim@pkgsrc.org> | 2006-12-05 21:26:58 +0000 |
commit | 641c822ab9f9c62d2dc1d7cd4dc4c2507ab5ec01 (patch) | |
tree | 690aabc8492754247ae44dfe47747ea47d00a159 /x11/gtk2 | |
parent | d3edfc23b7bd49e8bfcd0089deef098da06e4b05 (diff) | |
download | pkgsrc-641c822ab9f9c62d2dc1d7cd4dc4c2507ab5ec01.tar.gz |
Add an option to choose the GDK backend target between X11 and Quartz for
Mac OS X. Thanks to wiz@ for review and suggestions for earlier patches
of this change.
Diffstat (limited to 'x11/gtk2')
-rw-r--r-- | x11/gtk2/Makefile | 17 | ||||
-rw-r--r-- | x11/gtk2/PLIST | 28 | ||||
-rw-r--r-- | x11/gtk2/buildlink3.mk | 25 | ||||
-rw-r--r-- | x11/gtk2/options.mk | 38 |
4 files changed, 73 insertions, 35 deletions
diff --git a/x11/gtk2/Makefile b/x11/gtk2/Makefile index a6c58e4380d..0b0cadb1150 100644 --- a/x11/gtk2/Makefile +++ b/x11/gtk2/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.132 2006/11/06 10:42:38 joerg Exp $ +# $NetBSD: Makefile,v 1.133 2006/12/05 21:26:58 minskim Exp $ DISTNAME= gtk+-2.10.6 PKGNAME= ${DISTNAME:S/gtk/gtk2/} @@ -19,7 +19,6 @@ CONFLICTS= gtk2-engines<2.6.0 BUILDLINK_API_DEPENDS.cairo+= cairo>=1.2.0 BUILDLINK_API_DEPENDS.glib2+= glib2>=2.12.0 BUILDLINK_API_DEPENDS.pango+= pango>=1.13.0 -BUILDLINK_API_DEPENDS.Xft2+= Xft2>=2.1.2nb2 USE_DIRS+= xdg-1.1 USE_PKGLOCALEDIR= yes @@ -28,10 +27,7 @@ USE_LIBTOOL= yes PTHREAD_AUTO_VARS= yes GNU_CONFIGURE= yes -CONFIGURE_ARGS+= --with-xinput=xfree CONFIGURE_ARGS+= --sysconfdir=${PREFIX}/libdata -CONFIGURE_ENV+= ac_cv_header_X11_extensions_Xinerama_h=no -CONFIGURE_ENV+= ac_cv_lib_Xinerama_XineramaQueryExtension=no MAKE_ENV+= PKGLOCALEDIR=${PKGLOCALEDIR:Q} TEST_TARGET= check @@ -93,16 +89,5 @@ _BUILDING_GTK2= yes .include "../../graphics/jpeg/buildlink3.mk" .include "../../graphics/png/buildlink3.mk" .include "../../graphics/tiff/buildlink3.mk" -.include "../../x11/libX11/buildlink3.mk" -.include "../../x11/libXcursor/buildlink3.mk" -.include "../../x11/libXft/buildlink3.mk" -.include "../../x11/libXfixes/buildlink3.mk" -.include "../../x11/libXinerama/buildlink3.mk" -.include "../../x11/libXi/buildlink3.mk" -.include "../../x11/libXrandr/buildlink3.mk" -.include "../../x11/libXrender/buildlink3.mk" -.include "../../x11/libXt/buildlink3.mk" -.include "../../x11/xextproto/buildlink3.mk" -.include "../../x11/libXext/buildlink3.mk" .include "../../mk/bsd.pkg.mk" diff --git a/x11/gtk2/PLIST b/x11/gtk2/PLIST index 614e1241ecc..cc06e3ee214 100644 --- a/x11/gtk2/PLIST +++ b/x11/gtk2/PLIST @@ -1,11 +1,11 @@ -@comment $NetBSD: PLIST,v 1.49 2006/09/15 15:06:08 jmmv Exp $ +@comment $NetBSD: PLIST,v 1.50 2006/12/05 21:26:59 minskim Exp $ bin/gdk-pixbuf-csource bin/gdk-pixbuf-query-loaders bin/gtk-demo bin/gtk-query-immodules-2.0 bin/gtk-update-icon-cache -include/gtk-2.0/gdk-pixbuf-xlib/gdk-pixbuf-xlib.h -include/gtk-2.0/gdk-pixbuf-xlib/gdk-pixbuf-xlibrgb.h +${X11}include/gtk-2.0/gdk-pixbuf-xlib/gdk-pixbuf-xlib.h +${X11}include/gtk-2.0/gdk-pixbuf-xlib/gdk-pixbuf-xlibrgb.h include/gtk-2.0/gdk-pixbuf/gdk-pixbuf-animation.h include/gtk-2.0/gdk-pixbuf/gdk-pixbuf-core.h include/gtk-2.0/gdk-pixbuf/gdk-pixbuf-enum-types.h @@ -48,7 +48,7 @@ include/gtk-2.0/gdk/gdkspawn.h include/gtk-2.0/gdk/gdktypes.h include/gtk-2.0/gdk/gdkvisual.h include/gtk-2.0/gdk/gdkwindow.h -include/gtk-2.0/gdk/gdkx.h +${X11}include/gtk-2.0/gdk/gdkx.h include/gtk-2.0/gtk/gtk.h include/gtk-2.0/gtk/gtkaboutdialog.h include/gtk-2.0/gtk/gtkaccelgroup.h @@ -258,7 +258,7 @@ lib/gtk-2.0/2.10.0/immodules/im-thai-broken.la lib/gtk-2.0/2.10.0/immodules/im-ti-er.la lib/gtk-2.0/2.10.0/immodules/im-ti-et.la lib/gtk-2.0/2.10.0/immodules/im-viqr.la -lib/gtk-2.0/2.10.0/immodules/im-xim.la +${X11}lib/gtk-2.0/2.10.0/immodules/im-xim.la lib/gtk-2.0/2.10.0/loaders/libpixbufloader-ani.la lib/gtk-2.0/2.10.0/loaders/libpixbufloader-bmp.la lib/gtk-2.0/2.10.0/loaders/libpixbufloader-gif.la @@ -276,17 +276,21 @@ lib/gtk-2.0/2.10.0/loaders/libpixbufloader-xpm.la lib/gtk-2.0/2.10.0/printbackends/libprintbackend-file.la lib/gtk-2.0/2.10.0/printbackends/libprintbackend-lpr.la lib/gtk-2.0/include/gdkconfig.h -lib/libgdk-x11-2.0.la +${QUARTZ}lib/libgdk-quartz-2.0.la +${X11}lib/libgdk-x11-2.0.la lib/libgdk_pixbuf-2.0.la -lib/libgdk_pixbuf_xlib-2.0.la -lib/libgtk-x11-2.0.la +${X11}lib/libgdk_pixbuf_xlib-2.0.la +${QUARTZ}lib/libgtk-quartz-2.0.la +${X11}lib/libgtk-x11-2.0.la lib/pkgconfig/gdk-2.0.pc lib/pkgconfig/gdk-pixbuf-2.0.pc -lib/pkgconfig/gdk-pixbuf-xlib-2.0.pc -lib/pkgconfig/gdk-x11-2.0.pc +${QUARTZ}lib/pkgconfig/gdk-quartz-2.0.pc +${X11}lib/pkgconfig/gdk-pixbuf-xlib-2.0.pc +${X11}lib/pkgconfig/gdk-x11-2.0.pc lib/pkgconfig/gtk+-2.0.pc +${QUARTZ}lib/pkgconfig/gtk+-quartz-2.0.pc lib/pkgconfig/gtk+-unix-print-2.0.pc -lib/pkgconfig/gtk+-x11-2.0.pc +${X11}lib/pkgconfig/gtk+-x11-2.0.pc man/man1/gdk-pixbuf-csource.1 man/man1/gdk-pixbuf-query-loaders.1 man/man1/gtk-query-immodules-2.0.1 @@ -1133,7 +1137,7 @@ share/themes/Raleigh/gtk-2.0/gtkrc @dirrm include/gtk-unix-print-2.0/gtk @dirrm include/gtk-unix-print-2.0 @dirrm include/gtk-2.0/gtk -@dirrm include/gtk-2.0/gdk-pixbuf-xlib +${X11}@dirrm include/gtk-2.0/gdk-pixbuf-xlib @dirrm include/gtk-2.0/gdk-pixbuf @dirrm include/gtk-2.0/gdk @dirrm include/gtk-2.0 diff --git a/x11/gtk2/buildlink3.mk b/x11/gtk2/buildlink3.mk index 98d8f44639d..06a7ee38436 100644 --- a/x11/gtk2/buildlink3.mk +++ b/x11/gtk2/buildlink3.mk @@ -1,4 +1,4 @@ -# $NetBSD: buildlink3.mk,v 1.32 2006/11/06 10:42:38 joerg Exp $ +# $NetBSD: buildlink3.mk,v 1.33 2006/12/05 21:26:59 minskim Exp $ BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ GTK2_BUILDLINK3_MK:= ${GTK2_BUILDLINK3_MK}+ @@ -24,6 +24,24 @@ PRINT_PLIST_AWK+= /^@dirrm lib\/gtk-2.0\/2.10.0\/(engines|filesystems|immodules| { print "@comment in gtk2: " $$0; next; } .endif # GTK2_BUILDLINK3_MK +.include "../../mk/bsd.prefs.mk" + +.if !defined(PKG_BUILD_OPTIONS.gtk2+) +PKG_BUILD_OPTIONS.gtk2+!= \ + cd ${BUILDLINK_PKGSRCDIR.gtk2} && \ + ${MAKE} show-var ${MAKEFLAGS} VARNAME=PKG_OPTIONS +MAKEFLAGS+= PKG_BUILD_OPTIONS.gtk2+=${PKG_BUILD_OPTIONS.gtk2+:Q} +.endif +MAKEVARS+= PKG_BUILD_OPTIONS.gtk2+ + +.if !empty(PKG_BUILD_OPTIONS.gtk2+:Mx11) +.include "../../x11/libXcursor/buildlink3.mk" +.include "../../x11/libXft/buildlink3.mk" +.include "../../x11/libXrandr/buildlink3.mk" +.include "../../x11/libXinerama/buildlink3.mk" +.include "../../x11/libXi/buildlink3.mk" +.endif + .include "../../devel/atk/buildlink3.mk" .include "../../devel/gettext-lib/buildlink3.mk" .include "../../devel/glib2/buildlink3.mk" @@ -32,10 +50,5 @@ PRINT_PLIST_AWK+= /^@dirrm lib\/gtk-2.0\/2.10.0\/(engines|filesystems|immodules| .include "../../graphics/cairo/buildlink3.mk" .include "../../graphics/freetype2/buildlink3.mk" .include "../../graphics/png/buildlink3.mk" -.include "../../x11/libXcursor/buildlink3.mk" -.include "../../x11/libXft/buildlink3.mk" -.include "../../x11/libXrandr/buildlink3.mk" -.include "../../x11/libXinerama/buildlink3.mk" -.include "../../x11/libXi/buildlink3.mk" BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} diff --git a/x11/gtk2/options.mk b/x11/gtk2/options.mk index 04c1590ae0b..b3a1f09eecd 100644 --- a/x11/gtk2/options.mk +++ b/x11/gtk2/options.mk @@ -1,10 +1,46 @@ -# $NetBSD: options.mk,v 1.1 2005/11/25 21:31:06 wiz Exp $ +# $NetBSD: options.mk,v 1.2 2006/12/05 21:26:59 minskim Exp $ PKG_OPTIONS_VAR= PKG_OPTIONS.gtk2+ PKG_SUPPORTED_OPTIONS= debug +.if exists(/System/Library/Frameworks/Quartz.framework) +PKG_OPTIONS_REQUIRED_GROUPS= gdk-target +PKG_OPTIONS_GROUP.gdk-target= quartz x11 +PKG_SUGGESTED_OPTIONS= x11 +.endif .include "../../mk/bsd.options.mk" .if !empty(PKG_OPTIONS:Mdebug) CONFIGURE_ARGS+= --enable-debug=yes .endif + +### +### GDK target +### +.if !empty(PKG_OPTIONS:Mquartz) +CONFIGURE_ARGS+= --without-x +CONFIGURE_ARGS+= --with-gdktarget=quartz +PLIST_SUBST+= QUARTZ="" +PLIST_SUBST+= X11="@comment " +.else +CONFIGURE_ARGS+= --with-xinput=xfree +CONFIGURE_ENV+= ac_cv_header_X11_extensions_Xinerama_h=no +CONFIGURE_ENV+= ac_cv_lib_Xinerama_XineramaQueryExtension=no +PLIST_SUBST+= QUARTZ="@comment " +PLIST_SUBST+= X11="" + +BUILDLINK_API_DEPENDS.Xft2+= Xft2>=2.1.2nb2 + +.include "../../x11/libX11/buildlink3.mk" +.include "../../x11/libXcursor/buildlink3.mk" +.include "../../x11/libXft/buildlink3.mk" +.include "../../x11/libXfixes/buildlink3.mk" +.include "../../x11/libXinerama/buildlink3.mk" +.include "../../x11/libXi/buildlink3.mk" +.include "../../x11/libXrandr/buildlink3.mk" +.include "../../x11/libXrender/buildlink3.mk" +.include "../../x11/libXt/buildlink3.mk" +.include "../../x11/xextproto/buildlink3.mk" +.include "../../x11/libXext/buildlink3.mk" + +.endif |