diff options
author | Jakub Jirutka <jakub@jirutka.cz> | 2018-05-20 20:39:10 +0200 |
---|---|---|
committer | Jakub Jirutka <jakub@jirutka.cz> | 2018-05-20 20:35:15 +0200 |
commit | 727a1b01d1aea34d92f04a72cbfd7246df08e650 (patch) | |
tree | 72d259387ef1da2da198891fad057a6ac75e4767 | |
parent | 792ba86e07a8f0e49a85468b49eca954fcf8fb57 (diff) | |
download | aports-727a1b01d1aea34d92f04a72cbfd7246df08e650.tar.bz2 aports-727a1b01d1aea34d92f04a72cbfd7246df08e650.tar.xz |
main/procps: upgrade to 3.3.15
-rw-r--r-- | main/procps/APKBUILD | 10 | ||||
-rw-r--r-- | main/procps/strtod.patch | 115 |
2 files changed, 4 insertions, 121 deletions
diff --git a/main/procps/APKBUILD b/main/procps/APKBUILD index 5471aa1d2b..616b7a1e02 100644 --- a/main/procps/APKBUILD +++ b/main/procps/APKBUILD @@ -1,7 +1,7 @@ # Maintainer: Natanael Copa <ncopa@alpinelinux.org> pkgname=procps -pkgver=3.3.12 -pkgrel=5 +pkgver=3.3.15 +pkgrel=0 pkgdesc="Utilities for monitoring your system and processes on your system" url="https://gitlab.com/procps-ng/procps" arch="all" @@ -9,8 +9,7 @@ license="GPL-2.0 LGPL-2.1+" makedepends="ncurses-dev gettext-dev autoconf automake libtool" checkdepends="dejagnu" subpackages="$pkgname-dev $pkgname-doc $pkgname-lang libproc" -source="$pkgname-$pkgver.tar.gz::https://gitlab.com/procps-ng/$pkgname/repository/archive.tar.gz?ref=v$pkgver - strtod.patch" +source="$pkgname-$pkgver.tar.gz::https://gitlab.com/procps-ng/$pkgname/repository/archive.tar.gz?ref=v$pkgver" builddir="$srcdir/$pkgname-v$pkgver" prepare() { @@ -78,5 +77,4 @@ libproc() { mv "$pkgdir"/lib "$subpkgdir"/ } -sha512sums="a4400b9e13f8e9ec1c527a0e9e2e5580b6d007cae0f961b2a82c2924e4922232cee7a8be77badb45d608383758476da0260460d8e0801a5e88ced7cc6b8c10cc procps-3.3.12.tar.gz -93449c3b431a40d9fbfe8a5681cbd3696a984565b99d6105cf988ae571beda0c815104a3a13bf6d20289705e4063b0a61d2658c422293095e3eb78c29c41053b strtod.patch" +sha512sums="61017c98827cb9c325fe51f74e9e912cb6b130abdc69742678968a45f4a6f1f033bac4adaed19908197bc97a7426a7a27e04be361edb74ebff3dc0383b71fa53 procps-3.3.15.tar.gz" diff --git a/main/procps/strtod.patch b/main/procps/strtod.patch deleted file mode 100644 index 9cc974b1b3..0000000000 --- a/main/procps/strtod.patch +++ /dev/null @@ -1,115 +0,0 @@ -From 4ed44ab58e27a9a09902b9c5b49df484842b6c9a Mon Sep 17 00:00:00 2001 -From: Dr. Werner Fink <werner@suse.de> -Date: Wed, 13 Jul 2016 20:08:51 +1000 -Subject: [PATCH] misc: fix strtod_nol_err tests - -A better way of implementing the string to double -conversion and a better way of testing it. - -Signed-off-by: Craig Small <csmall@enc.com.au> ---- - include/strutils.h | 2 +- - lib/strutils.c | 22 ++++++++++++---------- - lib/test_strtod_nol.c | 7 ++++--- - 4 files changed, 20 insertions(+), 18 deletions(-) - -diff --git a/include/strutils.h b/include/strutils.h -index 85a6192..a5a15c9 100644 ---- a/include/strutils.h -+++ b/include/strutils.h -@@ -7,6 +7,6 @@ - - extern long strtol_or_err(const char *str, const char *errmesg); - extern double strtod_or_err(const char *str, const char *errmesg); --double strtod_nol_or_err(char *str, const char *errmesg); -+extern double strtod_nol_or_err(char *str, const char *errmesg); - - #endif -diff --git a/lib/strutils.c b/lib/strutils.c -index e5245db..e0632c4 100644 ---- a/lib/strutils.c -+++ b/lib/strutils.c -@@ -20,6 +20,8 @@ - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -+#include <float.h> -+#include <math.h> - #include <stdlib.h> - #include <ctype.h> - -@@ -71,9 +73,9 @@ double strtod_or_err(const char *str, const char *errmesg) - */ - double strtod_nol_or_err(char *str, const char *errmesg) - { -- double num; -+ long double num; - const char *cp, *radix; -- double mult; -+ long double mult; - int negative = 0; - - if (str != NULL && *str != '\0') { -@@ -95,29 +97,29 @@ double strtod_nol_or_err(char *str, const char *errmesg) - mult=0.1; - while(isdigit(*radix)) { - radix++; -- mult *= 10; -+ mult *= 10.0; - } - while(isdigit(*cp)) { -- num += (*cp - '0') * mult; -- mult /= 10; -+ num += (long double)(*cp - '0') * mult; -+ mult /= 10.0; - cp++; - } - /* got the integers */ - if (*cp == '\0') -- return (negative?-num:num); -+ return (double)(negative?-num:num); - if (*cp != '.' && *cp != ',') - error(EXIT_FAILURE, EINVAL, "%s: '%s'", errmesg, str); - - cp++; - mult = 0.1; - while(isdigit(*cp)) { -- num += (*cp - '0') * mult; -- mult /= 10; -+ num += (long double)(*cp - '0') * mult; -+ mult /= 10.0; - cp++; - } - if (*cp == '\0') -- return (negative?-num:num); -+ return (double)(negative?-num:num); - } - error(EXIT_FAILURE, errno, "%s: '%s'", errmesg, str); -- return 0; -+ return (double)0; - } -diff --git a/lib/test_strtod_nol.c b/lib/test_strtod_nol.c -index 0be798c..736768a 100644 ---- a/lib/test_strtod_nol.c -+++ b/lib/test_strtod_nol.c -@@ -1,4 +1,5 @@ -- -+#include <float.h> -+#include <math.h> - #include <stdio.h> - #include <stdlib.h> - #include "strutils.h" -@@ -33,8 +34,8 @@ int main(int argc, char *argv[]) - double val; - - for(i=0; tests[i].string != NULL; i++) { -- if(strtod_nol_or_err(tests[i].string, "Cannot parse number") != -- tests[i].result) { -+ val = strtod_nol_or_err(tests[i].string, "Cannot parse number"); -+ if(fabs(tests[i].result - val) > DBL_EPSILON) { - fprintf(stderr, "FAIL: strtod_nol_or_err(\"%s\") != %f\n", - tests[i].string, tests[i].result); - return EXIT_FAILURE; --- -libgit2 0.26.0 - |