Date: Wed, 8 Jun 2005 15:08:27 +0200 From: jannisan@t-online.de To: gnome@FreeBSD.org Subject: Port upgrade: www/firefox. Added GUI selection support Message-ID: <20050608130827.GA65807@rochel.dyndns.org>
next in thread | raw e-mail | index | archive | help
--Kj7319i9nmIyA2yE Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hello. Here is a patch for the www/firefox port adding the ability to let the user select which GUI to use by "make config". He can choose between Xlib, Gtk1 and Gtk2 (default). Furthermore XUL can be disabled. I hope I did it right. If the patch is approved maybe another patch will follow, enabling more facilities to configure the software installation. Thanks Jan --Kj7319i9nmIyA2yE Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="firefox-select-gui-patch.diff" diff -cr firefox.orig/Makefile firefox/Makefile *** firefox.orig/Makefile Wed Jun 8 15:02:02 2005 --- firefox/Makefile Wed Jun 8 13:49:09 2005 *************** *** 8,13 **** --- 8,14 ---- PORTNAME= firefox PORTVERSION= 1.0.4 PORTEPOCH= 1 + PORTREVISION= 1 CATEGORIES= www MASTER_SITES= ${MASTER_SITE_MOZILLA} MASTER_SITE_SUBDIR= ${PORTNAME}/releases/1.0.4/source *************** *** 21,27 **** BUILD_DEPENDS= zip:${PORTSDIR}/archivers/zip ALL_TARGET= default ! CONFIGURE_ENV= LOCALBASE=${LOCALBASE} FAKEDIR= ${WRKDIR}/fake USE_REINPLACE= yes HAS_CONFIGURE= yes --- 22,29 ---- BUILD_DEPENDS= zip:${PORTSDIR}/archivers/zip ALL_TARGET= default ! LIBIDL_CONFIG?= ${LOCALBASE}/bin/libIDL-config-2 ! CONFIGURE_ENV= LOCALBASE=${LOCALBASE} LIBIDL_CONFIG=${LIBIDL_CONFIG} FAKEDIR= ${WRKDIR}/fake USE_REINPLACE= yes HAS_CONFIGURE= yes *************** *** 30,36 **** PLUGINSDIR= ${PREFIX}/lib/browser_plugins USE_BZIP2= yes USE_GMAKE= yes ! USE_GNOME= gtk20 libidl gnomehier desktopfileutils USE_ICONV= yes USE_PERL5_BUILD=yes USE_X_PREFIX= yes --- 32,38 ---- PLUGINSDIR= ${PREFIX}/lib/browser_plugins USE_BZIP2= yes USE_GMAKE= yes ! USE_GNOME= libidl gnomehier desktopfileutils USE_ICONV= yes USE_PERL5_BUILD=yes USE_X_PREFIX= yes *************** *** 64,82 **** MOZ_PIS_SCRIPTS= S50cleanhome MOZ_PIS_DIR= ${SCRIPTS_DIR}/init.d ! OPTIONS= DEBUG "Build a debugging image" off \ ! LOGGING "Enable additional log messages" off \ ! OPTIMIZED_CFLAGS "Enable some additional optimizations" off \ ! XFT "Enable support for anti-aliased fonts" on \ ! SMB "Enable smb:// URI support using gnomevfs" off \ NEWTAB "Open external links in a new tab" on .include <bsd.port.pre.mk> ! .if defined(WITH_DEBUG) ! WITH_LOGGING= yes ! CONFIGURE_ENV+= WITH_DEBUG=yes ! .endif # defined(WITH_DEBUG) .if defined(WITH_OPTIMIZED_CFLAGS) CFLAGS:= -O2 -fno-strict-aliasing ${CFLAGS:N-O*} --- 66,99 ---- MOZ_PIS_SCRIPTS= S50cleanhome MOZ_PIS_DIR= ${SCRIPTS_DIR}/init.d ! OPTIONS= TK_XLIB "EITHER use Xlib (pretty fast)" off \ ! TK_GTK1 "OR Gtk+ version 1" off \ ! TK_GTK2 "OR Gtk+ version 2 (just pretty)" on \ ! XUL "Mozilla's UI (slower than native)" on \ ! DEBUG "Build a debugging image" off \ ! LOGGING "Additional log messages" off \ ! OPTIMIZED_CFLAGS "Additional optimizations (not recommended)" off \ ! XFT "Support for anti-aliased fonts" on \ ! GNOMEVFS2 "smb:// URI support (uses Gtk+ version 2)" off \ NEWTAB "Open external links in a new tab" on .include <bsd.port.pre.mk> ! OPTION_VARS= ${OPTIONS:C/".*"|on|off//g} ! .for O in ${OPTION_VARS} ! OPTION_VALUE= ${WITH_${O}} ! .if ${OPTION_VALUE} == true ! CONFIGURE_ENV+= WITH_${O}=yes ! .else ! CONFIGURE_ENV+= WITH_${O}=no ! .endif ! .endfor ! ! .if defined(WITH_TK_GTK1) ! USE_GNOME+= gtk12 ! .elif defined(WITH_TK_GTK2) ! USE_GNOME+= gtk20 ! .endif .if defined(WITH_OPTIMIZED_CFLAGS) CFLAGS:= -O2 -fno-strict-aliasing ${CFLAGS:N-O*} *************** *** 85,104 **** CONFIGURE_ENV+= WITH_OPTIMIZE=-O .endif # defined(WITH_OPTIMIZED_CFLAGS) ! .if defined(WITH_LOGGING) ! CONFIGURE_ENV+= WITH_LOGGING=yes ! .endif # defined(WITH_LOGGING) ! ! .if defined(WITHOUT_XFT) ! CONFIGURE_ENV+= WITHOUT_XFT=yes ! .else LIB_DEPENDS+= Xft.2:${PORTSDIR}/x11-fonts/libXft ! .endif # !defined(WITHOUT_XFT) ! .if defined(WITH_SMB) USE_GNOME+= gnomevfs2 ! CONFIGURE_ENV+= WITH_SMB=yes ! .endif # defined(WITH_SMB) CPPFLAGS+= -I${X11BASE}/include -I${LOCALBASE}/include CFLAGS+= ${PTHREAD_CFLAGS} --- 102,114 ---- CONFIGURE_ENV+= WITH_OPTIMIZE=-O .endif # defined(WITH_OPTIMIZED_CFLAGS) ! .if defined(WITH_XFT) LIB_DEPENDS+= Xft.2:${PORTSDIR}/x11-fonts/libXft ! .endif # defined(WITH_XFT) ! .if defined(WITH_GNOMEVFS2) USE_GNOME+= gnomevfs2 ! .endif # defined(WITH_GNOMEVFS2) CPPFLAGS+= -I${X11BASE}/include -I${LOCALBASE}/include CFLAGS+= ${PTHREAD_CFLAGS} *************** *** 175,180 **** --- 185,192 ---- .endfor pre-configure: + echo ${OPTION_VARS} + echo ${CONFIGURE_ENV} @if [ -n "`${PKG_INFO} -xI '^bind[0-9]*-base-[0-9]'`" ]; then \ ${ECHO_CMD} "${PKGNAME}: bind installed with PORT_REPLACES_BASE_BIND causes build problems."; \ ${FALSE}; \ *************** *** 265,272 **** --- 277,286 ---- .endfor ${MKDIR} ${PREFIX}/share/applications ${INSTALL_DATA} ${WRKDIR}/firefox.desktop ${PREFIX}/share/applications + .if defined(WITH_TK_GTK1) || defined(WITH_TK_GTK2) ${INSTALL_DATA} ${WRKSRC}/other-licenses/branding/firefox/default.xpm \ ${PREFIX}/lib/${FIREFOX}/chrome/icons/default/default.xpm + .endif @-update-desktop-database .include <bsd.port.post.mk> diff -cr firefox.orig/files/mozconfig.in firefox/files/mozconfig.in *** firefox.orig/files/mozconfig.in Wed Jun 8 15:02:02 2005 --- firefox/files/mozconfig.in Wed Jun 8 08:24:55 2005 *************** *** 8,14 **** ac_add_options --disable-tests ac_add_options --disable-mailnews ac_add_options --disable-composer - ac_add_options --enable-default-toolkit=gtk2 # See the following URL for approval email for using official branding # http://people.freebsd.org/~ahze/firefox_thunderbird-approved.txt ac_add_options --enable-official-branding --- 8,13 ---- *************** *** 58,82 **** #else # ac_add_options --disable-reorder #fi # test -n "$WITH_REORDER" ! if test -n "$WITH_DEBUG"; then ac_add_options --enable-debug ac_add_options --disable-strip else ac_add_options --disable-debug - ac_add_options --enable-optimize=${WITH_OPTIMIZE} ac_add_options --enable-strip ! fi # test -n "$WITH_DEBUG" ! if test -n "$WITH_LOGGING"; then ! ac_add_options --enable-logging ! else ! ac_add_options --disable-logging ! fi # test -n "$WITH_LOGGING" ! if test -z "$WITHOUT_XFT"; then ac_add_options --enable-xft else ac_add_options --disable-xft ! fi # test -z "$WITHOUT_XFT" ! if test -z "$WITH_SMB"; then ac_add_options --disable-gnomevfs ! fi # test -z "$WITH_SMB" ###################################################################### --- 57,96 ---- #else # ac_add_options --disable-reorder #fi # test -n "$WITH_REORDER" ! if [ "$WITH_TK_XLIB" = "yes" ]; then ! ac_add_options --enable-default-toolkit=xlib ! elif [ "$WITH_TK_GTK1" = "yes" ]; then ! ac_add_options --enable-default-toolkit=gtk1 ! elif [ "$WITH_TK_GTK2" = "yes" ]; then ! ac_add_options --enable-default-toolkit=gtk2 ! fi ! if [ "$WITH_XUL" = "no" ]; then ! ac_ad_options --disable-xul ! fi ! if [ "$WITH_DEBUG" = "yes" ]; then ac_add_options --enable-debug ac_add_options --disable-strip + ac_add_options --enable-logging else ac_add_options --disable-debug ac_add_options --enable-strip ! if [ "$WITH_LOGGING" = "yes" ]; then ! ac_add_options --enable-logging ! else ! ac_add_options --disable-logging ! fi ! if [ "WITH_OPTIMIZED_CFLAGS" = "yes" ]; then ! ac_add_options --enable-optimize=-O2 ! fi ! fi ! if [ "$WITH_XFT" = "yes" ]; then ac_add_options --enable-xft else ac_add_options --disable-xft ! fi ! if [ "$WITH_GNOMEVFS2" = "yes" ]; then ! ac_add_options --enable-gnomevfs ! else ac_add_options --disable-gnomevfs ! fi ###################################################################### diff -cr firefox.orig/pkg-message firefox/pkg-message *** firefox.orig/pkg-message Wed Jun 8 15:02:02 2005 --- firefox/pkg-message Wed Jun 8 14:58:47 2005 *************** *** 1,7 **** ====================================================================== README FOR GNOMEVFS SUPPORT: Gnomevfs support is optional (disabled by default), and can be enabled by ! building with ``-DWITH_SMB''. It is new and currently has issues to be ironed out. --- 1,7 ---- ====================================================================== README FOR GNOMEVFS SUPPORT: Gnomevfs support is optional (disabled by default), and can be enabled by ! building with ``-DWITH_GNOMEVFS2''. It is new and currently has issues to be ironed out. --Kj7319i9nmIyA2yE--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050608130827.GA65807>