commit:     58786218b1e0b317dff5b9d4dc117178c8fa61f0
Author:     Michael Everitt <m.j.everitt <AT> iee <DOT> org>
AuthorDate: Sun Oct  7 19:05:45 2018 +0000
Commit:     Michael Everitt <m.j.everitt <AT> iee <DOT> org>
CommitDate: Sun Oct  7 19:05:45 2018 +0000
URL:        https://gitweb.gentoo.org/repo/user/veremit.git/commit/?id=58786218

Add scribus qt4 packages

Signed-off-by: Michael Everitt <m.j.everitt <AT> iee.org>

 app-office/scribus/Manifest                        |   2 +
 .../scribus/files/scribus-1.4.0-minizip.patch      |  60 ++++++++
 app-office/scribus/metadata.xml                    |  19 +++
 app-office/scribus/scribus-1.4.6.ebuild            | 171 +++++++++++++++++++++
 app-office/scribus/scribus-1.4.7.ebuild            | 171 +++++++++++++++++++++
 5 files changed, 423 insertions(+)

diff --git a/app-office/scribus/Manifest b/app-office/scribus/Manifest
new file mode 100644
index 0000000..cd5c14e
--- /dev/null
+++ b/app-office/scribus/Manifest
@@ -0,0 +1,2 @@
+DIST scribus-1.4.6.tar.xz 73601104 BLAKE2B 
5968a48410d1a2a4caa333c9f83b43f68c964862d9aa3cb20e136760201ef2ef6cb82f770026b6f962758c9d397f25a017d906433f52f88bec11c57105c27f6b
 SHA512 
74d8a89eb767535bcd8fe5e3c55d03709d59ff8fc5280005bcc2ad36cae1d37c8442ab85abaea86fdee9f351a901c86947231001324e2d8df00cbd8e5c18d1e3
+DIST scribus-1.4.7.tar.xz 72763748 BLAKE2B 
a3daa485cd35164d5055d920d53d1945c2760d48c552a2ce34193d1be2c5dc43e3c7d3c2ac64712f6d33c3b822648a78d8ba68f42c48bd3eb01739e28ec7aca1
 SHA512 
7627a46f0de2a7d4d3d3223e852db2fcdf9af439654cee3130046cd0a9a39f89dc185fc0342d9e03067e996c378929a2fee3f05cefee0b831a823622cf41e957

