net-analyzer/gvmd: fix C23 build on 24.1.0, only show update instructions on update

Closes: https://bugs.gentoo.org/946583
Signed-off-by: Giuseppe Foti <foti.giuseppe@gmail.com>
Part-of: https://github.com/gentoo/gentoo/pull/43780
Closes: https://github.com/gentoo/gentoo/pull/43780
Signed-off-by: Florian Schmaus <flow@gentoo.org>
This commit is contained in:
Giuseppe Foti 2025-09-14 11:56:40 +02:00 committed by Florian Schmaus
parent 9453ca3651
commit ccd5546d74
No known key found for this signature in database
GPG Key ID: 2239A7E8F5852052
2 changed files with 20 additions and 12 deletions

View File

@ -49,6 +49,10 @@ BDEPEND="
) )
test? ( dev-libs/cgreen ) test? ( dev-libs/cgreen )
" "
PATCHES=(
# Closes #946583
"${FILESDIR}/gvmd-25.2.1-fix-c23-build.patch"
)
src_prepare() { src_prepare() {
cmake_src_prepare cmake_src_prepare
@ -120,10 +124,12 @@ src_install() {
} }
pkg_postinst() { pkg_postinst() {
elog "If you are upgrading from a previous version, you need to update the database version." if [[ ${REPLACING_VERSIONS} ]]; then
elog "Please, create the running directory and give write permission to the database user" elog "If you are upgrading from a previous version, you need to update the database version."
elog "then run gvmd as the gvm user with --migrate option:" elog "Please, create the running directory and give write permission to the database user"
elog "~# mkdir /run/gvmd" elog "then run gvmd as the gvm user with --migrate option:"
elog "~# setfacl -m u:gvm:rwx /run/gvmd/" elog "~# mkdir /run/gvmd"
elog "~# sudo -u gvm gvmd --migrate" elog "~# setfacl -m u:gvm:rwx /run/gvmd/"
elog "~# sudo -u gvm gvmd --migrate"
fi
} }

View File

@ -125,10 +125,12 @@ src_install() {
} }
pkg_postinst() { pkg_postinst() {
elog "If you are upgrading from a previous version, you need to update the database version." if [[ ${REPLACING_VERSIONS} ]]; then
elog "Please, create the running directory and give write permission to the database user" elog "If you are upgrading from a previous version, you need to update the database version."
elog "then run gvmd as the gvm user with --migrate option:" elog "Please, create the running directory and give write permission to the database user"
elog "~# mkdir /run/gvmd" elog "then run gvmd as the gvm user with --migrate option:"
elog "~# setfacl -m u:gvm:rwx /run/gvmd/" elog "~# mkdir /run/gvmd"
elog "~# sudo -u gvm gvmd --migrate" elog "~# setfacl -m u:gvm:rwx /run/gvmd/"
elog "~# sudo -u gvm gvmd --migrate"
fi
} }