versioninfo.h: fix recognizing archs and compiler (#6794)

This commit is contained in:
Sergey Fedorov
2023-08-02 21:02:39 +08:00
committed by GitHub
parent d87917cdc9
commit 7700916eae

View File

@@ -1,5 +1,7 @@
#ifdef __GNUC__
#if defined(__GNUC__)
#define GCC_VERSION "GCC " __VERSION__
#elif defined(__clang__)
#define GCC_VERSION "Clang " __clang_version__
#else
#define GCC_VERSION "unknown compiler"
#endif
@@ -12,6 +14,22 @@
#define MACHINE "x86_64"
#endif
#ifdef LMMS_HOST_ARM32
#define MACHINE "arm"
#endif
#ifdef LMMS_HOST_ARM64
#define MACHINE "arm64"
#endif
#ifdef LMMS_HOST_PPC32
#define MACHINE "ppc"
#endif
#ifdef LMMS_HOST_PPC64
#define MACHINE "ppc64"
#endif
#ifndef MACHINE
#define MACHINE "unknown processor"
#endif
@@ -39,3 +57,7 @@
#ifdef LMMS_BUILD_HAIKU
#define PLATFORM "Haiku"
#endif
#ifndef PLATFORM
#define PLATFORM "unknown platform"
#endif