Refs #133. Users can set COMMON_OPT flag to control CFLAGS and FFLAGS.
This commit is contained in:
parent
d007cca61d
commit
068861a927
|
@ -108,19 +108,16 @@ VERSION = 0.2.2
|
|||
# The installation directory.
|
||||
# PREFIX = /opt/OpenBLAS
|
||||
|
||||
# Common Optimization Flag; -O2 is enough.
|
||||
# DEBUG = 1
|
||||
|
||||
ifeq ($(DEBUG), 1)
|
||||
COMMON_OPT += -g
|
||||
# -DDEBUG
|
||||
else
|
||||
COMMON_OPT += -O2
|
||||
endif
|
||||
# Common Optimization Flag;
|
||||
# The default -O2 is enough.
|
||||
# COMMON_OPT = -O2
|
||||
|
||||
# Profiling flags
|
||||
COMMON_PROF = -pg
|
||||
|
||||
# Build Debug version
|
||||
# DEBUG = 1
|
||||
|
||||
#
|
||||
# End of user configuration
|
||||
#
|
||||
|
|
|
@ -687,6 +687,15 @@ AWK = awk
|
|||
REVISION = -r$(VERSION)
|
||||
MAJOR_VERSION = $(word 1,$(subst ., ,$(VERSION)))
|
||||
|
||||
ifeq ($(DEBUG), 1)
|
||||
COMMON_OPT += -g
|
||||
endif
|
||||
|
||||
ifndef COMMON_OPT
|
||||
COMMON_OPT = -O2
|
||||
endif
|
||||
|
||||
|
||||
CFLAGS = $(COMMON_OPT) $(CCOMMON_OPT) -I$(TOPDIR)
|
||||
PFLAGS = $(COMMON_OPT) $(CCOMMON_OPT) -I$(TOPDIR) -DPROFILE $(COMMON_PROF)
|
||||
|
||||
|
|
Loading…
Reference in New Issue