summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /app-admin/mcelog/files
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'app-admin/mcelog/files')
-rw-r--r--app-admin/mcelog/files/mcelog-0.8_pre1-timestamp-mcelog.patch8
-rw-r--r--app-admin/mcelog/files/mcelog-1.0_pre3_p20120918-bashism.patch21
-rw-r--r--app-admin/mcelog/files/mcelog-1.0_pre3_p20120918-build.patch42
-rw-r--r--app-admin/mcelog/files/mcelog.init29
-rw-r--r--app-admin/mcelog/files/mcelog.init-r116
-rw-r--r--app-admin/mcelog/files/mcelog.service10
6 files changed, 126 insertions, 0 deletions
diff --git a/app-admin/mcelog/files/mcelog-0.8_pre1-timestamp-mcelog.patch b/app-admin/mcelog/files/mcelog-0.8_pre1-timestamp-mcelog.patch
new file mode 100644
index 000000000000..d24afdbfe00e
--- /dev/null
+++ b/app-admin/mcelog/files/mcelog-0.8_pre1-timestamp-mcelog.patch
@@ -0,0 +1,8 @@
+diff -Nuar mcelog-0.8pre.orig/mcelog.cron mcelog-0.8pre/mcelog.cron
+--- mcelog-0.8pre.orig/mcelog.cron 2006-02-08 05:09:03.000000000 -0800
++++ mcelog-0.8pre/mcelog.cron 2008-02-22 11:32:06.717012502 -0800
+@@ -1,2 +1,3 @@
+ #!/bin/bash
+-/usr/sbin/mcelog --ignorenodev --filter >> /var/log/mcelog
++header="$(date +"%b %d %H:%M:%S") $(hostname) "
++/usr/sbin/mcelog --ignorenodev --filter | sed "s,^,$header,g" >> /var/log/mcelog
diff --git a/app-admin/mcelog/files/mcelog-1.0_pre3_p20120918-bashism.patch b/app-admin/mcelog/files/mcelog-1.0_pre3_p20120918-bashism.patch
new file mode 100644
index 000000000000..c6cba7d83bae
--- /dev/null
+++ b/app-admin/mcelog/files/mcelog-1.0_pre3_p20120918-bashism.patch
@@ -0,0 +1,21 @@
+From: Julian Ospald <hasufell@gentoo.org>
+Date: Sat Jan 26 17:40:22 UTC 2013
+Subject: remove bashisms
+
+--- triggers/cache-error-trigger
++++ triggers/cache-error-trigger
+@@ -1,4 +1,4 @@
+-#!/bin/bash
++#!/bin/sh
+ # cache error trigger. This shell script is executed by mcelog in daemon mode
+ # when a CPU reports excessive corrected cache errors. This could be a indication
+ # for future uncorrected errors.
+@@ -28,7 +28,7 @@
+ logger -s -p daemon.crit -t mcelog "Offlining CPU $i due to cache error threshold"
+ F=$(printf "/sys/devices/system/cpu/cpu%d/online" $i)
+ echo 0 > $F
+- if [ "$(< $F)" != "0" ] ; then
++ if [ "$(cat $F)" != "0" ] ; then
+ logger -s -p daemon.warn -t mcelog "Offlining CPU $i failed"
+ EXIT=1
+ fi
diff --git a/app-admin/mcelog/files/mcelog-1.0_pre3_p20120918-build.patch b/app-admin/mcelog/files/mcelog-1.0_pre3_p20120918-build.patch
new file mode 100644
index 000000000000..6444bfb133e8
--- /dev/null
+++ b/app-admin/mcelog/files/mcelog-1.0_pre3_p20120918-build.patch
@@ -0,0 +1,42 @@
+From: Julian Ospald <hasufell@gentoo.org>
+Date: Wed Oct 24 15:41:33 UTC 2012
+Subject: build system
+
+don't overwrite system CFLAGS, only append "-g -Os" if DEBUG=1 is passed
+as argument
+
+always use $(CC) instead of "gcc"
+
+--- Makefile
++++ Makefile
+@@ -1,4 +1,11 @@
+-CFLAGS := -g -Os
++CC ?= gcc
++
++# set to 1 to enable debug flags
++DEBUG = 0
++ifeq ($(DEBUG),1)
++CFLAGS += -g -Os
++endif
++
+ prefix := /usr
+ etcprefix :=
+ # Define appropiately for your distribution
+@@ -70,7 +77,7 @@
+ rm -f ${CLEAN} ${OBJ}
+
+ tsc: tsc.c
+- gcc -o tsc ${CFLAGS} -DSTANDALONE tsc.c ${LDFLAGS}
++ $(CC) -o tsc ${CFLAGS} -DSTANDALONE tsc.c ${LDFLAGS}
+
+ dbquery: db.o dbquery.o memutil.o
+
+@@ -101,7 +108,7 @@
+ echo $(SRC)
+
+ config-test: config.c
+- gcc -DTEST=1 config.c -o config-test
++ $(CC) -DTEST=1 config.c -o config-test
+
+ test:
+ $(MAKE) -C tests test DEBUG=""
diff --git a/app-admin/mcelog/files/mcelog.init b/app-admin/mcelog/files/mcelog.init
new file mode 100644
index 000000000000..d800b757b868
--- /dev/null
+++ b/app-admin/mcelog/files/mcelog.init
@@ -0,0 +1,29 @@
+#!/sbin/runscript
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+description='Start/stop mcelog in daemon mode'
+
+PIDFILE="/var/run/mcelog.pid"
+
+depend() {
+ after udev
+ need localmount
+ use logging
+}
+
+start() {
+ ebegin "Starting mcelog"
+ start-stop-daemon \
+ --start \
+ --pidfile ${PIDFILE} \
+ --exec /usr/sbin/mcelog -- --daemon --pidfile ${PIDFILE} ${MCELOG_OPTS}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping mcelog"
+ start-stop-daemon --stop --pidfile ${PIDFILE}
+ eend $?
+}
diff --git a/app-admin/mcelog/files/mcelog.init-r1 b/app-admin/mcelog/files/mcelog.init-r1
new file mode 100644
index 000000000000..a282118ef0d4
--- /dev/null
+++ b/app-admin/mcelog/files/mcelog.init-r1
@@ -0,0 +1,16 @@
+#!/sbin/runscript
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+description='Start/stop mcelog in daemon mode'
+
+pidfile="/var/run/mcelog.pid"
+command="/usr/sbin/mcelog"
+command_args="--daemon --pidfile ${pidfile} ${MCELOG_OPTS}"
+
+depend() {
+ after udev
+ need localmount
+ use logging
+}
diff --git a/app-admin/mcelog/files/mcelog.service b/app-admin/mcelog/files/mcelog.service
new file mode 100644
index 000000000000..4bd553012c95
--- /dev/null
+++ b/app-admin/mcelog/files/mcelog.service
@@ -0,0 +1,10 @@
+[Unit]
+Description=Machine Check Exception Logging Daemon
+After=syslog.target
+
+[Service]
+ExecStart=/usr/sbin/mcelog --ignorenodev --daemon --foreground
+StandardOutput=syslog
+
+[Install]
+WantedBy=multi-user.target