From ef6399c64a2b7523153a6e78135669f41280fb57 Mon Sep 17 00:00:00 2001 From: Kevin Boyd Date: Mon, 30 Jul 2018 21:54:27 -0400 Subject: [PATCH] Report up to date hwloc version information The hwloc version in gmx --version and log files had been taken from HWLOC_API_VERSION in the hwloc header, which is not always updated to reflect new releases. Added HWLOC_VERSION to buildinfo.h from cmake, used in place of HWLOC_API_VERSION Fixes #2591 Change-Id: I0ed9f1f1ad9b4262fbb966c03c407eeb1edfc3da --- src/buildinfo.h.cmakein | 3 +++ src/gromacs/utility/binaryinformation.cpp | 5 +---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/buildinfo.h.cmakein b/src/buildinfo.h.cmakein index 1e32a4c381..f681a650c0 100644 --- a/src/buildinfo.h.cmakein +++ b/src/buildinfo.h.cmakein @@ -90,6 +90,9 @@ /** Location of GROMACS-specific data files */ #define GMX_INSTALL_GMXDATADIR "@GMX_INSTALL_GMXDATADIR@" +/** HWLOC version information */ +#define HWLOC_VERSION "@HWLOC_VERSION@" + /** CUDA compiler version information */ #define CUDA_COMPILER_INFO "@CUDA_COMPILER_INFO@" diff --git a/src/gromacs/utility/binaryinformation.cpp b/src/gromacs/utility/binaryinformation.cpp index 495ebe3ae6..c27e28ad37 100644 --- a/src/gromacs/utility/binaryinformation.cpp +++ b/src/gromacs/utility/binaryinformation.cpp @@ -263,10 +263,7 @@ void gmx_print_version_info(gmx::TextWriter *writer) writer->writeLine("TNG support: disabled"); #endif #if GMX_HWLOC - writer->writeLine(formatString("Hwloc support: hwloc-%d.%d.%d", - HWLOC_API_VERSION>>16, - (HWLOC_API_VERSION>>8) & 0xFF, - HWLOC_API_VERSION & 0xFF)); + writer->writeLine(formatString("Hwloc support: hwloc-%s", HWLOC_VERSION)); #else writer->writeLine("Hwloc support: disabled"); #endif -- 2.11.4.GIT