From 40a49f51f320228eb5adbd6ee29a615965d3af9a Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Sun, 28 Mar 2004 02:04:23 +0000 Subject: [PATCH] log library versions --- .../src/arch/ArchHooks/ArchHooks_Unix.cpp | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/stepmania/src/arch/ArchHooks/ArchHooks_Unix.cpp b/stepmania/src/arch/ArchHooks/ArchHooks_Unix.cpp index 5370b04dfe..c57a531104 100644 --- a/stepmania/src/arch/ArchHooks/ArchHooks_Unix.cpp +++ b/stepmania/src/arch/ArchHooks/ArchHooks_Unix.cpp @@ -5,6 +5,7 @@ #include "StepMania.h" #include "archutils/Unix/SignalHandler.h" #include "archutils/Unix/GetSysInfo.h" +#include "archutils/Unix/LinuxThreadHelpers.h" #if defined(CRASH_HANDLER) #include "archutils/Unix/CrashHandler.h" @@ -73,6 +74,20 @@ ArchHooks_Unix::ArchHooks_Unix() SignalHandler::OnClose( EmergencyShutdown ); } +#ifndef _CS_GNU_LIBC_VERSION +#define _CS_GNU_LIBC_VERSION 2 +#endif + +static CString LibcVersion() +{ + char buf[1024]; + int ret = confstr( _CS_GNU_LIBC_VERSION, buf, sizeof(buf) ); + if( ret == -1 ) + return "(unknown)"; + + return buf; +} + void ArchHooks_Unix::DumpDebugInfo() { CString sys; @@ -87,6 +102,9 @@ void ArchHooks_Unix::DumpDebugInfo() LOG->Info( "Crash demangle component: %s", BACKTRACE_DEMANGLE_METHOD_TEXT ); #endif #endif + + LOG->Info( "Runtime library: %s", LibcVersion().c_str() ); + LOG->Info( "Threads library: %s", ThreadsVersion().c_str() ); } /*