1 ###################################################
4 # Created: June 29, 2010
6 ###################################################
17 MOTHUR_FILES="\"Enter_your_default_path_here\""
18 RELEASE_DATE = "\"1/9/2012\""
19 VERSION = "\"1.23.0\""
20 FORTAN_COMPILER = gfortran
22 # Optimize to level 3:
25 ifeq ($(strip $(64BIT_VERSION)),yes)
26 #if you are using centos uncomment the following lines
29 #if you are a mac user use the following line
30 TARGET_ARCH += -arch x86_64
32 #if you using cygwin to build Windows the following line
33 #CXX = x86_64-w64-mingw32-g++
34 #CC = x86_64-w64-mingw32-g++
35 #FORTAN_COMPILER = x86_64-w64-mingw32-gfortran
36 #TARGET_ARCH += -m64 -static
38 #if you are a linux user use the following line
39 #CXXFLAGS += -mtune=native -march=native -m64
41 CXXFLAGS += -DBIT_VERSION
45 CXXFLAGS += -DRELEASE_DATE=${RELEASE_DATE} -DVERSION=${VERSION}
47 ifeq ($(strip $(MOTHUR_FILES)),"\"Enter_your_default_path_here\"")
49 CXXFLAGS += -DMOTHUR_FILES=${MOTHUR_FILES}
52 ifeq ($(strip $(CYGWIN_BUILD)),yes)
53 CXXFLAGS += -mno-cygwin
54 LDFLAGS += -mno-cygwin
57 # if you do not want to use the readline library, set this to no.
58 # make sure you have the library installed
61 ifeq ($(strip $(USEREADLINE)),yes)
62 CXXFLAGS += -DUSE_READLINE
69 ifeq ($(strip $(USEMPI)),yes)
74 # if you want to enable reading and writing of compressed files, set to yes.
75 # The default is no. this may only work on unix-like systems, not for windows.
78 ifeq ($(strip $(USECOMPRESSION)),yes)
79 CXXFLAGS += -DUSE_COMPRESSION
83 # INCLUDE directories for mothur
89 # Get the list of all .cpp files, rename to .o files
92 OBJECTS=$(patsubst %.cpp,%.o,$(wildcard *.cpp))
93 OBJECTS+=$(patsubst %.c,%.o,$(wildcard *.c))
94 OBJECTS+=$(patsubst %.f,%.o,$(wildcard *.f))
96 mothur : fortranSource $(OBJECTS) uchime
97 $(CXX) $(LDFLAGS) $(TARGET_ARCH) -o $@ $(OBJECTS) $(LIBS)
102 cd uchime_src && ./mk && mv uchime .. && cd ..
105 ${FORTAN_COMPILER} -c *.f
108 # cp mothur ../Release/mothur
111 $(COMPILE.c) $(OUTPUT_OPTION) $<
113 $(COMPILE.cpp) $(OUTPUT_OPTION) $<
115 $(COMPILE.cpp) $(OUTPUT_OPTION) $<