diff --git a/app-office/scribus/files/scribus-1.4.0-minizip.patch 
b/app-office/scribus/files/scribus-1.4.0-minizip.patch
new file mode 100644
index 0000000..c0a4b7c
--- /dev/null
+++ b/app-office/scribus/files/scribus-1.4.0-minizip.patch
@@ -0,0 +1,60 @@
+ Scribus.pro            |    4 ----
+ scribus/CMakeLists.txt |    2 --
+ 2 files changed, 0 insertions(+), 6 deletions(-)
+
+diff --git a/Scribus.pro b/Scribus.pro
+index 17b5417..0cc23c9 100644
+--- a/Scribus.pro
++++ b/Scribus.pro
+@@ -276,7 +276,6 @@ HEADERS += scribus/about.h \
+            scribus/insertaframe.h \
+            scribus/insertTable.h \
+            scribus/inspage.h \
+-           scribus/ioapi.h \
+            scribus/javadocs.h \
+            scribus/KarbonCurveFit.h \
+            scribus/langmgr.h \
+@@ -496,7 +495,6 @@ HEADERS += scribus/about.h \
+            scribus/undostate.h \
+            scribus/unicodesearch.h \
+            scribus/units.h \
+-           scribus/unzip.h \
+            scribus/updatemanager.h \
+            scribus/upgradechecker.h \
+            scribus/urllauncher.h \
+@@ -933,7 +931,6 @@ SOURCES += scribus/about.cpp \
+            scribus/insertaframe.cpp \
+            scribus/insertTable.cpp \
+            scribus/inspage.cpp \
+-           scribus/ioapi.c \
+            scribus/javadocs.cpp \
+            scribus/KarbonCurveFit.cpp \
+            scribus/langmgr.cpp \
+@@ -1143,7 +1140,6 @@ SOURCES += scribus/about.cpp \
+            scribus/undostate.cpp \
+            scribus/unicodesearch.cpp \
+            scribus/units.cpp \
+-           scribus/unzip.c \
+            scribus/updatemanager.cpp \
+            scribus/upgradechecker.cpp \
+            scribus/urllauncher.cpp \
+diff --git a/scribus/CMakeLists.txt b/scribus/CMakeLists.txt
+index dcd7e10..3aca69b 100644
+--- a/scribus/CMakeLists.txt
++++ b/scribus/CMakeLists.txt
+@@ -405,7 +405,6 @@ SET(SCRIBUS_SOURCES
+   insertTable.cpp
+   insertaframe.cpp
+   inspage.cpp
+-  ioapi.c
+   javadocs.cpp
+   KarbonCurveFit.cpp
+   langmgr.cpp
+@@ -613,7 +612,6 @@ SET(SCRIBUS_SOURCES
+   undostate.cpp
+   unicodesearch.cpp
+   units.cpp
+-  unzip.c
+   updatemanager.cpp
+   upgradechecker.cpp
+   urllauncher.cpp

diff --git a/app-office/scribus/metadata.xml b/app-office/scribus/metadata.xml
new file mode 100644
index 0000000..02d7f56
--- /dev/null
+++ b/app-office/scribus/metadata.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd";>
+<pkgmetadata>
+  <maintainer type="person">
+    <email>j...@gentoo.org</email>
+  </maintainer>
+  <use>
+    <flag name="boost">Enable support for Boost based enhancement</flag>
+    <flag name="hunspell">Enable support for spell checking with 
<pkg>app-text/hunspell</pkg></flag>
+    <flag name="minimal">Don't install headers (only required for e.g. plug-in 
developers)</flag>
+    <flag name="osg">3D redering via <pkg>dev-games/openscenegraph</pkg></flag>
+    <flag name="scripts">Install the scripts</flag>
+    <flag name="templates">Document tamplates</flag>
+    <flag name="tk">Install tk based scripts e.g. FontSample.py</flag>
+  </use>
+  <upstream>
+    <remote-id type="sourceforge">scribus</remote-id>
+  </upstream>
+</pkgmetadata>

diff --git a/app-office/scribus/scribus-1.4.6.ebuild 
b/app-office/scribus/scribus-1.4.6.ebuild
new file mode 100644
index 0000000..0908438
--- /dev/null
+++ b/app-office/scribus/scribus-1.4.6.ebuild
@@ -0,0 +1,171 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="tk?"
+
+inherit cmake-utils fdo-mime python-single-r1
+
+DESCRIPTION="Desktop publishing (DTP) and layout program"
+HOMEPAGE="http://www.scribus.net/";
+SRC_URI="mirror://sourceforge/${PN}/${PV}/${P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 ~hppa ppc ppc64 ~sparc x86"
+IUSE="cairo debug examples hunspell +minimal +pdf scripts templates tk"
+
+# a=$(ls resources/translations/po/scribus.*ts | sed -e 's:\.: :g' | awk 
'{print $2}'); echo ${a}
+# Keep this sorted, otherwise eliminating of duplicates below won't work
+IUSE_L10N=" af ar bg br ca cs_CZ cy da_DK de_1901 de_CH de el en_AU en_GB 
en_US eo es_ES et eu fi fr gl hu id it ja ko lt_LT nb_NO nl pl_PL pt_BR pt ru 
sa sk_SK sl sq sr sv th_TH tr uk zh_CN zh_TW"
+
+map_lang() {
+       local lang=${1/_/-}
+       case $1 in
+               # Retain the following, which have a specific subtag
+               de_*|en_*|pt_*|zh_*) ;;
+               # Consider all other xx_XX as duplicates of the generic xx tag
+               *_*) lang=${1%%_*} ;;
+       esac
+       echo ${lang}
+}
+
+prev_l=
+for l in ${IUSE_L10N}; do
+       l=$(map_lang ${l})
+       [[ ${l} != "${prev_l}" ]] && IUSE+=" l10n_${l}"
+       prev_l=${l}
+done
+unset l prev_l
+
+REQUIRED_USE="
+       ${PYTHON_REQUIRED_USE}
+       tk? ( scripts )"
+
+COMMON_DEPEND="
+       ${PYTHON_DEPS}
+       dev-libs/boost
+       dev-libs/hyphen
+       dev-libs/libxml2
+       dev-qt/qtcore:4
+       dev-qt/qtgui:4
+       media-libs/fontconfig
+       media-libs/freetype:2
+       media-libs/lcms:2
+       media-libs/libpng:0
+       media-libs/tiff:0
+       net-print/cups
+       sys-libs/zlib[minizip]
+       virtual/jpeg:0=
+       cairo? ( x11-libs/cairo[X,svg] )
+       !cairo? ( media-libs/libart_lgpl )
+       hunspell? ( app-text/hunspell )
+       pdf? ( app-text/podofo )
+       scripts? ( dev-python/pillow[tk?,${PYTHON_USEDEP}] )
+       tk? ( dev-python/pillow[tk?,${PYTHON_USEDEP}] )
+"
+RDEPEND="${COMMON_DEPEND}
+       app-text/ghostscript-gpl"
+DEPEND="${COMMON_DEPEND}
+       virtual/pkgconfig"
+
+PATCHES=(
+       "${FILESDIR}"/${PN}-1.4.0-minizip.patch
+       )
+
+src_prepare() {
+       cat > cmake/modules/FindZLIB.cmake <<- EOF
+       find_package(PkgConfig)
+       pkg_check_modules(ZLIB minizip zlib)
+       SET( ZLIB_LIBRARY \${ZLIB_LIBRARIES} )
+       SET( ZLIB_INCLUDE_DIR \${ZLIB_INCLUDE_DIRS} )
+       MARK_AS_ADVANCED( ZLIB_LIBRARY ZLIB_INCLUDE_DIR )
+       EOF
+
+       rm scribus/{ioapi,unzip}.[ch] || die
+
+       sed \
+               -e 's:\(${CMAKE_INSTALL_PREFIX}\):./\1:g' \
+               -i resources/templates/CMakeLists.txt || die
+
+       cmake-utils_src_prepare
+}
+
+src_configure() {
+       local _lang lang langs
+       for _lang in ${IUSE_L10N}; do
+               lang=$(map_lang ${_lang})
+               if use l10n_${lang}; then
+                       langs+=",${_lang}"
+               else
+                       sed -e "/${_lang}/d" -i scribus/doc/CMakeLists.txt || 
die
+               fi
+       done
+
+       local mycmakeargs=(
+               -DHAVE_PYTHON=ON
+               -DPYTHON_INCLUDE_PATH="$(python_get_includedir)"
+               -DPYTHON_LIBRARY="$(python_get_library_path)"
+               -DWANT_NORPATH=ON
+               -DWANT_QT3SUPPORT=OFF
+               -IUSE_LINGUAS=ON
+               -DWANT_GUI_LANG=${langs#,}
+               -DCMAKE_INSTALL_DATAROOTDIR="${EPREFIX}/usr/share"
+               -DTAG_VERSION=-${PVR}
+               $(cmake-utils_use_with pdf PODOFO)
+               $(cmake-utils_use_want cairo)
+               $(cmake-utils_use_want !cairo QTARTHUR)
+               $(cmake-utils_use_want debug DEBUG)
+               $(cmake-utils_use_want minimal NOHEADERINSTALL)
+               $(cmake-utils_use_want hunspell HUNSPELL)
+               $(cmake-utils_use_want !examples NOEXAMPLES)
+               $(cmake-utils_use_want !templates NOTEMPLATES)
+               )
+       cmake-utils_src_configure
+}
+
+src_install() {
+       cmake-utils_src_install
+
+       local _lang lang file
+       for _lang in ${IUSE_L10N}; do
+               lang=$(map_lang ${_lang})
+               file="${ED}"/usr/share/scribus/translations/scribus.${_lang}.qm
+               if ! use l10n_${lang} && [[ -f "${file}" ]]; then
+                       rm "${file}" || die
+               fi
+       done
+
+       if ! use scripts; then
+               rm "${ED}"/usr/share/${PF}/scripts/*.py || die
+       else
+               if ! use tk; then
+                       rm 
"${ED}"/usr/share/${PF}/scripts/{FontSample,CalendarWizard}.py* || die
+               fi
+               python_fix_shebang "${ED}"/usr/share/${PF}/scripts
+               python_optimize "${ED}"/usr/share/${PF}/scripts
+       fi
+
+       mv "${ED}"/usr/share/doc/${PF}/{en,html} || die
+       ln -sf html "${ED}"/usr/share/doc/${PF}/en || die
+       cat >> "${T}"/COPYING <<- EOF
+       ${PN} is licensed under the "${LICENSE}".
+       Please visit https://www.gnu.org/licenses/gpl-2.0.html for the complete 
license text.
+       EOF
+       dodoc "${T}"/COPYING
+       docompress -x /usr/share/doc/${PF}/en 
/usr/share/doc/${PF}/{AUTHORS,TRANSLATION,LINKS,COPYING}
+       doicon resources/icons/scribus.png
+       domenu scribus.desktop
+}
+
+pkg_postinst() {
+       fdo-mime_desktop_database_update
+       fdo-mime_mime_database_update
+}
+
+pkg_postrm() {
+       fdo-mime_desktop_database_update
+       fdo-mime_mime_database_update
+}

diff --git a/app-office/scribus/scribus-1.4.7.ebuild 
b/app-office/scribus/scribus-1.4.7.ebuild
new file mode 100644
index 0000000..cfd29c7
--- /dev/null
+++ b/app-office/scribus/scribus-1.4.7.ebuild
@@ -0,0 +1,171 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="tk?"
+
+inherit cmake-utils fdo-mime python-single-r1
+
+DESCRIPTION="Desktop publishing (DTP) and layout program"
+HOMEPAGE="http://www.scribus.net/";
+SRC_URI="mirror://sourceforge/${PN}/${PV}/${P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
+IUSE="cairo debug examples hunspell +minimal +pdf scripts templates tk"
+
+# a=$(ls resources/translations/po/scribus.*ts | sed -e 's:\.: :g' | awk 
'{print $2}'); echo ${a}
+# Keep this sorted, otherwise eliminating of duplicates below won't work
+IUSE_L10N=" af ar bg br ca cs_CZ cy da_DK de_1901 de_CH de el en_AU en_GB 
en_US eo es_ES et eu fi fr gl hu id it ja ko lt_LT nb_NO nl pl_PL pt_BR pt ru 
sa sk_SK sl sq sr sv th_TH tr uk zh_CN zh_TW"
+
+map_lang() {
+       local lang=${1/_/-}
+       case $1 in
+               # Retain the following, which have a specific subtag
+               de_*|en_*|pt_*|zh_*) ;;
+               # Consider all other xx_XX as duplicates of the generic xx tag
+               *_*) lang=${1%%_*} ;;
+       esac
+       echo ${lang}
+}
+
+prev_l=
+for l in ${IUSE_L10N}; do
+       l=$(map_lang ${l})
+       [[ ${l} != "${prev_l}" ]] && IUSE+=" l10n_${l}"
+       prev_l=${l}
+done
+unset l prev_l
+
+REQUIRED_USE="
+       ${PYTHON_REQUIRED_USE}
+       tk? ( scripts )"
+
+COMMON_DEPEND="
+       ${PYTHON_DEPS}
+       dev-libs/boost
+       dev-libs/hyphen
+       dev-libs/libxml2
+       dev-qt/qtcore:4
+       dev-qt/qtgui:4
+       media-libs/fontconfig
+       media-libs/freetype:2
+       media-libs/lcms:2
+       media-libs/libpng:0
+       media-libs/tiff:0
+       net-print/cups
+       sys-libs/zlib[minizip]
+       virtual/jpeg:0=
+       cairo? ( x11-libs/cairo[X,svg] )
+       !cairo? ( media-libs/libart_lgpl )
+       hunspell? ( app-text/hunspell )
+       pdf? ( app-text/podofo )
+       scripts? ( dev-python/pillow[tk?,${PYTHON_USEDEP}] )
+       tk? ( dev-python/pillow[tk?,${PYTHON_USEDEP}] )
+"
+RDEPEND="${COMMON_DEPEND}
+       app-text/ghostscript-gpl"
+DEPEND="${COMMON_DEPEND}
+       virtual/pkgconfig"
+
+PATCHES=(
+       "${FILESDIR}"/${PN}-1.4.0-minizip.patch
+       )
+
+src_prepare() {
+       cat > cmake/modules/FindZLIB.cmake <<- EOF
+       find_package(PkgConfig)
+       pkg_check_modules(ZLIB minizip zlib)
+       SET( ZLIB_LIBRARY \${ZLIB_LIBRARIES} )
+       SET( ZLIB_INCLUDE_DIR \${ZLIB_INCLUDE_DIRS} )
+       MARK_AS_ADVANCED( ZLIB_LIBRARY ZLIB_INCLUDE_DIR )
+       EOF
+
+       rm scribus/{ioapi,unzip}.[ch] || die
+
+       sed \
+               -e 's:\(${CMAKE_INSTALL_PREFIX}\):./\1:g' \
+               -i resources/templates/CMakeLists.txt || die
+
+       cmake-utils_src_prepare
+}
+
+src_configure() {
+       local _lang lang langs
+       for _lang in ${IUSE_L10N}; do
+               lang=$(map_lang ${_lang})
+               if use l10n_${lang}; then
+                       langs+=",${_lang}"
+               else
+                       sed -e "/${_lang}/d" -i scribus/doc/CMakeLists.txt || 
die
+               fi
+       done
+
+       local mycmakeargs=(
+               -DHAVE_PYTHON=ON
+               -DPYTHON_INCLUDE_PATH="$(python_get_includedir)"
+               -DPYTHON_LIBRARY="$(python_get_library_path)"
+               -DWANT_NORPATH=ON
+               -DWANT_QT3SUPPORT=OFF
+               -IUSE_LINGUAS=ON
+               -DWANT_GUI_LANG=${langs#,}
+               -DCMAKE_INSTALL_DATAROOTDIR="${EPREFIX}/usr/share"
+               -DTAG_VERSION=-${PVR}
+               $(cmake-utils_use_with pdf PODOFO)
+               $(cmake-utils_use_want cairo)
+               $(cmake-utils_use_want !cairo QTARTHUR)
+               $(cmake-utils_use_want debug DEBUG)
+               $(cmake-utils_use_want minimal NOHEADERINSTALL)
+               $(cmake-utils_use_want hunspell HUNSPELL)
+               $(cmake-utils_use_want !examples NOEXAMPLES)
+               $(cmake-utils_use_want !templates NOTEMPLATES)
+               )
+       cmake-utils_src_configure
+}
+
+src_install() {
+       cmake-utils_src_install
+
+       local _lang lang file
+       for _lang in ${IUSE_L10N}; do
+               lang=$(map_lang ${_lang})
+               file="${ED}"/usr/share/scribus/translations/scribus.${_lang}.qm
+               if ! use l10n_${lang} && [[ -f "${file}" ]]; then
+                       rm "${file}" || die
+               fi
+       done
+
+       if ! use scripts; then
+               rm "${ED}"/usr/share/${PF}/scripts/*.py || die
+       else
+               if ! use tk; then
+                       rm 
"${ED}"/usr/share/${PF}/scripts/{FontSample,CalendarWizard}.py* || die
+               fi
+               python_fix_shebang "${ED}"/usr/share/${PF}/scripts
+               python_optimize "${ED}"/usr/share/${PF}/scripts
+       fi
+
+       mv "${ED}"/usr/share/doc/${PF}/{en,html} || die
+       ln -sf html "${ED}"/usr/share/doc/${PF}/en || die
+       cat >> "${T}"/COPYING <<- EOF
+       ${PN} is licensed under the "${LICENSE}".
+       Please visit https://www.gnu.org/licenses/gpl-2.0.html for the complete 
license text.
+       EOF
+       dodoc "${T}"/COPYING
+       docompress -x /usr/share/doc/${PF}/en 
/usr/share/doc/${PF}/{AUTHORS,TRANSLATION,LINKS,COPYING}
+       doicon resources/icons/scribus.png
+       domenu scribus.desktop
+}
+
+pkg_postinst() {
+       fdo-mime_desktop_database_update
+       fdo-mime_mime_database_update
+}
+
+pkg_postrm() {
+       fdo-mime_desktop_database_update
+       fdo-mime_mime_database_update
+}

Reply via email to