1 |
commit: 7a440e37c189fb350b824203221acb9ab7920824 |
2 |
Author: Michał Górny <mgorny <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Jul 19 08:02:30 2021 +0000 |
4 |
Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Aug 21 13:10:11 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/kde.git/commit/?id=7a440e37 |
7 |
|
8 |
cmake.eclass: Default CMAKE_BUILD_TYPE=RelWithDebInfo in EAPI 8 |
9 |
|
10 |
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> |
11 |
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org> |
12 |
|
13 |
eclass/cmake.eclass | 11 ++++++++--- |
14 |
1 file changed, 8 insertions(+), 3 deletions(-) |
15 |
|
16 |
diff --git a/eclass/cmake.eclass b/eclass/cmake.eclass |
17 |
index 8befd9e5a9..3021a3a2b1 100644 |
18 |
--- a/eclass/cmake.eclass |
19 |
+++ b/eclass/cmake.eclass |
20 |
@@ -42,14 +42,19 @@ _CMAKE_ECLASS=1 |
21 |
# Eclass can use different cmake binary than the one provided in by system. |
22 |
: ${CMAKE_BINARY:=cmake} |
23 |
|
24 |
+[[ ${EAPI} == 7 ]] && : ${CMAKE_BUILD_TYPE:=Gentoo} |
25 |
# @ECLASS-VARIABLE: CMAKE_BUILD_TYPE |
26 |
# @DESCRIPTION: |
27 |
# Set to override default CMAKE_BUILD_TYPE. Only useful for packages |
28 |
# known to make use of "if (CMAKE_BUILD_TYPE MATCHES xxx)". |
29 |
# If about to be set - needs to be set before invoking cmake_src_configure. |
30 |
-# You usually do *NOT* want nor need to set it as it pulls CMake default |
31 |
-# build-type specific compiler flags overriding make.conf. |
32 |
-: ${CMAKE_BUILD_TYPE:=Gentoo} |
33 |
+# |
34 |
+# The default is RelWithDebInfo as that is least likely to append undesirable |
35 |
+# flags. However, you may still need to sed CMake files or choose a different |
36 |
+# build type to achieve desirable results. |
37 |
+# |
38 |
+# In EAPI 7, the default was non-standard build type of Gentoo. |
39 |
+: ${CMAKE_BUILD_TYPE:=RelWithDebInfo} |
40 |
|
41 |
# @ECLASS-VARIABLE: CMAKE_IN_SOURCE_BUILD |
42 |
# @DEFAULT_UNSET |