summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2022-12-29 17:25:33 +0000
committerSam James <sam@gentoo.org>2022-12-29 17:26:29 +0000
commit973ccf5af3917e0e50bcbfcb0321da80846a67d3 (patch)
tree55df1d0d06896cb9446c13fbd1837c77ebda73f6 /app-admin
parentapp-admin/rasdaemon: add github upstream metadata (diff)
downloadgentoo-973ccf5af3917e0e50bcbfcb0321da80846a67d3.tar.gz
gentoo-973ccf5af3917e0e50bcbfcb0321da80846a67d3.tar.bz2
gentoo-973ccf5af3917e0e50bcbfcb0321da80846a67d3.zip
app-admin/rasdaemon: add 0.6.8
Closes: https://bugs.gentoo.org/834964 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'app-admin')
-rw-r--r--app-admin/rasdaemon/Manifest1
-rw-r--r--app-admin/rasdaemon/files/rasdaemon-0.6.8-bashisms-configure.patch186
-rw-r--r--app-admin/rasdaemon/rasdaemon-0.6.8.ebuild76
3 files changed, 263 insertions, 0 deletions
diff --git a/app-admin/rasdaemon/Manifest b/app-admin/rasdaemon/Manifest
index 1b6919f9da7f..7c6fda66f703 100644
--- a/app-admin/rasdaemon/Manifest
+++ b/app-admin/rasdaemon/Manifest
@@ -1 +1,2 @@
DIST rasdaemon-0.6.7.tar.bz2 422473 BLAKE2B 32a95ed9ca217fb69b197f88fa296bf0d3b4230a1ae11c60582911ff84abbe8b9a67b318774b8c4b765dbedbd4458eb220ca3b8ff4c9d065eb893a9a6a9916c5 SHA512 15beae5d4964c49b7b7f9e731948b5def9622fba5d7d17ce52a282d7834d256366cdf3cf427b82b2a6a8fd0c99f202f545000bdb06064fbae7ae0296aef0946c
+DIST rasdaemon-0.6.8.tar.gz 161343 BLAKE2B 95dab212e404480d45e5b07fa0f9ec7361036c9295a81dd082657c71cf8ad1114cc28f163b8975733e2042dfeb957f8da71dc52440249c75c24653c1ce235e86 SHA512 634638154c6b0bf7a079d6aba884a55e540c9edc3c25715a792ad7535c68629618e9cef8b6ec7e20845f78bd57f712d437be4d772523020f09d30cce42759a30
diff --git a/app-admin/rasdaemon/files/rasdaemon-0.6.8-bashisms-configure.patch b/app-admin/rasdaemon/files/rasdaemon-0.6.8-bashisms-configure.patch
new file mode 100644
index 000000000000..6a3beaae217c
--- /dev/null
+++ b/app-admin/rasdaemon/files/rasdaemon-0.6.8-bashisms-configure.patch
@@ -0,0 +1,186 @@
+https://github.com/mchehab/rasdaemon/pull/81
+
+From 9632f63c3855b119ab4b02300e27ab357bddcf03 Mon Sep 17 00:00:00 2001
+From: Sam James <sam@gentoo.org>
+Date: Thu, 29 Dec 2022 17:23:47 +0000
+Subject: [PATCH] configure.ac: fix bashisms
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+configure scripts need to be runnable with a POSIX-compliant /bin/sh.
+
+On many (but not all!) systems, /bin/sh is provided by Bash, so errors
+like this aren't spotted. Notably Debian defaults to /bin/sh provided
+by dash which doesn't tolerate such bashisms as '=='.
+
+This retains compatibility with bash.
+
+Signed-off-by: Sam James <sam@gentoo.org>
+--- a/configure.ac
++++ b/configure.ac
+@@ -27,14 +27,14 @@ AC_ARG_ENABLE([all],
+ AC_ARG_ENABLE([sqlite3],
+ AS_HELP_STRING([--enable-sqlite3], [enable storing data at SQL lite database (currently experimental)]))
+
+-AS_IF([test "x$enable_sqlite3" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_sqlite3" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_CHECK_LIB(sqlite3, sqlite3_open,[echo "found sqlite3"] , AC_MSG_ERROR([*** Unable to find sqlite3 library]), )
+ SQLITE3_LIBS="-lsqlite3"
+ AC_DEFINE(HAVE_SQLITE3,1,"have sqlite3")
+ AC_SUBST([WITH_SQLITE3])
+ ])
+
+-AM_CONDITIONAL([WITH_SQLITE3], [test x$enable_sqlite3 = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_SQLITE3], [test x$enable_sqlite3 = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_SQLITE3], [USE_SQLITE3="yes"], [USE_SQLITE3="no"])
+
+ AC_SUBST([SQLITE3_LIBS])
+@@ -43,122 +43,122 @@ AC_SUBST([SQLITE3_LIBS])
+ AC_ARG_ENABLE([aer],
+ AS_HELP_STRING([--enable-aer], [enable PCIe AER events (currently experimental)]))
+
+-AS_IF([test "x$enable_aer" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_aer" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_AER,1,"have PCIe AER events collect")
+ AC_SUBST([WITH_AER])
+ ])
+-AM_CONDITIONAL([WITH_AER], [test x$enable_aer = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_AER], [test x$enable_aer = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_AER], [USE_AER="yes"], [USE_AER="no"])
+
+
+ AC_ARG_ENABLE([non_standard],
+ AS_HELP_STRING([--enable-non-standard], [enable NON_STANDARD events (currently experimental)]))
+
+-AS_IF([test "x$enable_non_standard" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_non_standard" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_NON_STANDARD,1,"have UNKNOWN_SEC events collect")
+ AC_SUBST([WITH_NON_STANDARD])
+ ])
+-AM_CONDITIONAL([WITH_NON_STANDARD], [test x$enable_non_standard = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_NON_STANDARD], [test x$enable_non_standard = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_NON_STANDARD], [USE_NON_STANDARD="yes"], [USE_NON_STANDARD="no"])
+
+ AC_ARG_ENABLE([arm],
+ AS_HELP_STRING([--enable-arm], [enable ARM events (currently experimental)]))
+
+-AS_IF([test "x$enable_arm" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_arm" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_ARM,1,"have ARM events collect")
+ AC_SUBST([WITH_ARM])
+ ])
+-AM_CONDITIONAL([WITH_ARM], [test x$enable_arm = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_ARM], [test x$enable_arm = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_ARM], [USE_ARM="yes"], [USE_ARM="no"])
+
+ AC_ARG_ENABLE([mce],
+ AS_HELP_STRING([--enable-mce], [enable MCE events (currently experimental)]))
+
+-AS_IF([test "x$enable_mce" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_mce" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_MCE,1,"have PCIe MCE events collect")
+ AC_SUBST([WITH_MCE])
+ ])
+-AM_CONDITIONAL([WITH_MCE], [test x$enable_mce = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_MCE], [test x$enable_mce = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_MCE], [USE_MCE="yes"], [USE_MCE="no"])
+
+ AC_ARG_ENABLE([extlog],
+ AS_HELP_STRING([--enable-extlog], [enable EXTLOG events (currently experimental)]))
+
+-AS_IF([test "x$enable_extlog" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_extlog" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_EXTLOG,1,"have EXTLOG events collect")
+ AC_SUBST([WITH_EXTLOG])
+ ])
+-AM_CONDITIONAL([WITH_EXTLOG], [test x$enable_extlog = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_EXTLOG], [test x$enable_extlog = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_EXTLOG], [USE_EXTLOG="yes"], [USE_EXTLOG="no"])
+
+ AC_ARG_ENABLE([devlink],
+ AS_HELP_STRING([--enable-devlink], [enable devlink health events (currently experimental)]))
+
+-AS_IF([test "x$enable_devlink" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_devlink" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_DEVLINK,1,"have devlink health events collect")
+ AC_SUBST([WITH_DEVLINK])
+ ])
+-AM_CONDITIONAL([WITH_DEVLINK], [test x$enable_devlink = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_DEVLINK], [test x$enable_devlink = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_DEVLINK], [USE_DEVLINK="yes"], [USE_DEVLINK="no"])
+
+ AC_ARG_ENABLE([diskerror],
+ AS_HELP_STRING([--enable-diskerror], [enable disk I/O error events (currently experimental)]))
+
+-AS_IF([test "x$enable_diskerror" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_diskerror" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_DISKERROR,1,"have disk I/O errors collect")
+ AC_SUBST([WITH_DISKERROR])
+ ])
+-AM_CONDITIONAL([WITH_DISKERROR], [test x$enable_diskerror = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_DISKERROR], [test x$enable_diskerror = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_DISKERROR], [USE_DISKERROR="yes"], [USE_DISKERROR="no"])
+
+ AC_ARG_ENABLE([memory_failure],
+ AS_HELP_STRING([--enable-memory-failure], [enable memory failure events (currently experimental)]))
+
+-AS_IF([test "x$enable_memory_failure" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_memory_failure" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_MEMORY_FAILURE,1,"have memory failure events collect")
+ AC_SUBST([WITH_MEMORY_FAILURE])
+ ])
+-AM_CONDITIONAL([WITH_MEMORY_FAILURE], [test x$enable_memory_failure = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_MEMORY_FAILURE], [test x$enable_memory_failure = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_MEMORY_FAILURE], [USE_MEMORY_FAILURE="yes"], [USE_MEMORY_FAILURE="no"])
+
+ AC_ARG_ENABLE([abrt_report],
+ AS_HELP_STRING([--enable-abrt-report], [enable report event to ABRT (currently experimental)]))
+
+-AS_IF([test "x$enable_abrt_report" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_abrt_report" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_ABRT_REPORT,1,"have report event to ABRT")
+ AC_SUBST([WITH_ABRT_REPORT])
+ ])
+-AM_CONDITIONAL([WITH_ABRT_REPORT], [test x$enable_abrt_report = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_ABRT_REPORT], [test x$enable_abrt_report = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_ABRT_REPORT], [USE_ABRT_REPORT="yes"], [USE_ABRT_REPORT="no"])
+
+ AC_ARG_ENABLE([hisi_ns_decode],
+ AS_HELP_STRING([--enable-hisi-ns-decode], [enable HISI_NS_DECODE events (currently experimental)]))
+
+-AS_IF([test "x$enable_hisi_ns_decode" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_hisi_ns_decode" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_HISI_NS_DECODE,1,"have HISI UNKNOWN_SEC events decode")
+ AC_SUBST([WITH_HISI_NS_DECODE])
+ ])
+-AM_CONDITIONAL([WITH_HISI_NS_DECODE], [test x$enable_hisi_ns_decode = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_HISI_NS_DECODE], [test x$enable_hisi_ns_decode = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_HISI_NS_DECODE], [USE_HISI_NS_DECODE="yes"], [USE_HISI_NS_DECODE="no"])
+
+ AC_ARG_ENABLE([memory_ce_pfa],
+ AS_HELP_STRING([--enable-memory-ce-pfa], [enable memory Corrected Error predictive failure analysis]))
+
+-AS_IF([test "x$enable_memory_ce_pfa" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_memory_ce_pfa" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_MEMORY_CE_PFA,1,"have memory corrected error predictive failure analysis")
+ AC_SUBST([WITH_MEMORY_CE_PFA])
+ ])
+-AM_CONDITIONAL([WITH_MEMORY_CE_PFA], [test x$enable_memory_ce_pfa = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_MEMORY_CE_PFA], [test x$enable_memory_ce_pfa = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_MEMORY_CE_PFA], [USE_MEMORY_CE_PFA="yes"], [USE_MEMORY_CE_PFA="no"])
+
+ AC_ARG_ENABLE([amp_ns_decode],
+ AS_HELP_STRING([--enable-amp-ns-decode], [enable AMP_NS_DECODE events (currently experimental)]))
+
+-AS_IF([test "x$enable_amp_ns_decode" = "xyes" || test "x$enable_all" == "xyes"], [
++AS_IF([test "x$enable_amp_ns_decode" = "xyes" || test "x$enable_all" = "xyes"], [
+ AC_DEFINE(HAVE_AMP_NS_DECODE,1,"have AMP UNKNOWN_SEC events decode")
+ AC_SUBST([WITH_AMP_NS_DECODE])
+ ])
+-AM_CONDITIONAL([WITH_AMP_NS_DECODE], [test x$enable_amp_ns_decode = xyes || test x$enable_all == xyes])
++AM_CONDITIONAL([WITH_AMP_NS_DECODE], [test x$enable_amp_ns_decode = xyes || test x$enable_all = xyes])
+ AM_COND_IF([WITH_AMP_NS_DECODE], [USE_AMP_NS_DECODE="yes"], [USE_AMP_NS_DECODE="no"])
+
+ test "$sysconfdir" = '${prefix}/etc' && sysconfdir=/etc
+
diff --git a/app-admin/rasdaemon/rasdaemon-0.6.8.ebuild b/app-admin/rasdaemon/rasdaemon-0.6.8.ebuild
new file mode 100644
index 000000000000..3a80aa0e89a8
--- /dev/null
+++ b/app-admin/rasdaemon/rasdaemon-0.6.8.ebuild
@@ -0,0 +1,76 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools flag-o-matic linux-info systemd
+
+DESCRIPTION="Reliability, Availability and Serviceability logging tool"
+HOMEPAGE="https://github.com/mchehab/rasdaemon"
+SRC_URI="https://github.com/mchehab/rasdaemon/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~x86"
+
+DEPEND="
+ dev-db/sqlite
+ elibc_musl? ( sys-libs/argp-standalone )
+"
+RDEPEND="
+ ${DEPEND}
+ dev-perl/DBI
+ dev-perl/DBD-SQLite
+ sys-apps/dmidecode
+"
+BDEPEND="sys-devel/gettext"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-0.6.8-bashisms-configure.patch
+)
+
+pkg_setup() {
+ linux-info_pkg_setup
+ local CONFIG_CHECK="~ACPI_EXTLOG"
+ check_extra_config
+}
+
+src_prepare() {
+ default
+
+ eautoreconf
+}
+
+src_configure() {
+ local myconfargs=(
+ --enable-sqlite3
+ --enable-abrt-report
+ --enable-aer
+ --enable-arm
+ --enable-extlog
+ --enable-hisi-ns-decode
+ --enable-mce
+ --enable-non-standard
+ --enable-devlink
+ --enable-diskerror
+ --enable-memory-ce-pfa
+ --includedir="/usr/include/${PN}"
+ --localstatedir=/var
+ )
+
+ use elibc_musl && append-libs -largp
+
+ econf "${myconfargs[@]}"
+}
+
+src_install() {
+ default
+
+ keepdir "/var/lib/${PN}"
+
+ systemd_dounit misc/*.service
+
+ newinitd "${FILESDIR}/rasdaemon.openrc-r2" rasdaemon
+ newinitd "${FILESDIR}/ras-mc-ctl.openrc-r1" ras-mc-ctl
+ newconfd "${FILESDIR}"/rasdaemon.confd rasdaemon
+}