Gentoo Archives: gentoo-commits

From: Maciej Mrozowski <reavertm@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: kde-plasma/plasma-workspace/
Date: Mon, 25 Nov 2019 00:33:35
Message-Id: 1574641977.bdb0f5267d00191069c4bf88b98fe759441a2a2b.reavertm@gentoo
1 commit: bdb0f5267d00191069c4bf88b98fe759441a2a2b
2 Author: Maciej Mrozowski <reavertm <AT> gentoo <DOT> org>
3 AuthorDate: Tue Nov 12 23:39:50 2019 +0000
4 Commit: Maciej Mrozowski <reavertm <AT> gentoo <DOT> org>
5 CommitDate: Mon Nov 25 00:32:57 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bdb0f526
7
8 kde-plasma/plasma-workspace: migrate {ssh,gpg}-agent scripts to new layout
9
10 Bug: https://bugs.gentoo.org/688366
11 Package-Manager: Portage-2.3.76, Repoman-2.3.16
12 Signed-off-by: Maciej Mrozowski <reavertm <AT> gentoo.org>
13
14 .../plasma-workspace-5.17.3-r1.ebuild | 205 +++++++++++++++++++++
15 1 file changed, 205 insertions(+)
16
17 diff --git a/kde-plasma/plasma-workspace/plasma-workspace-5.17.3-r1.ebuild b/kde-plasma/plasma-workspace/plasma-workspace-5.17.3-r1.ebuild
18 new file mode 100644
19 index 00000000000..642b9c76cca
20 --- /dev/null
21 +++ b/kde-plasma/plasma-workspace/plasma-workspace-5.17.3-r1.ebuild
22 @@ -0,0 +1,205 @@
23 +# Copyright 1999-2019 Gentoo Authors
24 +# Distributed under the terms of the GNU General Public License v2
25 +
26 +EAPI=7
27 +
28 +ECM_HANDBOOK="forceoptional"
29 +ECM_TEST="forceoptional"
30 +KFMIN=5.64.0
31 +PVCUT=$(ver_cut 1-3)
32 +QTMIN=5.12.3
33 +VIRTUALX_REQUIRED="test"
34 +inherit ecm kde.org
35 +
36 +DESCRIPTION="KDE Plasma workspace"
37 +
38 +LICENSE="GPL-2" # TODO: CHECK
39 +SLOT="5"
40 +KEYWORDS="~amd64 ~arm ~arm64 ~x86"
41 +IUSE="appstream +calendar geolocation gps qalculate qrcode +semantic-desktop systemd"
42 +
43 +REQUIRED_USE="gps? ( geolocation )"
44 +
45 +# drop qtgui subslot operator when QT_MINIMAL >= 5.14.0
46 +COMMON_DEPEND="
47 + >=kde-frameworks/kactivities-${KFMIN}:5
48 + >=kde-frameworks/kactivities-stats-${KFMIN}:5
49 + >=kde-frameworks/kauth-${KFMIN}:5
50 + >=kde-frameworks/kbookmarks-${KFMIN}:5
51 + >=kde-frameworks/kcompletion-${KFMIN}:5
52 + >=kde-frameworks/kconfig-${KFMIN}:5
53 + >=kde-frameworks/kconfigwidgets-${KFMIN}:5
54 + >=kde-frameworks/kcoreaddons-${KFMIN}:5
55 + >=kde-frameworks/kcrash-${KFMIN}:5
56 + >=kde-frameworks/kdbusaddons-${KFMIN}:5
57 + >=kde-frameworks/kdeclarative-${KFMIN}:5
58 + >=kde-frameworks/kded-${KFMIN}:5
59 + >=kde-frameworks/kdelibs4support-${KFMIN}:5
60 + >=kde-frameworks/kglobalaccel-${KFMIN}:5
61 + >=kde-frameworks/kguiaddons-${KFMIN}:5
62 + >=kde-frameworks/ki18n-${KFMIN}:5
63 + >=kde-frameworks/kiconthemes-${KFMIN}:5
64 + >=kde-frameworks/kidletime-${KFMIN}:5
65 + >=kde-frameworks/kio-${KFMIN}:5
66 + >=kde-frameworks/kitemmodels-${KFMIN}:5
67 + >=kde-frameworks/kitemviews-${KFMIN}:5
68 + >=kde-frameworks/kjobwidgets-${KFMIN}:5
69 + >=kde-frameworks/knewstuff-${KFMIN}:5
70 + >=kde-frameworks/knotifications-${KFMIN}:5
71 + >=kde-frameworks/knotifyconfig-${KFMIN}:5
72 + >=kde-frameworks/kpackage-${KFMIN}:5
73 + >=kde-frameworks/kpeople-${KFMIN}:5
74 + >=kde-frameworks/krunner-${KFMIN}:5
75 + >=kde-frameworks/kservice-${KFMIN}:5
76 + >=kde-frameworks/ktexteditor-${KFMIN}:5
77 + >=kde-frameworks/ktextwidgets-${KFMIN}:5
78 + >=kde-frameworks/kwallet-${KFMIN}:5
79 + >=kde-frameworks/kwayland-${KFMIN}:5
80 + >=kde-frameworks/kwidgetsaddons-${KFMIN}:5
81 + >=kde-frameworks/kwindowsystem-${KFMIN}:5
82 + >=kde-frameworks/kxmlgui-${KFMIN}:5
83 + >=kde-frameworks/plasma-${KFMIN}:5
84 + >=kde-frameworks/solid-${KFMIN}:5
85 + >=kde-plasma/kscreenlocker-${PVCUT}:5
86 + >=kde-plasma/kwin-${PVCUT}:5
87 + >=kde-plasma/libkscreen-${PVCUT}:5
88 + >=kde-plasma/libksysguard-${PVCUT}:5
89 + >=kde-plasma/libkworkspace-${PVCUT}:5
90 + >=dev-qt/qtdbus-${QTMIN}:5
91 + >=dev-qt/qtdeclarative-${QTMIN}:5[widgets]
92 + >=dev-qt/qtgui-${QTMIN}:5=[jpeg]
93 + >=dev-qt/qtnetwork-${QTMIN}:5
94 + >=dev-qt/qtsql-${QTMIN}:5
95 + >=dev-qt/qtwidgets-${QTMIN}:5
96 + >=dev-qt/qtx11extras-${QTMIN}:5
97 + >=dev-qt/qtxml-${QTMIN}:5
98 + media-libs/phonon[qt5(+)]
99 + sys-libs/zlib
100 + x11-libs/libICE
101 + x11-libs/libSM
102 + x11-libs/libX11
103 + x11-libs/libXau
104 + x11-libs/libxcb
105 + x11-libs/libXfixes
106 + x11-libs/libXrender
107 + x11-libs/libXtst
108 + x11-libs/xcb-util
109 + x11-libs/xcb-util-image
110 + appstream? ( dev-libs/appstream[qt5] )
111 + calendar? ( >=kde-frameworks/kholidays-${KFMIN}:5 )
112 + geolocation? ( >=kde-frameworks/networkmanager-qt-${KFMIN}:5 )
113 + gps? ( sci-geosciences/gpsd )
114 + qalculate? ( sci-libs/libqalculate:= )
115 + qrcode? ( >=kde-frameworks/prison-${KFMIN}:5 )
116 + semantic-desktop? ( >=kde-frameworks/baloo-${KFMIN}:5 )
117 +"
118 +DEPEND="${COMMON_DEPEND}
119 + >=dev-qt/qtconcurrent-${QTMIN}:5
120 + x11-base/xorg-proto
121 +"
122 +RDEPEND="${COMMON_DEPEND}
123 + >=kde-frameworks/kdesu-${KFMIN}:5
124 + >=kde-frameworks/kirigami-${KFMIN}:5
125 + >=kde-apps/kio-extras-19.04.3:5
126 + >=kde-plasma/ksysguard-${PVCUT}:5
127 + >=kde-plasma/milou-${PVCUT}:5
128 + >=kde-plasma/plasma-integration-${PVCUT}:5
129 + >=dev-qt/qdbus-${QTMIN}:5
130 + >=dev-qt/qtgraphicaleffects-${QTMIN}:5
131 + >=dev-qt/qtpaths-${QTMIN}:5
132 + >=dev-qt/qtquickcontrols-${QTMIN}:5[widgets]
133 + >=dev-qt/qtquickcontrols2-${QTMIN}:5
134 + app-text/iso-codes
135 + x11-apps/xmessage
136 + x11-apps/xprop
137 + x11-apps/xrdb
138 + x11-apps/xsetroot
139 + systemd? ( sys-apps/dbus[user-session] )
140 + !systemd? ( sys-apps/dbus )
141 + !<kde-plasma/plasma-desktop-5.16.80:5
142 +"
143 +PDEPEND="
144 + >=kde-plasma/kde-cli-tools-${PVCUT}:5
145 +"
146 +
147 +PATCHES=(
148 + "${FILESDIR}/${PN}-5.14.2-split-libkworkspace.patch"
149 + "${FILESDIR}/${PN}-5.17.2-waylandsessionrename.patch"
150 +)
151 +
152 +RESTRICT+=" test"
153 +
154 +# used for agent scripts migration
155 +OLDST=/etc/plasma/startup/10-agent-startup.sh
156 +NEWST=/etc/xdg/plasma-workspace/env/10-agent-startup.sh
157 +OLDSH=/etc/plasma/shutdown/10-agent-shutdown.sh
158 +NEWSH=/etc/xdg/plasma-workspace/shutdown/10-agent-shutdown.sh
159 +
160 +src_prepare() {
161 + ecm_src_prepare
162 +
163 + cmake_comment_add_subdirectory libkworkspace
164 + # delete colliding libkworkspace translations
165 + if [[ ${KDE_BUILD_TYPE} = release ]]; then
166 + find po -type f -name "*po" -and -name "libkworkspace*" -delete || die
167 + fi
168 +}
169 +
170 +src_configure() {
171 + local mycmakeargs=(
172 + -DBUILD_xembed-sni-proxy=OFF
173 + $(cmake-utils_use_find_package appstream AppStreamQt)
174 + $(cmake-utils_use_find_package calendar KF5Holidays)
175 + $(cmake-utils_use_find_package geolocation KF5NetworkManagerQt)
176 + $(cmake-utils_use_find_package qalculate Qalculate)
177 + $(cmake-utils_use_find_package qrcode KF5Prison)
178 + $(cmake-utils_use_find_package semantic-desktop KF5Baloo)
179 + )
180 +
181 + use gps && mycmakeargs+=( $(cmake-utils_use_find_package gps libgps) )
182 +
183 + ecm_src_configure
184 +}
185 +
186 +src_install() {
187 + ecm_src_install
188 +
189 + # default startup and shutdown scripts
190 + insinto "$(dirname ${NEWST})"
191 + doins "${FILESDIR}/$(basename ${NEWST})"
192 +
193 + insinto "$(dirname ${NEWSH})"
194 + doins "${FILESDIR}/$(basename ${NEWSH})"
195 + fperms +x "${NEWSH}"
196 +}
197 +
198 +pkg_preinst() {
199 + ecm_pkg_preinst
200 +
201 + # migrate existing agent scripts to new layout if no files there yet
202 + if [[ -r "${EROOT}${OLDST}" && ! -f "${EROOT}${NEWST}" ]]; then
203 + mkdir -p "${EROOT}$(dirname ${NEWST})" && cp "${EROOT}${OLDST}" "${EROOT}${NEWST}" && \
204 + elog "${EROOT}${OLDST} has been migrated to ${EROOT}${NEWST}, please delete old file."
205 + fi
206 + if [[ -r "${EROOT}${OLDSH}" && ! -f "${EROOT}${NEWSH}" ]]; then
207 + mkdir -p "${EROOT}$(dirname ${NEWSH})" && cp "${EROOT}${OLDSH}" "${EROOT}${NEWSH}" && \
208 + chmod +x "${EROOT}${NEWSH}" && \
209 + elog "${EROOT}${OLDSH} has been migrated to ${EROOT}${NEWSH}, please delete old file."
210 + fi
211 +}
212 +
213 +pkg_postinst () {
214 + ecm_pkg_postinst
215 +
216 + # warn about any leftover user scripts
217 + if [[ -d "${EROOT}"/etc/plasma/startup && -n "$(ls "${EROOT}"/etc/plasma/startup)" ]] || \
218 + [[ -d "${EROOT}"/etc/plasma/shutdown && -n "$(ls "${EROOT}"/etc/plasma/shutdown)" ]]; then
219 + elog "You appear to have scripts in ${EROOT}/etc/plasma/{startup,shutdown}."
220 + elog "They will no longer work since plasma-workspace-5.17"
221 + fi
222 +
223 + elog " * Edit ${EROOT}${NEWST} and uncomment"
224 + elog " the lines enabling ssh-agent."
225 + elog " * Edit ${EROOT}${NEWSH} uncomment"
226 + elog " the respective lines to properly kill the agent when the session ends."
227 +}