# | # o---------------------------------------------------------------------o # | # | MAD makefile - gcc compiler settings # | # o---------------------------------------------------------------------o # | # | Methodical Accelerator Design # | # | Copyright (c) 2011+ CERN, mad@cern.ch # | # | For more information, see http://cern.ch/mad # | # o---------------------------------------------------------------------o # | # | $Id$ # | # # makedep # CDEP = $(CC) -MM $(addprefix -I,$(CC_DIR)) # # preprocessor flags # CPPFLAGS += -D_GCC # # compiler flags # CFLAGS = -m$(ARCH) -O$(NOPT) -std=c99 -Wall -W -Wextra -pedantic -c # # options flags # ifeq ($(DEBUG),yes) CFLAGS += -g -ggdb endif ifeq ($(PROFILE),yes) CFLAGS += -pg endif ifeq ($(SHARED),yes) CFLAGS += -fPIC endif # # extra flags # CFLAGS += -pipe $(addprefix -I,$(CC_DIR)) ifeq ($(OSTYPE),Darwin) CFLAGS += -mmacosx-version-min=10.5 endif # # diagnostics (gcc is the reference) # CFLAGS += -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations \ -Wchar-subscripts -Wconversion -Wno-conversion -Winline \ -Wpointer-arith -Wbad-function-cast -Wcast-align -Wcast-qual \ -Wstrict-prototypes # -Wfloat-equal -Wformat-nonliteral -Wwrite-strings # end of makefile