From owner-svn-ports-head@freebsd.org Thu Sep 10 00:33:09 2015 Return-Path: Delivered-To: svn-ports-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5C904A00606; Thu, 10 Sep 2015 00:33:09 +0000 (UTC) (envelope-from truckman@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4BF2910BB; Thu, 10 Sep 2015 00:33:09 +0000 (UTC) (envelope-from truckman@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.70]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id t8A0X9df082708; Thu, 10 Sep 2015 00:33:09 GMT (envelope-from truckman@FreeBSD.org) Received: (from truckman@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id t8A0X8oT082706; Thu, 10 Sep 2015 00:33:08 GMT (envelope-from truckman@FreeBSD.org) Message-Id: <201509100033.t8A0X8oT082706@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: truckman set sender to truckman@FreeBSD.org using -f From: Don Lewis Date: Thu, 10 Sep 2015 00:33:08 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r396545 - in head/editors/openoffice-4: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 10 Sep 2015 00:33:09 -0000 Author: truckman Date: Thu Sep 10 00:33:08 2015 New Revision: 396545 URL: https://svnweb.freebsd.org/changeset/ports/396545 Log: Unbreak wrapper script so that if a particular application is specified but without specifying a document, that application is started instead of presenting the user with the generic startup window and requiring him to pick the document type (running openoffice-*-scalc should open to a new spreadsheet, etc.) Building with clang 3.7 is reported to have the same failure mode as clang 3.6, so use the same optimization tweak as a workaround. Various cleanups to do-install: * The paths ${PREFIX}/${INSTALLATION_BASEDIR} and ${PREFIX}/${INSTALLATION_BASEDIR}/${AOODIR}, and ${PREFIX}/${INSTALLATION_BASEDIR}/${AOODIR}/share/xdg are frequently used, so create a few variables to hold those paths instead of repeating the same, long sequence in a number of places * Tweak openoffice-wrapper to take advantage of the previous change * Use INSTALLS_ICONS=yes instead of manually adding the @exec and @unexec entries to the plist * Edit bootstraprc only once with ${REINPLACE_CMD} instead of running it twice to edit the same line * Remove bootstraprc.bak so that it does not get installed * With the advent of staging, it is not necessary to remove ${STAGEDIR}${DESKTOPDIR}/${EXECBASE} * Simplify code for installing icons Rename remaining OOO* variables to AOO*. Delete unused definition of ${SUBST}. Delete fbsd:nokeywords property and add svn:keywords to files/openoffice-wrapper. Modified: head/editors/openoffice-4/Makefile head/editors/openoffice-4/files/openoffice-wrapper (contents, props changed) Modified: head/editors/openoffice-4/Makefile ============================================================================== --- head/editors/openoffice-4/Makefile Thu Sep 10 00:26:28 2015 (r396544) +++ head/editors/openoffice-4/Makefile Thu Sep 10 00:33:08 2015 (r396545) @@ -3,7 +3,7 @@ PORTNAME= apache-openoffice PORTVERSION= ${AOOVERSION} -PORTREVISION= 12 +PORTREVISION= 13 CATEGORIES= editors java MASTER_SITES= APACHE/openoffice/${PORTVERSION}/source \ http://tools.openoffice.org/unowinreg_prebuild/680/:unoreg \ @@ -14,9 +14,9 @@ PKGNAMEPREFIX= ${LANG_PKGNAME}- .if defined(LANG_SUFFIX) PKGNAMESUFFIX= -${LANG_SUFFIX} .endif -DISTFILES= ${OOOSRC} unowinreg.dll:unoreg ${EXTSRC}:extsrc +DISTFILES= ${AOOSRC} unowinreg.dll:unoreg ${EXTSRC}:extsrc DIST_SUBDIR= openoffice -EXTRACT_ONLY= ${OOOSRC} +EXTRACT_ONLY= ${AOOSRC} MAINTAINER= office@FreeBSD.org #de facto maintainer is truckman@FreeBSD.org @@ -104,11 +104,13 @@ EXTSRC= ApacheOpenOffice.ext_sources.${ AOOVERSION= ${AOOVERSION1}.${AOOVERSION2}.${AOOVERSION3} AOOXXX= ${AOOVERSION1}${AOOVERSION2}${AOOVERSION3} AOOSUFFIX= ${PORTVERSION} -OOOSRC= apache-openoffice-${AOOVERSION}-r${SVNREVISION}-src${EXTRACT_SUFX} +AOOSRC= apache-openoffice-${AOOVERSION}-r${SVNREVISION}-src${EXTRACT_SUFX} -OOODIR= openoffice${AOOVERSION1} AOOUDIR= .openoffice.org\/${AOOVERSION1} INSTALLATION_BASEDIR?= openoffice-${AOOSUFFIX} +PRINSTALLATION_BASEDIR= ${PREFIX}/${INSTALLATION_BASEDIR} +OOPATH= ${PRINSTALLATION_BASEDIR}/openoffice${AOOVERSION1} +XDGDIR= ${OOPATH}/share/xdg EXECBASE?= openoffice-${AOOSUFFIX} ONLY_FOR_ARCHS= i386 amd64 @@ -125,6 +127,7 @@ USE_XORG= ice x11 xau xaw xcomposite xcu USES= autoreconf:autoconf bison compiler cpe desktop-file-utils \ gettext-runtime gmake iconv jpeg perl5 pkgconfig python \ tar:bzip2 +INSTALLS_ICONS= yes WITHOUT_CPU_CFLAGS= true CPE_PRODUCT= ${PORTNAME:S|apache-||} CPE_VENDOR= apache @@ -159,7 +162,6 @@ MMEDIA_USE= GSTREAMER=yes CPPFLAGS+= -I${LOCALBASE}/include .else USE_GCC= yes -SUBST= "s/-fexceptions/& -fno-enforce-eh-specs/;s/-DHAVE_STL_INCLUDE_PATH/-DBOOST_TR1_DISABLE_INCLUDE_NEXT -DBOOST_TR1_GCC_INCLUDE_PATH=c++/" .endif .if ${ARCH} == amd64 @@ -176,14 +178,14 @@ LOCALIZED_LANG?= en-US .if ${PORT_OPTIONS:MCCACHE} || defined(WITH_CCACHE) BUILD_DEPENDS+= ccache:${PORTSDIR}/devel/ccache CCACHE_PREFIX= ccache -OOOCC= ${CCACHE_PREFIX} ${CC} -OOOCXX= ${CCACHE_PREFIX} ${CXX} +AOOCC= ${CCACHE_PREFIX} ${CC} +AOOCXX= ${CCACHE_PREFIX} ${CXX} .else -OOOCC= ${CC} -OOOCXX= ${CXX} +AOOCC= ${CC} +AOOCXX= ${CXX} .endif -CONFIGURE_ENV+= CC="${OOOCC}" CXX="${OOOCXX}" \ +CONFIGURE_ENV+= CC="${AOOCC}" CXX="${AOOCXX}" \ PATH=${WRKSRC}/solenv/bin:$$PATH GNU_CONFIGURE= yes @@ -252,10 +254,10 @@ CONFIGURE_ARGS+= \ --with-system-xrender \ --with-system-zlib -#OOOEXTENSIONS+= minimizer/presentation-minimizer.oxt -#OOOEXTENSIONS+= presenter/presenter-screen.oxt -#OOOEXTENSIONS+= pdfimport/pdfimport.oxt -OOOEXTENSIONS+= swext/wiki-publisher.oxt +#AOOEXTENSIONS+= minimizer/presentation-minimizer.oxt +#AOOEXTENSIONS+= presenter/presenter-screen.oxt +#AOOEXTENSIONS+= pdfimport/pdfimport.oxt +AOOEXTENSIONS+= swext/wiki-publisher.oxt ICONS= ${WRKSRC}/sysui/desktop/icons @@ -324,7 +326,7 @@ post-patch: ${REINPLACE_CMD} -e "s/ := -Os/ := -Os -fno-devirtualize -fno-devirtualize-speculatively/" ${WRKSRC}/solenv/gbuild/platform/freebsd.mk; \ ${REINPLACE_CMD} -e "s/=-Os /=-Os -fno-devirtualize -fno-devirtualize-speculatively /" ${WRKSRC}/solenv/inc/unxfbsdi.mk; \ fi -.elif ${ARCH} == i386 && ${COMPILER_TYPE} == clang && ${COMPILER_VERSION} == 36 +.elif ${ARCH} == i386 && ${COMPILER_TYPE} == clang && ${COMPILER_VERSION} >= 36 # autodoc and uno (bridgetest) core dump when built with with -Os # on i386, affects file.cxx and bridgetest.cxx # Using -O2 optimiztion works, and -Os is essentially -O2 with out @@ -384,23 +386,21 @@ do-install: ${ECHO_CMD} "extracting $$i" ; \ cd ${WRKDIR}/tmp ; ${TAR} xfz ${WRKSRC}/instsetoo_native/unxfbsd?.pro/Apache_OpenOffice/archive/install/${LOCALIZED_LANG}/$$i ; \ done - ${MKDIR} ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR} - cd ${WRKDIR}/tmp/*/ ; ${TAR} cf - -C . . | ${TAR} xf - -C ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR} - ${REINPLACE_CMD} -e 's/^UserInstallation.*$$/USERINSTALLATION/' ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR}/${OOODIR}/program/bootstraprc - ${REINPLACE_CMD} -e 's/USERINSTALLATION/UserInstallation=$$SYSUSERCONFIG\/${AOOUDIR}/' ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR}/${OOODIR}/program/bootstraprc - ${MKDIR} ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR}/extensions/ - cd ${WRKSRC}/solver/${AOOXXX}/unxfbsd?.pro/bin/ ; ${INSTALL_DATA} ${OOOEXTENSIONS} ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR}/extensions/ - ${FIND} ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR}/${OOODIR}/program -type f \( -name '*.so*' -or -name '*.bin' \) -print0 | ${XARGS} -0 -n1 ${STRIP_CMD} + ${MKDIR} ${STAGEDIR}${PRINSTALLATION_BASEDIR} + cd ${WRKDIR}/tmp/*/ ; ${TAR} cf - -C . . | ${TAR} xf - -C ${STAGEDIR}${PRINSTALLATION_BASEDIR} + ${REINPLACE_CMD} -e '/^UserInstallation/s/=.*/=$$SYSUSERCONFIG\/${AOOUDIR}/' ${STAGEDIR}${OOPATH}/program/bootstraprc + ${RM} ${STAGEDIR}${OOPATH}/program/bootstraprc.bak + ${MKDIR} ${STAGEDIR}${PRINSTALLATION_BASEDIR}/extensions/ + cd ${WRKSRC}/solver/${AOOXXX}/unxfbsd?.pro/bin/ ; ${INSTALL_DATA} ${AOOEXTENSIONS} ${STAGEDIR}${PRINSTALLATION_BASEDIR}/extensions/ + ${FIND} ${STAGEDIR}${OOPATH}/program -type f \( -name '*.so*' -or -name '*.bin' \) -print0 | ${XARGS} -0 -n1 ${STRIP_CMD} for prog in crashrep pagein uri-encode javaldx regmerge regview; do \ - ${STRIP_CMD} ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR}/${OOODIR}/program/$${prog}; \ + ${STRIP_CMD} ${STAGEDIR}${OOPATH}/program/$${prog}; \ done - ${FIND} ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR} -type d -exec ${CHMOD} 755 {} \; + ${FIND} ${STAGEDIR}${PRINSTALLATION_BASEDIR} -type d -exec ${CHMOD} 755 {} \; @${ECHO_MSG} "===> Add wrapper scripts"; ${CP} ${FILESDIR}/openoffice-wrapper ${WRKDIR}/ - ${REINPLACE_CMD} -e 's#%%PREFIX%%#${PREFIX}#g' \ - -e 's#%%SVNREVISION%%#${SVNREVISION}#g' \ - -e 's#%%OOODIR%%#${OOODIR}#g' \ - -e 's#%%INSTALLATION_BASEDIR%%#${INSTALLATION_BASEDIR}#g' \ + ${REINPLACE_CMD} -e 's#%%OOPATH%%#${OOPATH}#g' \ + -e 's#%%EXECBASE%%#${EXECBASE}#g' \ ${WRKDIR}/openoffice-wrapper ${INSTALL_SCRIPT} ${WRKDIR}/openoffice-wrapper \ ${STAGEDIR}${PREFIX}/bin/${EXECBASE} @@ -419,38 +419,38 @@ do-install: for app in base calc draw impress math writer; do \ ${REINPLACE_CMD} -e "s/^Exec.*/Exec=${EXECBASE} -$${app} %U/" \ -e "s/^Icon.*/Icon=${EXECBASE}-$${app}.png/" \ - ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR}/${OOODIR}/share/xdg/$${app}.desktop ; \ + ${STAGEDIR}${XDGDIR}/$${app}.desktop ; \ done ${REINPLACE_CMD} -e "s/^Exec.*/Exec=${EXECBASE}-spadmin %U/" \ -e "s/^Icon.*/Icon=${EXECBASE}-printeradmin.png/" \ - ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR}/${OOODIR}/share/xdg/printeradmin.desktop + ${STAGEDIR}${XDGDIR}/printeradmin.desktop ${REINPLACE_CMD} -e "s/^Exec.*/Exec=${EXECBASE} -quickstart -nologo -nodefault/" \ - ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR}/${OOODIR}/share/xdg/startcenter.desktop - ${RM} ${STAGEDIR}${PREFIX}/${INSTALLATION_BASEDIR}/${OOODIR}/share/xdg/*.desktop.bak - ${RM} -f ${STAGEDIR}${DESKTOPDIR}/${EXECBASE} + ${STAGEDIR}${XDGDIR}/startcenter.desktop + ${RM} ${STAGEDIR}${XDGDIR}/*.desktop.bak ${MKDIR} ${STAGEDIR}${DESKTOPDIR} - ${LN} -sf ${PREFIX}/${INSTALLATION_BASEDIR}/${OOODIR}/share/xdg \ - ${STAGEDIR}${DESKTOPDIR}/${EXECBASE} + ${LN} -sf ${XDGDIR} ${STAGEDIR}${DESKTOPDIR}/${EXECBASE} ${ECHO_CMD} "share/applications/${EXECBASE}" >> ${TMPPLIST} - for dir in `ls ${ICONS}/hicolor | ${GREP} -v CVS`; do \ + cd ${ICONS} ; for dir in hicolor/*/apps ; do \ + ${MKDIR} ${STAGEDIR}${PREFIX}/share/icons/$${dir} ; \ for app in base calc draw impress math printeradmin writer; do \ - if [ -r ${ICONS}/hicolor/$${dir}/apps/$${app}.png ]; then \ - ${MKDIR} ${STAGEDIR}${PREFIX}/share/icons/hicolor/$${dir}/apps/ ; \ - ${INSTALL_DATA} ${ICONS}/hicolor/$${dir}/apps/$${app}.png \ - ${STAGEDIR}${PREFIX}/share/icons/hicolor/$${dir}/apps/${EXECBASE}-$${app}.png ; \ - ${ECHO_CMD} "share/icons/hicolor/$${dir}/apps/${EXECBASE}-$${app}.png" >> ${TMPPLIST} ; \ + icon_src=$${dir}/$${app}.png; \ + icon_dst=share/icons/$${dir}/${EXECBASE}-$${app}.png; \ + if [ -r $${icon_src} ]; then \ + ${INSTALL_DATA} $${icon_src} \ + ${STAGEDIR}${PREFIX}/$${icon_dst} ; \ + ${ECHO_CMD} "$${icon_dst}" >> ${TMPPLIST} ; \ fi \ done ; \ - for iconfile in `cd ${ICONS}/hicolor/$${dir}/mimetypes; ls *.png`; do \ - ${MKDIR} ${STAGEDIR}${PREFIX}/share/icons/hicolor/$${dir}/mimetypes/ ; \ - ${INSTALL_DATA} ${ICONS}/hicolor/$${dir}/mimetypes/$${iconfile} \ - ${STAGEDIR}${PREFIX}/share/icons/hicolor/$${dir}/mimetypes/ ; \ - ${ECHO_CMD} "share/icons/hicolor/$${dir}/mimetypes/$${iconfile}" >> ${TMPPLIST} ; \ + done + cd ${ICONS} ; for dir in hicolor/*/mimetypes ; do \ + ${MKDIR} ${STAGEDIR}${PREFIX}/share/icons/$${dir} ; \ + for iconfile in `cd $${dir}; ls *.png`; do \ + icon_dst=share/icons/$${dir}/$${iconfile} ; \ + ${INSTALL_DATA} $${dir}/$${iconfile} \ + ${STAGEDIR}${PREFIX}/$${icon_dst}; \ + ${ECHO_CMD} "$${icon_dst}" >> ${TMPPLIST} ; \ done ; \ done - ${ECHO_CMD} "@unexec ${RM} %D/share/icons/hicolor/icon-theme.cache 2>/dev/null || ${TRUE}" >> ${TMPPLIST} - ${ECHO_CMD} "@exec ${PREFIX}/bin/gtk-update-icon-cache -q -f %D/share/icons/hicolor 2>/dev/null || ${TRUE}" >> ${TMPPLIST} - ${ECHO_CMD} "@unexec ${PREFIX}/bin/gtk-update-icon-cache -q -f %D/share/icons/hicolor 2>/dev/null || ${TRUE}" >> ${TMPPLIST} .include <${FILESDIR}/Makefile.others> Modified: head/editors/openoffice-4/files/openoffice-wrapper ============================================================================== --- head/editors/openoffice-4/files/openoffice-wrapper Thu Sep 10 00:26:28 2015 (r396544) +++ head/editors/openoffice-4/files/openoffice-wrapper Thu Sep 10 00:33:08 2015 (r396545) @@ -1,9 +1,9 @@ #!/bin/sh # -# $FreeBSD: /tmp/pcvs/ports/editors/openoffice-3/files/openoffice-wrapper,v 1.17 2012-05-09 03:48:16 maho Exp $ +# $FreeBSD$ -oopath=%%PREFIX%%/%%INSTALLATION_BASEDIR%%/%%OOODIR%% -program=`echo $0 | sed -e 's|.*-%%OOOVERSION%%-||'` +oopath=%%OOPATH%% +program=`echo $0 | sed -e 's|.*%%EXECBASE%%-||'` case $program in $0)