Scribus: Optionally depend on qt-webkit
[gentoo-overlay-ibormuth.git] / app-office / scribus / scribus-9999.ebuild
blobf910e883b93c4a68afc997ad3acfd951b935f5da
1 # Copyright 1999-2009 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: $
5 EAPI=1
7 inherit qt4 eutils subversion
9 ESVN_REPO_URI="svn://scribus.info/Scribus/trunk/Scribus"
11 DESCRIPTION="Desktop Publishing (DTP) and Layout program for Linux."
12 HOMEPAGE="http://www.scribus.net"
13 SRC_URI=""
14 SLOT="svn"
15 LICENSE="GPL-2"
16 KEYWORDS=""
17 IUSE="doc latex gnuplot spell webkit"
19 DEPEND="dev-util/cmake
20 >=x11-libs/qt-gui-4.4
21 webkit? ( x11-libs/qt-webkit )
22 media-libs/freetype
23 x11-libs/cairo
24 media-libs/tiff
25 >=media-libs/lcms-1.15
26 media-libs/jpeg
27 media-libs/libpng
28 dev-libs/libxml2
29 media-libs/libart_lgpl
30 spell? ( app-text/aspell )
31 latex? ( virtual/latex-base )
32 gnuplot? ( sci-visualization/gnuplot )"
34 RDEPEND="${DEPEND}
35 virtual/ghostscript"
37 pkg_setup() {
38 if ! built_with_use 'x11-libs/cairo' 'X' 'svg'; then
39 eerror "You must build cairo with X and svg support"
40 die "x11-libs/cairo built without X and/or svg"
41 fi
42 }
44 src_compile() {
45 # Install into /opt/scribus-svn to avoid slot collision:
46 cmake -DCMAKE_INSTALL_PREFIX:PATH=/optsvn || die "cmake failed"
47 emake || die "make failed"
49 }
51 src_install() {
52 emake DESTDIR="${D}" install || die "install failed"
54 dodoc AUTHORS ChangeLog README TODO
56 if use doc ; then
57 emake -C devel-doc || die "make docs failed"
58 dohtml -r devel-doc/*
59 fi
61 # Rename additional files to avoid slot collision:
62 cp scribus/icons/scribus.png scribus-svn.png && \
63 doicon scribus-svn.png && \
64 sed -e 's/Name=Scribus/Name=Scribus-SVN/' -i scribus.desktop && \
65 sed -e 's/Icon=scribus/Icon=scribus-svn/' -i scribus.desktop && \
66 mv scribus.desktop scribus-svn.desktop && \
67 domenu scribus-svn.desktop || \
68 eerror "Failed to generate menu entry."
69 }
71 pkg_postrm() {
72 ewarn "BIG FAT WARNING: This development version of scribus."
73 echo
74 ewarn "The file format of scribus >=1.3.4 is _NOT_ backwards compatible"
75 ewarn "with the stable 1.3.3.x versions !!!"
76 }