Diff boinc-7.24.1-r2 with a boinc-8.2.4

/usr/portage/sci-misc/boinc/boinc-8.2.4.ebuild 2026-05-27 19:17:04.715635457 +0300
1
# Copyright 2023-2025 Gentoo Authors
1
# Copyright 2023-2026 Gentoo Authors
2 2
# Distributed under the terms of the GNU General Public License v2
3 3

  
4 4
EAPI=8
......
6 6
MY_PV=$(ver_cut 1-2)
7 7
WX_GTK_VER=3.2-gtk3
8 8

  
9
inherit autotools desktop flag-o-matic linux-info optfeature wxwidgets xdg-utils
9
inherit autotools bash-completion-r1 linux-info optfeature wxwidgets xdg-utils
10 10

  
11 11
DESCRIPTION="The Berkeley Open Infrastructure for Network Computing"
12 12
HOMEPAGE="https://boinc.berkeley.edu/"
13 13

  
14
SRC_URI="X? ( https://boinc.berkeley.edu/logo/boinc_glossy2_512_F.tif -> ${PN}.tif )"
15 14
if [[ ${PV} == *9999 ]] ; then
16 15
	EGIT_REPO_URI="https://github.com/BOINC/${PN}.git"
17 16
	inherit git-r3
18 17
else
19
	SRC_URI+=" https://github.com/BOINC/boinc/archive/client_release/${MY_PV}/${PV}.tar.gz -> ${P}.tar.gz"
20
	KEYWORDS="amd64 arm64 ~ppc ppc64 ~sparc ~x86"
18
	SRC_URI="https://github.com/BOINC/boinc/archive/client_release/${MY_PV}/${PV}.tar.gz -> ${P}.tar.gz"
21 19
	S="${WORKDIR}/${PN}-client_release-${MY_PV}-${PV}"
20

  
21
	# We don't mark "stable" and "alpha" release channels in any special way but
22
	# use stable/testing keywords instead.
23
	#
24
	# "Alpha" versions are only named as such, they are actually more like beta
25
	# versions or release candidates.
26
	# https://github.com/BOINC/boinc/wiki/AlphaInstructions
27
	#
28
	# The current versions for each of release channels can be found at:
29
	# https://boinc.berkeley.edu/linux_install.php
30
	KEYWORDS="amd64 arm64 ~ppc ppc64 ~sparc ~x86"
22 31
fi
23 32

  
24 33
LICENSE="LGPL-3+"
25 34
SLOT="0"
26 35

  
27
IUSE="X cuda curl_ssl_gnutls +curl_ssl_openssl opencl"
28

  
29
REQUIRED_USE="
30
	^^ ( curl_ssl_gnutls curl_ssl_openssl )
31
"
36
# - "X" builds idle tracking via XScrnSaver and the libboinc_graphics2 library
37
# - "gui" builds the manager app and the screensaver
38
IUSE="X gui selinux"
32 39

  
33
# libcurl must not be using an ssl backend boinc does not support.
34
# If the libcurl ssl backend changes, boinc should be recompiled.
35 40
DEPEND="
36
	acct-user/boinc
41
	>=acct-user/boinc-1
37 42
	app-misc/ca-certificates
38 43
	dev-libs/openssl:=
39
	net-misc/curl[curl_ssl_gnutls(-)=,curl_ssl_openssl(-)=,-curl_ssl_axtls(-),-curl_ssl_cyassl(-)]
44
	net-misc/curl[ssl]
40 45
	virtual/zlib:=
41
	cuda? (
42
		x11-drivers/nvidia-drivers
43
	)
44
	opencl? (
45
		virtual/opencl
46
	)
47 46
	X? (
48
		dev-libs/glib:2
49 47
		media-libs/freeglut
50 48
		media-libs/libjpeg-turbo:=
51
		x11-libs/gtk+:3
52
		x11-libs/libnotify
53 49
		x11-libs/libX11
54 50
		x11-libs/libXScrnSaver
51
	)
52
	gui? (
53
		dev-libs/glib:2
54
		x11-libs/gtk+:3
55
		x11-libs/libnotify
55 56
		x11-libs/libxcb:=
56
		x11-libs/wxGTK:${WX_GTK_VER}=[X,opengl,webkit]
57
		x11-libs/wxGTK:${WX_GTK_VER}=[opengl,webkit]
57 58
		x11-libs/xcb-util
58 59
	)
59 60
"
60
BDEPEND="app-text/docbook-xml-dtd:4.4
61
	app-text/docbook2X
62
	sys-devel/gettext
63
	X? ( virtual/imagemagick-tools[png,tiff] )
64
"
65 61
RDEPEND="
66 62
	${DEPEND}
67
	sys-apps/util-linux
68
	!app-admin/quickswitch
63
	selinux? ( sec-policy/selinux-boinc )
64
"
65
BDEPEND="
66
	app-text/docbook-xml-dtd:4.4
67
	app-text/docbook2X
68
	virtual/pkgconfig
