projects
/
openwrt
/
staging
/
linusw.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f60bbfa
)
rules.mk: set default host tools GCC optimization level to -O2
author
Shiji Yang
<
[email protected]
>
Fri, 16 May 2025 10:56:36 +0000
(18:56 +0800)
committer
Robert Marko
<
[email protected]
>
Fri, 16 May 2025 11:16:15 +0000
(13:16 +0200)
This patch can help save over 60% of package build time. -O2
optimization level is the default value before the commit
e8b470139c78
("tools: add options to optimize host binaries").
Signed-off-by: Shiji Yang <
[email protected]
>
Link:
https://github.com/openwrt/openwrt/pull/18812
Signed-off-by: Robert Marko <
[email protected]
>
rules.mk
patch
|
blob
|
history
diff --git
a/rules.mk
b/rules.mk
index ccf97fe7b7bb9b5eefebd6b173ac1a7b6746f093..3971852f454a310fdea0d2b7ed042c1e386533f7 100644
(file)
--- a/
rules.mk
+++ b/
rules.mk
@@
-278,7
+278,7
@@
PKG_CONFIG:=$(STAGING_DIR_HOST)/bin/pkg-config
export PKG_CONFIG
-HOST_FLAGS_OPT:=$(
call qstrip,$(CONFIG_HOST_FLAGS_OPT)
)
+HOST_FLAGS_OPT:=$(
if $(CONFIG_HOST_FLAGS_OPT),$(call qstrip,$(CONFIG_HOST_FLAGS_OPT)),"-O2"
)
HOST_FLAGS_STRIP:=$(call qstrip,$(CONFIG_HOST_FLAGS_STRIP))
HOST_EXTRA_CFLAGS:=$(call qstrip,$(CONFIG_HOST_EXTRA_CFLAGS))
HOST_EXTRA_CXXFLAGS:=$(call qstrip,$(CONFIG_HOST_EXTRA_CXXFLAGS))