Merge remote-tracking branch 'github/pr/218'.
[gentoo.git] / kde-plasma / breeze / breeze-5.4.3.ebuild
1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Id$
4
5 EAPI=5
6
7 inherit kde5 multibuild
8
9 DESCRIPTION="Breeze visual style for the Plasma desktop"
10 HOMEPAGE="https://projects.kde.org/projects/kde/workspace/breeze"
11 KEYWORDS=" ~amd64 ~x86"
12 IUSE="qt4"
13
14 DEPEND="
15         $(add_frameworks_dep frameworkintegration)
16         $(add_frameworks_dep kcmutils)
17         $(add_frameworks_dep kconfig)
18         $(add_frameworks_dep kconfigwidgets)
19         $(add_frameworks_dep kcoreaddons)
20         $(add_frameworks_dep kguiaddons)
21         $(add_frameworks_dep ki18n)
22         $(add_frameworks_dep kwidgetsaddons)
23         $(add_frameworks_dep kwindowsystem)
24         $(add_plasma_dep kdecoration)
25         dev-qt/qtdbus:5
26         dev-qt/qtgui:5
27         dev-qt/qtwidgets:5
28         dev-qt/qtx11extras:5
29         x11-libs/libxcb
30         qt4? (
31                 kde-base/kdelibs:4
32                 x11-libs/libX11
33         )
34 "
35 RDEPEND="${DEPEND}
36         $(add_frameworks_dep breeze-icons '' '5.4.3')
37         $(add_plasma_dep kde-cli-tools)
38 "
39
40 pkg_setup() {
41         kde5_pkg_setup
42         MULTIBUILD_VARIANTS=( kf5 $(usev qt4) )
43 }
44
45 src_prepare() {
46         # Disable icons packaged separately in kde-frameworks/breeze-icons
47         sed -i \
48                 -e "/add_subdirectory(icons/ s/^/#/" \
49                 CMakeLists.txt
50
51         kde5_src_prepare
52 }
53
54 src_configure() {
55         myconfigure() {
56                 local mycmakeargs=()
57
58                 if [[ ${MULTIBUILD_VARIANT} = qt4 ]] ; then
59                         mycmakeargs+=( -DUSE_KDE4=true )
60                 fi
61
62                 kde5_src_configure
63         }
64
65         multibuild_foreach_variant myconfigure
66 }
67
68 src_compile() {
69         multibuild_foreach_variant kde5_src_compile
70 }
71
72 src_install() {
73         multibuild_foreach_variant kde5_src_install
74 }