69 69
"
70 70

  
71 71
pkg_setup() {
......
101 101
}
102 102

  
103 103
src_configure() {
104
	use X && setup-wxwidgets
105

  
106
	append-libs -L"${ESYSROOT}"/usr/$(get_libdir) -L"${ESYSROOT}"/$(get_libdir)
104
	use gui && setup-wxwidgets
107 105

  
108 106
	local myeconfargs=(
109 107
		--disable-server
110 108
		--enable-client
111 109
		--enable-dynamic-client-linkage
112
		--disable-static
113 110
		--enable-unicode
114 111
		--with-ssl
112
		$(usex X "" ax_cv_check_glut_libglut="no")
115 113
		$(use_with X x)
116
		$(use_enable X manager)
117
		$(usex X --with-wx-config="${WX_CONFIG}" --without-wxdir)
114
		$(use_enable gui manager)
115
		$(usex gui --with-wx-config="${WX_CONFIG}" --without-wxdir)
118 116
	)
119 117
	econf "${myeconfargs[@]}"
120 118
}
......
122 120
src_install() {
123 121
	default
124 122

  
125
	keepdir /var/lib/${PN}
126

  
127
	if use X; then
128
		# Create new icons. bug 593362
129
		local s SIZES=(16 22 24 32 36 48 64 72 96 128 192 256)
130
		for s in "${SIZES[@]}"; do
131
			# The convert command is not checked, because it will issue warnings and exit with
132
			# an error code if imagemagick is used and was merged with USE="-xml", although the
133
			# conversion has worked. See #766093
134
			# Instead, newicon will fail if the conversion did not produce the icon.
135
			convert "${DISTDIR}"/${PN}.tif -resize ${s}x${s} "${WORKDIR}"/boinc_${s}.png
136
			newicon -s $s "${WORKDIR}"/boinc_${s}.png boinc.png
137
		done
138
		make_desktop_entry boincmgr "${PN}" "${PN}" "Math;Science" "Path=/var/lib/${PN}"
139

  
140
		# Rename the desktop file to boincmgr.desktop to (hot)fix bug 599910
141
		mv "${ED}"/usr/share/applications/boincmgr{-${PN},}.desktop || \
142
			die "Failed to rename desktop file"
143
	fi
144

  
145 123
	# cleanup cruft
146 124
	rm -r "${ED}"/etc || die "rm failed"
147
	find "${D}" -name '*.la' -delete || die "Removing .la files failed"
125
	find "${D}/usr/$(get_libdir)" -name '*.la' -delete || die "Removing .la files failed"
126
	find "${D}/usr/$(get_libdir)" -name '*.a' -delete || die "Removing static libs failed"
148 127

  
149
	newinitd "${FILESDIR}"/${PN}.init ${PN}
150
	newconfd "${FILESDIR}"/${PN}.conf ${PN}
128
	newbashcomp client/scripts/boinc.bash boinc
129
	bashcomp_alias boinc boinccmd
130

  
131
	keepdir /var/lib/boinc
132
	fowners boinc:boinc /var/lib/boinc
133
	fperms 750 /var/lib/boinc
134

  
135
	dosym -r /etc/ssl/certs/ca-certificates.crt /var/lib/boinc/ca-bundle.crt
136

  
137
	exeinto /etc/X11/xinit/xinitrc.d
138
	newexe packages/generic/36x11-common_xhost-boinc 95-boinc
139

  
140
	newinitd "${FILESDIR}"/boinc.initd-r1 boinc
141
	newconfd "${FILESDIR}"/boinc.confd-r1 boinc
151 142
}
152 143

  
153 144
pkg_postinst() {
154
	if use X; then
145
	if use gui; then
155 146
		xdg_desktop_database_update
156 147
		xdg_mimeinfo_database_update
157 148
		xdg_icon_cache_update
158 149
	fi
159 150

  
160 151
	elog
161
	elog "You are using the source compiled version of boinc."
162
	use X && elog "The graphical manager can be found at /usr/bin/boincmgr"
163
	elog
164 152
	elog "You need to attach to a project to do anything useful with boinc."
165
	elog "You can do this by running /etc/init.d/boinc attach"
166
	elog "The howto for configuration is located at:"
167
	elog "http://boinc.berkeley.edu/wiki/Anonymous_platform"
153
	elog "You can do this by running:"
154
	elog "# rc-service boinc attach"
155
	elog "The user manual is located at:"
156
	elog "https://github.com/BOINC/boinc/wiki/User-manual"
168 157
	elog
169 158
	# Add warning about the new password for the client, bug 121896.
170
	if use X; then
171
		elog "If you need to use the graphical manager the password is in:"
159
	if use gui; then
160
		elog "If you need to use the graphical manager, the password is in:"
172 161
		elog "/var/lib/boinc/gui_rpc_auth.cfg"
173
		elog "Where /var/lib/ is default RUNTIMEDIR, that can be changed in:"
162
		elog "Where /var/lib/boinc is default RUNTIMEDIR that can be changed in:"
174 163
		elog "/etc/conf.d/boinc"
175 164
		elog "You should change this password to something more memorable (can be even blank)."
176 165
		elog "Remember to launch init script before using manager. Or changing the password."
177 166
		elog
178 167
	fi
179
	elog "To be able to use CUDA or OpenCL you should add the boinc user to the video group."
180
	elog "Run as root:"
181
	elog "gpasswd -a boinc video"
182
	elog
168

  
169
	# OpenCL and CUDA libraries are loaded with dlopen(),
170
	# no headers used at build time and no linking occurs.
171
	optfeature "CUDA applications support" x11-drivers/nvidia-drivers
172
	optfeature "Docker applications support" \
173
		"app-containers/podman app-containers/podman-compose" \
174
		"app-containers/docker app-containers/docker-compose:2"
175
	optfeature "OpenCL applications support" virtual/opencl
176
	optfeature "VirtualBox applications support" app-emulation/virtualbox
183 177

  
184 178
	optfeature_header "If you want to run ATLAS native tasks by LHC@home, you need to install:"
185 179
	optfeature "CERN VM filesystem support" net-fs/cvmfs
186 180
}
187 181

  
188 182
pkg_postrm() {
189
	if use X; then
183
	if use gui; then
190 184
		xdg_desktop_database_update
191 185
		xdg_mimeinfo_database_update
192 186
		xdg_icon_cache_update
Thank you!