-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
build: stop relying on CMAKE_BUILD_TYPE to determine the build type
Any logic involving CMAKE_BUILD_TYPE is automatically broken as it won't work with multi-config generators. The only exception is if we explicitly check whether the current generator is single-config as well. Instead, use generator expressions or cmake variables that allows to set options for certain build types only such as INTERPROCEDURAL_OPTIMIZATION_<CONFIG>. Opt to generate all headers with optimization level O2 with no debug information for all build types as that is the simplest way to make it behave the same for all generators.
- Loading branch information
Showing
6 changed files
with
54 additions
and
142 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#ifndef AUTO_VERSIONDEF_H | ||
#define AUTO_VERSIONDEF_H | ||
|
||
#define NVIM_VERSION_MAJOR @NVIM_VERSION_MAJOR@ | ||
#define NVIM_VERSION_MINOR @NVIM_VERSION_MINOR@ | ||
#define NVIM_VERSION_PATCH @NVIM_VERSION_PATCH@ | ||
#define NVIM_VERSION_PRERELEASE "@NVIM_VERSION_PRERELEASE@" | ||
|
||
#cmakedefine NVIM_VERSION_MEDIUM "@NVIM_VERSION_MEDIUM@" | ||
#ifndef NVIM_VERSION_MEDIUM | ||
# include "auto/versiondef_git.h" | ||
#endif | ||
|
||
#define NVIM_API_LEVEL @NVIM_API_LEVEL@ | ||
#define NVIM_API_LEVEL_COMPAT @NVIM_API_LEVEL_COMPAT@ | ||
#define NVIM_API_PRERELEASE @NVIM_API_PRERELEASE@ | ||
|
||
#define NVIM_VERSION_CFLAGS "${CMAKE_C_COMPILER} $<JOIN:$<TARGET_PROPERTY:nvim,COMPILE_OPTIONS>, > -D$<JOIN:$<TARGET_PROPERTY:nvim,COMPILE_DEFINITIONS>, -D> -I$<JOIN:$<TARGET_PROPERTY:nvim,INCLUDE_DIRECTORIES>, -I>" | ||
#define NVIM_VERSION_BUILD_TYPE "$<CONFIG>" | ||
|
||
#endif // AUTO_VERSIONDEF_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters