app-office/scribus: Update live ebuild. Add qt-5.7.0 patch.
authorMichael Weber <xmw@gentoo.org>
Tue, 27 Sep 2016 19:14:23 +0000 (21:14 +0200)
committerMichael Weber <xmw@gentoo.org>
Tue, 27 Sep 2016 19:14:23 +0000 (21:14 +0200)
Package-Manager: portage-2.2.28

app-office/scribus/scribus-1.5.0-r1.ebuild
app-office/scribus/scribus-1.5.2.ebuild
app-office/scribus/scribus-9999.ebuild

index 80f8a77961697f63290d9c0fc69fd3d58a0a3c79..aae0c4c25ca97b2c8be01a2d33fef44b81542d07 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 1999-2015 Gentoo Foundation
+# Copyright 1999-2016 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
@@ -97,6 +97,10 @@ src_prepare() {
                -e 's:\(${CMAKE_INSTALL_PREFIX}\):./\1:g' \
                -i resources/templates/CMakeLists.txt || die
 
+       if has_version ">=dev-qt/qtcore-5.7.0" ; then
+               append-cxxflags "-std=c++11" #bug 591948
+       fi
+
        cmake-utils_src_prepare
 }
 
index 4faa8dec8bcec453bc7599f031119123679c4281..ea8ec9e12c4326ec7ec58df15c8b52a03633cefb 100644 (file)
@@ -167,7 +167,7 @@ src_install() {
        EOF
        dodoc "${T}"/COPYING
        docompress -x /usr/share/doc/${PF}/en /usr/share/doc/${PF}/{AUTHORS,TRANSLATION,LINKS,COPYING}
-       doicon resources/iconsets/1_5_0/scribus.png
+       doicon resources/iconsets/*/scribus.png
        domenu scribus.desktop
 }
 
index 333a994df922455b3d5b4371bbc332041cc8f76b..59b904e29ffe1abeac015d3eb5fe6227fa50a915 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 1999-2015 Gentoo Foundation
+# Copyright 1999-2016 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
@@ -64,7 +64,7 @@ COMMON_DEPEND="
        hunspell? ( app-text/hunspell )
        graphicsmagick? ( media-gfx/graphicsmagick )
        osg? ( dev-games/openscenegraph )
-       pdf? ( app-text/podofo )
+       pdf? ( app-text/podofo:0= )
        scripts? ( dev-python/pillow[tk?,${PYTHON_USEDEP}] )
        tk? ( dev-python/pillow[tk?,${PYTHON_USEDEP}] )
 "
@@ -74,7 +74,9 @@ DEPEND="${COMMON_DEPEND}
        dev-qt/linguist-tools:5
        virtual/pkgconfig"
 
-PATCHES=( "${FILESDIR}"/${PN}-1.5.0-docdir.patch )
+PATCHES=(
+       "${FILESDIR}"/${PN}-1.5.0-docdir.patch
+       )
 
 src_prepare() {
        rm -r codegen/cheetah || die
@@ -96,6 +98,10 @@ src_prepare() {
                -e 's:\(${CMAKE_INSTALL_PREFIX}\):./\1:g' \
                -i resources/templates/CMakeLists.txt || die
 
+       if has_version ">=dev-qt/qtcore-5.7.0" ; then
+               append-cxxflags "-std=c++11" #bug 591948
+       fi
+
        cmake-utils_src_prepare
        subversion_src_prepare
 }
@@ -103,9 +109,9 @@ src_prepare() {
 src_configure() {
        local lang langs
        for lang in ${IUSE_LINGUAS}; do
-               if use linguas_${lang}; then
+               if use linguas_${lang} || [[ ${lang} == "en" ]]; then
                        # From the CMakeLists.txt
-                       # "#Bit of a hack, preprocess all the filenames to generate our language string, needed for -DWANT_GUI_LANG=en_GB,de_DE , etc"
+                       # "#Bit of a hack, preprocess all the filenames to generate our language string, needed for -DWANT_GUI_LANG=en_GB;de_DE , etc"
                        langs+=";${lang}"
                else
                        # Don't install localized documentation
@@ -123,7 +129,7 @@ src_configure() {
                -DPYTHON_LIBRARY="$(python_get_library_path)"
                -DWANT_DISTROBUILD=ON
                -DDOCDIR="/usr/share/doc/${PF}/"
-               -DWANT_GUI_LANG=${langs#;}
+               -DWANT_GUI_LANG="${langs#;};en"
                $(cmake-utils_use_with pdf PODOFO)
                $(cmake-utils_use_with boost)
                $(cmake-utils_use_want graphicsmagick)
@@ -180,21 +186,22 @@ pkg_postrm() {
 }
 
 safe_delete () {
-       if path_exists $2; then
-               case $1 in
-                       dir)
+       case $1 in
+               dir)
+                       if [[ -d "${2}" ]]; then
                                ebegin "Deleting ${2} recursively"
                                rm -r "${2}" || die
                                eend $?
-                               ;;
-                       file)
+                       fi
+                       ;;
+               file)
+                       if [[ -f "${2}" ]]; then
                                ebegin "Deleting ${2}"
                                rm "${2}" || die
                                eend $?
-                               ;;
-                       *)
-                               die "Wrong usage"
-                               ;;
-               esac
-       fi
+                       fi
+                       ;;
+               *)
+                       die "Wrong usage"
+       esac
 }