0004-Makefile.system-don-t-specify-optimization-level-bui.patch 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. From 6d1c1350977d74fb2239f765bd92a5763cd3bb73 Mon Sep 17 00:00:00 2001
  2. From: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com>
  3. Date: Fri, 5 Mar 2021 14:09:23 +0100
  4. Subject: [PATCH] Makefile.system: don't specify optimization level
  5. [buildroot-specific]
  6. Buildroot will pass an optimization level, but it is ignored because the
  7. openblas makefiles _append_ to the flags passed on the command-line.
  8. The CFLAGS/FFLAGS would e.g. contain '-Os -O2' in which -O2 survives.
  9. Remove the optimization level specified in openblas itself.
  10. Signed-off-by: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com>
  11. ---
  12. Makefile.system | 4 ++--
  13. 1 file changed, 2 insertions(+), 2 deletions(-)
  14. diff --git a/Makefile.system b/Makefile.system
  15. index 1e30d05a..04b0be16 100644
  16. --- a/Makefile.system
  17. +++ b/Makefile.system
  18. @@ -1216,11 +1216,11 @@ FCOMMON_OPT += -g
  19. endif
  20. ifndef COMMON_OPT
  21. -COMMON_OPT = -O2
  22. +COMMON_OPT =
  23. endif
  24. ifndef FCOMMON_OPT
  25. -FCOMMON_OPT = -O2 -frecursive
  26. +FCOMMON_OPT = -frecursive
  27. endif
  28. override CFLAGS += $(COMMON_OPT) $(CCOMMON_OPT) -I$(TOPDIR)
  29. --
  30. 2.26.2