pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/benchmarks/google-benchmark benchmarks/google-benchmar...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/f5d8ed209777
branches:  trunk
changeset: 410564:f5d8ed209777
user:      minskim <minskim%pkgsrc.org@localhost>
date:      Fri Jan 24 16:13:03 2020 +0000

description:
benchmarks/google-benchmark: Build fix

Apply upstream patch to define HOST_NAME_MAX.

diffstat:

 benchmarks/google-benchmark/distinfo                     |   3 +-
 benchmarks/google-benchmark/patches/patch-src_sysinfo.cc |  28 ++++++++++++++++
 2 files changed, 30 insertions(+), 1 deletions(-)

diffs (45 lines):

diff -r c07a86db5746 -r f5d8ed209777 benchmarks/google-benchmark/distinfo
--- a/benchmarks/google-benchmark/distinfo      Fri Jan 24 16:07:48 2020 +0000
+++ b/benchmarks/google-benchmark/distinfo      Fri Jan 24 16:13:03 2020 +0000
@@ -1,7 +1,8 @@
-$NetBSD: distinfo,v 1.5 2019/05/21 09:55:15 adam Exp $
+$NetBSD: distinfo,v 1.6 2020/01/24 16:13:03 minskim Exp $
 
 SHA1 (benchmark-1.5.tar.gz) = a35b0a2ae52be99162c24c470bcda4b102b2d7e3
 RMD160 (benchmark-1.5.tar.gz) = 4d2f355d89a8aa0e3c3657c096e1a1a90f4b3574
 SHA512 (benchmark-1.5.tar.gz) = a57122340c4f9a8e434ec70098916aef7c49d5d8312a30e4753f54bacc1099b146698b66c12f9ef116f7cadc93c604809a905c0e259aecf63aa2553390a1b609
 Size (benchmark-1.5.tar.gz) = 150159 bytes
 SHA1 (patch-CMakeLists.txt) = 858906c819358522d27d294025b9dfde6c053324
+SHA1 (patch-src_sysinfo.cc) = 0e5c6333e0160259d6ce2a77e36734c80685eddc
diff -r c07a86db5746 -r f5d8ed209777 benchmarks/google-benchmark/patches/patch-src_sysinfo.cc
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/benchmarks/google-benchmark/patches/patch-src_sysinfo.cc  Fri Jan 24 16:13:03 2020 +0000
@@ -0,0 +1,28 @@
+$NetBSD: patch-src_sysinfo.cc,v 1.1 2020/01/24 16:13:03 minskim Exp $
+
+Make sure HOST_NAME_MAX is always defined.
+https://github.com/google/benchmark/commit/7411874d9563b18c56f8a81e02e77c6ffc5c3851
+
+--- src/sysinfo.cc.orig        2019-05-13 19:42:18.000000000 +0000
++++ src/sysinfo.cc
+@@ -429,11 +429,20 @@ std::string GetSystemName() {
+ #endif
+   return str;
+ #else // defined(BENCHMARK_OS_WINDOWS)
++#ifndef HOST_NAME_MAX
+ #ifdef BENCHMARK_HAS_SYSCTL // BSD/Mac Doesnt have HOST_NAME_MAX defined
+ #define HOST_NAME_MAX 64
++#elif defined(BENCHMARK_OS_NACL)
++#define HOST_NAME_MAX 64
+ #elif defined(BENCHMARK_OS_QNX)
+ #define HOST_NAME_MAX 154
++#elif defined(BENCHMARK_OS_RTEMS)
++#define HOST_NAME_MAX 256
++#else
++#warning "HOST_NAME_MAX not defined. using 64"
++#define HOST_NAME_MAX 64
+ #endif
++#endif // def HOST_NAME_MAX
+   char hostname[HOST_NAME_MAX];
+   int retVal = gethostname(hostname, HOST_NAME_MAX);
+   if (retVal != 0) return std::string("");



Home | Main Index | Thread Index | Old Index