net-im/skype: add skype-2 with qt-4.4 DEPEND and USE-check.
[gentoo-soor-overlay.git] / eclass / qt4-qt-copy.eclass
blobdc4988ed583db2d1e880f54a6a8eeca74ca45b71
1 # Copyright 2008 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: $
5 EAPI="1"
7 # @ECLASS: qt4-qt-copy.eclass
8 # @MAINTAINER:
9 # Leonardo Valeri Manera <l.valerimanera@gmail.com>
10 # @BLURB: Eclass for Qt4 split ebuilds with qt-copy
11 # @DESCRIPTION:
12 # This eclass contains overlays the standard qt4-build eclass
13 # with an optional function that applies qt-copy patches,
14 # either from a tarball or from svn trunk.
16 inherit eutils qt4-build
18 case ${PN},${PVR} in
19 *,4.4.0_rc1)
20 QT_COPY_PV="1.0"
22 *,*)
23 eerror "${PN}-${PVR} does not have patchset defined in the qt4-qt-copy eclass!"
24 die "Unsupported package-version for patchset, something screwed up bad, boss."
26 esac
28 if [[ -n ${QT_COPY_PV} ]]; then
29 IUSE="${IUSE} +qt-copy"
30 SRC_URI="${SRC_URI} qt-copy? ( http://jyujin.de/~creidiki/qt-copy/qt-copy-${PV}-patches-${QT_COPY_PV}.tar.lzma )"
31 DEPEND="qt-copy? ( app-arch/lzma-utils )"
34 qt4_qt-copy() {
35 # sed -e 's:[0-9]*:&_all_:' -e 's:_all_-:_all_:'
37 case ${PVR} in
38 4.4.0_rc1)
39 base_patches="
40 0216_all_allow-isystem-for-headers.diff"
41 qt_assistant_patches="${base_patches}"
42 qt_opengl_patches="${base_patches}"
43 qt_phonon_patches="${base_patches}"
44 qt_sql_patches="${base_patches}"
45 qt_svg_patches="${base_patches}"
46 qt_test_patches="${base_patches}"
47 qt_webkit_patches="${base_patches}"
48 qt_xmlpatterns_patches="${base_patches}"
49 qt_script_patches="${base_patches}
50 0118_all_qtcopy-define.diff
51 0180_all_window-role-corelib.diff
52 0209_all_prevent-qt-mixing.diff"
53 qt_core_patches="${qt_script_patches}
54 0167_all_fix-group-reading.diff"
55 qt_dbus_patches="${qt_core_patches}"
56 qt_gui_patches="${base_patches}
57 0180_all_window-role-gui.diff
58 0191_all_listview-alternate-row-colors.diff
59 0192_all_itemdelegate-palette-state.diff
60 0195_all_compositing-properties.diff
61 0203_all_qtexthtmlparser-link-color.diff
62 0214_all_fix-qgraphicsproxywidget-tab-crash.diff
63 0220_all_no-x-recursion-in-xerrhandler.diff
64 0223_all_fix-qpixmap-hasalpha.diff
65 0224_all_fast-qpixmap-fill.diff
66 0225_all_invalidate-tabbar-geometry-on-refresh.diff
67 0226_all_qtreeview-column_resize_when_needed.diff"
68 qt_qt3support_patches="${base_patches}
69 0210_all_fix-crash-q3stylesheet-font-size.diff"
72 eerror "Version ${PVR} is not supported by the qt4-qt-copy eclass!"
73 die "Unsupported version for patching, something screwed up bad, boss."
75 esac
77 qt_copy_patches="${PN//-/_}_patches"
78 qt_copy_files=""
79 for qt_copy_patch in ${!qt_copy_patches}; do
80 qt_copy_files="${qt_copy_files} patches/${qt_copy_patch}"
81 done
82 qt_copy_files="${qt_copy_files# }"
84 cd "${S}"
86 echo "lzma -dc ${DISTDIR}/qt-copy-${PV}-patches-${QT_COPY_PV}.tar.lzma | tar xf - --no-same-owner ${qt_copy_files}"
87 lzma -dc "${DISTDIR}"/qt-copy-${PV}-patches-${QT_COPY_PV}.tar.lzma | tar xf - --no-same-owner ${qt_copy_files}
89 EPATCH_MULTI_MSG="Applying QT-copy patches ..." \
90 EPATCH_FORCE="yes" EPATCH_SUFFIX="" epatch "${S}"/patches
93 qt4-qt-copy_src_unpack() {
94 qt4-build_src_unpack
95 use qt-copy && qt4_qt-copy
98 qt4-qt-copy_pkg_postinst() {
99 qt4-build_pkg_postinst
100 if use qt-copy; then
101 ewarn
102 ewarn "Do NOT report bugs to Gentoo's bugzilla when built with qt-copy!"
103 ewarn
107 EXPORT_FUNCTIONS src_unpack pkg_postinst