endif # CFLAGS
endif # +cflags
-# If none of the above worked, default to "-g".
+# If none of the above worked, default to "-g -O".
ifeq "$(strip $(+cflags))" ""
+cflags := $(default_cflags)
endif # $(+cflags) == ""
# The PIC object files are named foo.so.
object-suffixes += .so
CPPFLAGS-.so = -DPIC
-CFLAGS-.so = -fPIC
+CFLAGS-.so = -fPIC -fno-common
libtype.so := lib%_pic.a
endif
ifeq (yes,$(build-profile))