[prev in list] [next in list] [prev in thread] [next in thread]
List: lyx-cvs
Subject: [LyX/master] Cmake build: Extend build info in Help>About
From: Kornel Benko <kornel () lyx ! org>
Date: 2020-03-25 12:33:15
Message-ID: 20200325123315.5EE342805F5 () lyx ! lyx ! org
[Download RAW message or body]
commit 3df9525a13de33b235d41a94cac9d2b1b8546c9b
Author: Kornel Benko <kornel@lyx.org>
Date: Wed Mar 25 13:48:16 2020 +0100
Cmake build: Extend build info in Help>About
Added list of used cmake options and info about used compiler
---
CMakeLists.txt | 32 ++++++++++++++++++++++++++++++--
1 files changed, 30 insertions(+), 2 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 76c4d57..202e341 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -317,8 +317,6 @@ else()
endif()
-set(VERSION_INFO "CMake Build")
-
# Try to get some informations from configure.ac
include(LyXPaths)
@@ -1070,6 +1068,36 @@ endif()
include(${LYX_CMAKE_DIR}/ConfigureChecks.cmake)
configure_file(${LYX_CMAKE_DIR}/configCompiler.h.cmake \
${TOP_BINARY_DIR}/configCompiler.h)
+set(opts)
+foreach(_option ${LYX_OPTIONS})
+ if(${_option}_show_message)
+ string(SUBSTRING "${_option} " 0 31 _var)
+ get_property(_prop CACHE ${_option} PROPERTY STRINGS)
+ list(FIND LYX_OPTION_STRINGS ${_option} _index)
+ if (${_index} GREATER -1)
+ set(_isset ${${_option}})
+ elseif(${_option})
+ set(_isset ON)
+ else()
+ set(_isset OFF)
+ endif()
+ string(SUBSTRING "${_isset} " 0 10 _val)
+ set(opts "${opts} ${_option}(${${_option}})")
+ endif()
+endforeach()
+set(VERSION_INFO "CMake Build")
+set(VERSION_INFO "${VERSION_INFO}\\n Host name: \
${CMAKE_HOST_SYSTEM_NAME}") +set(VERSION_INFO "${VERSION_INFO}\\n Host processor: \
${CMAKE_HOST_SYSTEM_PROCESSOR}") +set(VERSION_INFO "${VERSION_INFO}\\n Build flags: \
${opts}") +set(VERSION_INFO "${VERSION_INFO}\\n C++ Compiler: \
${CMAKE_CXX_COMPILER_ID} (${CMAKE_CXX_COMPILER_VERSION})") +set(VERSION_INFO \
"${VERSION_INFO}\\n C++ Compiler flags: ${CMAKE_CXX_FLAGS}") +if (LYX_DEBUG)
+set(VERSION_INFO "${VERSION_INFO}\\n C++ Compiler user flags: \
${CMAKE_CXX_FLAGS_DEBUG}") +else()
+set(VERSION_INFO "${VERSION_INFO}\\n C++ Compiler user flags: \
${CMAKE_CXX_FLAGS_RELEASE}") +endif()
+
+
configure_file(${LYX_CMAKE_DIR}/config.h.cmake ${TOP_BINARY_DIR}/config.h)
if(QTVERSION MATCHES "^([0-9]+)\\.([0-9]+)\\.([0-9]+).*")
--
lyx-cvs mailing list
lyx-cvs@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-cvs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic