diff options
Diffstat (limited to 'tmk_core/common.mk')
| -rw-r--r-- | tmk_core/common.mk | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/tmk_core/common.mk b/tmk_core/common.mk index 56ed4a857..a6c439f5c 100644 --- a/tmk_core/common.mk +++ b/tmk_core/common.mk | |||
| @@ -160,16 +160,13 @@ ifeq ($(strip $(SHARED_EP_ENABLE)), yes) | |||
| 160 | endif | 160 | endif |
| 161 | 161 | ||
| 162 | ifeq ($(strip $(LTO_ENABLE)), yes) | 162 | ifeq ($(strip $(LTO_ENABLE)), yes) |
| 163 | LINK_TIME_OPTIMIZATION_ENABLE = yes | ||
| 164 | endif | ||
| 165 | |||
| 166 | ifeq ($(strip $(LINK_TIME_OPTIMIZATION_ENABLE)), yes) | ||
| 167 | ifeq ($(PLATFORM),CHIBIOS) | 163 | ifeq ($(PLATFORM),CHIBIOS) |
| 168 | $(info Enabling LTO on ChibiOS-targeting boards is known to have a high likelihood of failure.) | 164 | $(info Enabling LTO on ChibiOS-targeting boards is known to have a high likelihood of failure.) |
| 169 | $(info If unsure, set LINK_TIME_OPTIMIZATION_ENABLE = no.) | 165 | $(info If unsure, set LTO_ENABLE = no.) |
| 170 | endif | 166 | endif |
| 171 | EXTRAFLAGS += -flto | 167 | EXTRAFLAGS += -flto |
| 172 | TMK_COMMON_DEFS += -DLINK_TIME_OPTIMIZATION_ENABLE | 168 | TMK_COMMON_DEFS += -DLTO_ENABLE |
| 169 | TMK_COMMON_DEFS += -DLINK_TIME_OPTIMIZATON_ENABLE | ||
| 173 | endif | 170 | endif |
| 174 | 171 | ||
| 175 | # Search Path | 172 | # Search Path |
