1 ### 2 # Configuration variables. 3 4 OS := $(shell uname) 5 6 # Assume make is always run from top-level of source directory. Note than an 7 # Apple style build overrides these variables later in the makefile. 8 ProjSrcRoot := $(shell pwd) 9 ProjObjRoot := $(ProjSrcRoot) 10 11 # The list of modules which are required to be built into every library. This 12 # should only be used for internal utilities which could be used in any other 13 # module. Any other cases the platform should be allowed to opt-in to. 14 AlwaysRequiredModules := int_util 15 16 ### 17 # Tool configuration variables. 18 19 # FIXME: LLVM uses autoconf/mkinstalldirs ? 20 MKDIR := mkdir -p 21 DATE := date 22 LIPO := lipo 23 CP := cp 24 DSYMUTIL := dsymutil 25 26 VERBOSE := 0 27 DEBUGMAKE := 28 29 ### 30 # Automatic and derived variables. 31 32 # Adjust settings for verbose mode 33 ifneq ($(VERBOSE),1) 34 Verb := @ 35 else 36 Verb := 37 endif 38 39 Echo := @echo 40 ifndef Summary 41 Summary = $(Echo) 42 endif 43 44 ### 45 # Common compiler options 46 COMMON_INCLUDES=-I${ProjSrcRoot}/lib -I${ProjSrcRoot}/include 47 COMMON_CXXFLAGS=-std=c++11 -fno-exceptions -fPIC -funwind-tables $(COMMON_INCLUDES) 48 COMMON_CFLAGS=-fPIC $(COMMON_INCLUDES) 49 COMMON_ASMFLAGS=$(COMMON_INCLUDES) 50