diff options
author | Que Quotion | 2017-03-29 07:15:13 +0900 |
---|---|---|
committer | Que Quotion | 2017-03-29 07:15:13 +0900 |
commit | 08f3af0c8d75131534ffcf212c8858443c2a70a1 (patch) | |
tree | 8afa340f5bb30248fe8609a0b3cc08d413cdac55 | |
parent | 5e3d92cbf42d4d737f9a861313abf94e60c86d88 (diff) | |
download | aur-08f3af0c8d75131534ffcf212c8858443c2a70a1.tar.gz |
kludge: only output ERROR messages for now
-rw-r--r-- | .SRCINFO | 6 | ||||
-rw-r--r-- | PKGBUILD | 12 | ||||
-rw-r--r-- | reduce-logging.patch | 26 |
3 files changed, 37 insertions, 7 deletions
@@ -1,9 +1,9 @@ # Generated by mksrcinfo v8 -# Sun Mar 26 14:53:57 UTC 2017 +# Tue Mar 28 22:14:07 UTC 2017 pkgbase = indicator-sensors-git pkgdesc = Small application to provide hardware sensor readings using the AppIndicator framework (git version) pkgver = 0.8.r28.gd267b5c - pkgrel = 1 + pkgrel = 2 url = https://github.com/alexmurray/indicator-sensors install = indicator-sensors.install arch = i686 @@ -23,9 +23,11 @@ pkgbase = indicator-sensors-git conflicts = indicator-sensors source = git+https://github.com/alexmurray/indicator-sensors source = menu-cleanup.patch + source = reduce-logging.patch source = is-udisks2.rules md5sums = SKIP md5sums = 7f41886142704131faba29ce87ae07ed + md5sums = 4a1c2fc97d24d4246c7f7e04761a9362 md5sums = 73468b5a1034ed57cb94c48ba26d2300 pkgname = indicator-sensors-git @@ -2,7 +2,7 @@ pkgname=indicator-sensors-git pkgver=0.8.r28.gd267b5c -pkgrel=1 +pkgrel=2 pkgdesc="Small application to provide hardware sensor readings using the AppIndicator framework (git version)" arch=('i686' 'x86_64') url="https://github.com/alexmurray/indicator-sensors" @@ -13,11 +13,12 @@ depends=('dconf' 'libappindicator-gtk3' 'libatasmart' 'libnotify' 'libpeas' 'lm_ optdepends=('libxnvctrl: NVIDIA GPU support') makedepends=('gnome-common' 'intltool') install=indicator-sensors.install -source=(git+https://github.com/alexmurray/indicator-sensors - menu-cleanup.patch - is-udisks2.rules) +source=("git+https://github.com/alexmurray/indicator-sensors" + {menu-cleanup,reduce-logging}.patch + 'is-udisks2.rules') md5sums=('SKIP' '7f41886142704131faba29ce87ae07ed' + '4a1c2fc97d24d4246c7f7e04761a9362' '73468b5a1034ed57cb94c48ba26d2300') pkgver() { @@ -30,6 +31,7 @@ prepare() { #Cleanup indicator menu (remove "about" and "quit") patch -Np2 < ../menu-cleanup.patch + patch -Np2 < ../reduce-logging.patch } build() { @@ -42,7 +44,7 @@ build() { package() { cd indicator-sensors make DESTDIR="$pkgdir" install - mkdir -p "$pkgdir"/etc/polkit-1/rules.d/ + mkdir -p -m 750 "$pkgdir"/etc/polkit-1/rules.d/ install -m 644 ../is-udisks2.rules "$pkgdir"/etc/polkit-1/rules.d/ } diff --git a/reduce-logging.patch b/reduce-logging.patch new file mode 100644 index 000000000000..bc71f9896a33 --- /dev/null +++ b/reduce-logging.patch @@ -0,0 +1,26 @@ +--- src/indicator-sensors/indicator-sensors/is-log.c 2017-03-29 07:06:33.842665416 +0900 ++++ src/indicator-sensors/indicator-sensors/is-log.c.new 2017-03-29 07:04:44.027817890 +0900 +@@ -79,13 +79,14 @@ + va_list args) + { + gchar *fmt, *output; +- +- /* TODO: perhaps add a more elaborate logger */ +- fmt = g_strdup_printf("[%s] %s: %s", source, +- is_log_level_to_string(level), format); +- output = g_strdup_vprintf(fmt, args); +- fprintf(stdout, "%s\n", output); +- fflush(stdout); +- g_free(output); +- g_free(fmt); ++ if (is_log_level_to_string(level) == "ERROR") { ++ /* TODO: perhaps add a more elaborate logger */ ++ fmt = g_strdup_printf("[%s] %s: %s", source, ++ is_log_level_to_string(level), format); ++ output = g_strdup_vprintf(fmt, args); ++ fprintf(stdout, "%s\n", output); ++ fflush(stdout); ++ g_free(output); ++ g_free(fmt); ++ } + } |