Closed yurivict closed 3 years ago
We have not seen this in our other OS builds. Could you tell me more about the build?
What settings did you set in the makefile?
Could you have old .o files from previous builds? If so, try make clean, make.
What settings did you set in the makefile?
All usual variables are set by the framework: CFLAGS/CXXFLAGS/LDFLAGS.
Could you have old .o files from previous builds? If so, try make clean, make.
No, the build is clean. It is done by the ports framework, as for all other ports.
`INSTALL_DIR ?= "\"Enter_your_mothur_install_path_here\""
OPTIMIZE ?= yes USEREADLINE ?= no USEBOOST ?= no USEHDF5 ?= no USEGSL ?= no LOGFILE_NAME ?= no
BOOST_LIBRARY_DIR ?= "\"Enter_your_boost_library_path_here\"" BOOST_INCLUDE_DIR ?= "\"Enter_your_boost_include_path_here\"" HDF5_LIBRARY_DIR ?= "\"Enter_your_HDF5_library_path_here\"" HDF5_INCLUDE_DIR ?= "\"Enter_your_HDF5_include_path_here\"" GSL_LIBRARY_DIR ?= "\"Enter_your_GSL_library_path_here\"" GSL_INCLUDE_DIR ?= "\"Enter_your_GSL_include_path_here\"" MOTHUR_FILES="\"Enter_your_default_path_here\"" MOTHUR_TOOLS="\"Enter_your_mothur_tools_path_here\"" VERSION = "\"1.44.3\""
ifeq ($(strip $(LOGFILE_NAME)),yes) LOGFILE_NAME="\"silent\"" endif
ifeq ($(strip $(OPTIMIZE)),yes) CXXFLAGS += -O3 endif
CXXFLAGS += -std=c++11 -pthread -DVERSION=${VERSION} LDFLAGS += -std=c++11 -pthread
ifeq ($(strip $(MOTHUR_FILES)),"\"Enter_your_default_path_here\"") else CXXFLAGS += -DMOTHUR_FILES=${MOTHUR_FILES} endif
ifeq ($(strip $(MOTHUR_TOOLS)),"\"Enter_your_mothur_tools_path_here\"") else CXXFLAGS += -DMOTHUR_TOOLS=${MOTHUR_TOOLS} endif
ifeq ($(strip $(USEREADLINE)),yes) CXXFLAGS += -DUSE_READLINE LIBS += -lreadline endif
ifeq ($(strip $(USEBOOST)),yes)
LDFLAGS += -L ${BOOST_LIBRARY_DIR}
LIBS += -lboost_iostreams -lz
CXXFLAGS += -DUSE_BOOST -I ${BOOST_INCLUDE_DIR}
endif
ifeq ($(strip $(USEHDF5)),yes)
LDFLAGS += -L ${HDF5_LIBRARY_DIR} LIBS += -lhdf5 -lhdf5_cpp CXXFLAGS += -DUSE_HDF5 -I ${HDF5_INCLUDE_DIR}
endif
ifeq ($(strip $(USEGSL)),yes)
LDFLAGS += -L ${GSL_LIBRARY_DIR} LIBS += -lgsl -lgslcblas -lm CXXFLAGS += -DUSE_GSL -I ${GSL_INCLUDE_DIR}
endif
VPATH=source/calculators:source/chimera:source/classifier:source/clearcut:source/commands:source/communitytype:source/datastructures:source/engines:source/metastats:source/read:source/svm:source/ skipUchime := source/uchime_src/ subdirs := $(sort $(dir $(filter-out $(skipUchime), source/, $(wildcard source/*/)))) subDirIncludes = $(patsubst %, -I %, $(subdirs)) subDirLinking = $(patsubst %, -L%, $(subdirs)) CXXFLAGS += -I. $(subDirIncludes) LDFLAGS += $(subDirLinking)
OBJECTS=$(patsubst %.cpp,%.o,$(wildcard $(addsuffix *.cpp,$(subdirs))))
OBJECTS+=$(patsubst %.c,%.o,$(wildcard $(addsuffix *.c,$(subdirs))))
OBJECTS+=$(patsubst %.cpp,%.o,$(wildcard *.cpp))
OBJECTS+=$(patsubst %.c,%.o,$(wildcard *.c))
mothur : $(OBJECTS) uchime $(CXX) $(LDFLAGS) $(TARGET_ARCH) -o $@ $(OBJECTS) $(LIBS)
uchime : cd source/uchime_src && export CXX=$(CXX) && make clean && make && mv uchime ../../ && cd ..
install : mothur
ifeq ($(strip $(INSTALL_DIR)),"\"Enter_your_mothur_install_path_here\"") else mkdir -p ${INSTALL_DIR} mv mothur ${INSTALL_DIR}/mothur endif
%.o : %.c %.h $(COMPILE.c) $(OUTPUT_OPTION) $< %.o : %.cpp %.h $(COMPILE.cpp) $(OUTPUT_OPTION) $< %.o : %.cpp %.hpp $(COMPILE.cpp) $(OUTPUT_OPTION) $<
clean : @rm -f $(OBJECTS)'
Can you try compiling with the this makefile?
The link line simply contains source/averagelinkage.o
twice:
c++ -L/usr/local/lib -fstack-protector-strong -std=c++11 -pthread -Lsource/ -Lsource/calculators/ -Lsource/chimera/ -Lsource/classifier/ -Lsource/clearcut/ -Lsource/commands/ -Lsource/communitytype/ -Lsource/datastructures/ -Lsource/engines/ -Lsource/metastats/ -Lsource/read/ -Lsource/svm/ -o mothur source/averagelinkage.o source/calcsparcc.o source/cluster.o source/clusterclassic.o source/collect.o source/commandfactory.o source/commandoptionparser.o source/completelinkage.o source/consensus.o source/currentfile.o source/dlibshuff.o source/fileoutput.o source/gotohoverlap.o source/heatmap.o source/heatmapsim.o source/inputdata.o source/libshuff.o source/linearalgebra.o source/mothur.o source/mothurout.o source/myseqdist.o source/nast.o source/nastreport.o source/needlemanoverlap.o source/noalign.o source/opticluster.o source/optifitcluster.o source/optionparser.o source/overlap.o source/raredisplay.o source/rarefact.o source/refchimeratest.o source/sensspeccalc.o source/seqnoise.o source/singlelinkage.o source/slibshuff.o source/subsample.o source/summary.o source/trialSwap2.o source/trimoligos.o source/utils.o source/validcalculator.o source/validparameter.o source/venn.o source/vsearchfileparser.o source/weightedlinkage.o source/wilcox.o source/calculators/accuracy.o source/calculators/ace.o source/calculators/bergerparker.o source/calculators/boneh.o source/calculators/bootstrap.o source/calculators/bstick.o source/calculators/calculator.o source/calculators/canberra.o source/calculators/chao1.o source/calculators/coverage.o source/calculators/diversityutils.o source/calculators/eachgapdist.o source/calculators/eachgapignore.o source/calculators/efron.o source/calculators/erarefaction.o source/calculators/f1score.o source/calculators/fdr.o source/calculators/fn.o source/calculators/fp.o source/calculators/fpfn.o source/calculators/geom.o source/calculators/goodscoverage.o source/calculators/gower.o source/calculators/hamming.o source/calculators/heip.o source/calculators/hellinger.o source/calculators/igabundance.o source/calculators/ignoregaps.o source/calculators/igrarefaction.o source/calculators/invsimpson.o source/calculators/jackknife.o source/calculators/lnabundance.o source/calculators/lnrarefaction.o source/calculators/lnshift.o source/calculators/logsd.o source/calculators/lsabundance.o source/calculators/lsrarefaction.o source/calculators/manhattan.o source/calculators/mcc.o source/calculators/memchi2.o source/calculators/memchord.o source/calculators/memeuclidean.o source/calculators/mempearson.o source/calculators/metroig.o source/calculators/metrolognormal.o source/calculators/metrologstudent.o source/calculators/metrosichel.o source/calculators/npshannon.o source/calculators/npv.o source/calculators/odum.o source/calculators/onegapdist.o source/calculators/onegapignore.o source/calculators/parsimony.o source/calculators/ppv.o source/calculators/prng.o source/calculators/qstat.o source/calculators/sensitivity.o source/calculators/shannon.o source/calculators/shannoneven.o source/calculators/shannonrange.o source/calculators/sharedace.o source/calculators/sharedanderbergs.o source/calculators/sharedbraycurtis.o source/calculators/sharedchao1.o source/calculators/sharedjabund.o source/calculators/sharedjackknife.o source/calculators/sharedjclass.o source/calculators/sharedjest.o source/calculators/sharedjsd.o source/calculators/sharedkstest.o source/calculators/sharedkulczynski.o source/calculators/sharedkulczynskicody.o source/calculators/sharedlennon.o source/calculators/sharedmarczewski.o source/calculators/sharedmorisitahorn.o source/calculators/sharedochiai.o source/calculators/sharedrjsd.o source/calculators/sharedsobs.o source/calculators/sharedsobscollectsummary.o source/calculators/sharedsorabund.o source/calculators/sharedsorclass.o source/calculators/sharedsorest.o source/calculators/sharedthetan.o source/calculators/sharedthetayc.o source/calculators/shen.o source/calculators/siabundance.o source/calculators/simpson.o source/calculators/simpsoneven.o source/calculators/sirarefaction.o source/calculators/sishift.o source/calculators/smithwilson.o source/calculators/soergel.o source/calculators/solow.o source/calculators/spearman.o source/calculators/speciesprofile.o source/calculators/specificity.o source/calculators/structchi2.o source/calculators/structchord.o source/calculators/structeuclidean.o source/calculators/structkulczynski.o source/calculators/structpearson.o source/calculators/tn.o source/calculators/tp.o source/calculators/tptn.o source/calculators/unweighted.o source/calculators/uvest.o source/calculators/weighted.o source/calculators/whittaker.o source/chimera/bellerophon.o source/chimera/ccode.o source/chimera/chimeracheckrdp.o source/chimera/chimerarealigner.o source/chimera/chimeraslayer.o source/chimera/decalc.o source/chimera/maligner.o source/chimera/mothurchimera.o source/chimera/myPerseus.o source/chimera/pintail.o source/chimera/slayer.o source/classifier/alignnode.o source/classifier/aligntree.o source/classifier/bayesian.o source/classifier/classify.o source/classifier/kmernode.o source/classifier/kmertree.o source/classifier/knn.o source/classifier/opticlassifier.o source/classifier/phylosummary.o source/classifier/phylotree.o source/classifier/taxonomyequalizer.o source/classifier/taxonomynode.o source/clearcut/clearcut.o source/clearcut/cmdargs.o source/clearcut/distclearcut.o source/clearcut/dmat.o source/clearcut/fasta.o source/clearcut/getopt_long.o source/commands/aligncheckcommand.o source/commands/aligncommand.o source/commands/amovacommand.o source/commands/anosimcommand.o source/commands/binsequencecommand.o source/commands/biominfocommand.o source/commands/chimerabellerophoncommand.o source/commands/chimeraccodecommand.o source/commands/chimeracheckcommand.o source/commands/chimeraperseuscommand.o source/commands/chimerapintailcommand.o source/commands/chimeraslayercommand.o source/commands/chimerauchimecommand.o source/commands/chimeravsearchcommand.o source/commands/chopseqscommand.o source/commands/classifyotucommand.o source/commands/classifyseqscommand.o source/commands/classifysvmsharedcommand.o source/commands/classifytreecommand.o source/commands/clearcutcommand.o source/commands/clustercommand.o source/commands/clusterdoturcommand.o source/commands/clusterfitcommand.o source/commands/clusterfragmentscommand.o source/commands/clustersplitcommand.o source/commands/collectcommand.o source/commands/collectsharedcommand.o source/commands/consensusseqscommand.o source/commands/cooccurrencecommand.o source/commands/corraxescommand.o source/commands/countgroupscommand.o source/commands/countseqscommand.o source/commands/createdatabasecommand.o source/commands/deconvolutecommand.o source/commands/degapseqscommand.o source/commands/deuniqueseqscommand.o source/commands/deuniquetreecommand.o source/commands/distancecommand.o source/commands/distsharedcommand.o source/commands/diversityestimatorcommand.o source/commands/filterseqscommand.o source/commands/filtersharedcommand.o source/commands/getcoremicrobiomecommand.o source/commands/getcurrentcommand.o source/commands/getdistscommand.o source/commands/getgroupcommand.o source/commands/getgroupscommand.o source/commands/getlabelcommand.o source/commands/getlineagecommand.o source/commands/getlistcountcommand.o source/commands/getmetacommunitycommand.o source/commands/getmimarkspackagecommand.o source/commands/getoturepcommand.o source/commands/getotuscommand.o source/commands/getrabundcommand.o source/commands/getrelabundcommand.o source/commands/getsabundcommand.o source/commands/getseqscommand.o source/commands/getsharedotucommand.o source/commands/heatmapcommand.o source/commands/heatmapsimcommand.o source/commands/helpcommand.o source/commands/homovacommand.o source/commands/indicatorcommand.o source/commands/kruskalwalliscommand.o source/commands/lefsecommand.o source/commands/libshuffcommand.o source/commands/listotuscommand.o source/commands/listseqscommand.o source/commands/makebiomcommand.o source/commands/makeclrcommand.o source/commands/makecontigscommand.o source/commands/makefastqcommand.o source/commands/makefilecommand.o source/commands/makegroupcommand.o source/commands/makelefsecommand.o source/commands/makelookupcommand.o source/commands/makesharedcommand.o source/commands/mantelcommand.o source/commands/mergecountcommand.o source/commands/mergefilecommand.o source/commands/mergegroupscommand.o source/commands/mergeotuscommand.o source/commands/mergesfffilecommand.o source/commands/mergetaxsummarycommand.o source/commands/metastatscommand.o source/commands/mgclustercommand.o source/commands/mimarksattributescommand.o source/commands/newcommandtemplate.o source/commands/nmdscommand.o source/commands/nocommands.o source/commands/normalizesharedcommand.o source/commands/otuassociationcommand.o source/commands/otuhierarchycommand.o source/commands/pairwiseseqscommand.o source/commands/parsefastaqcommand.o source/commands/parsimonycommand.o source/commands/pcacommand.o source/commands/pcoacommand.o source/commands/pcrseqscommand.o source/commands/phylodiversitycommand.o source/commands/phylotypecommand.o source/commands/preclustercommand.o source/commands/primerdesigncommand.o source/commands/quitcommand.o source/commands/rarefactcommand.o source/commands/rarefactsharedcommand.o source/commands/removedistscommand.o source/commands/removegroupscommand.o source/commands/removelineagecommand.o source/commands/removeotuscommand.o source/commands/removerarecommand.o source/commands/removeseqscommand.o source/commands/renamefilecommand.o source/commands/renameseqscommand.o source/commands/reversecommand.o source/commands/screenseqscommand.o source/commands/sensspeccommand.o source/commands/seqerrorcommand.o source/commands/seqsummarycommand.o source/commands/setcurrentcommand.o source/commands/setdircommand.o source/commands/setlogfilecommand.o source/commands/setseedcommand.o source/commands/sffinfocommand.o source/commands/sffmultiplecommand.o source/commands/shhhercommand.o source/commands/shhhseqscommand.o source/commands/sortseqscommand.o source/commands/sparcccommand.o source/commands/splitabundcommand.o source/commands/splitgroupscommand.o source/commands/sracommand.o source/commands/srainfocommand.o source/commands/subsamplecommand.o source/commands/summarycommand.o source/commands/summaryqualcommand.o source/commands/summarysharedcommand.o source/commands/summarytaxcommand.o source/commands/systemcommand.o source/commands/treesharedcommand.o source/commands/trimflowscommand.o source/commands/trimseqscommand.o source/commands/unifracunweightedcommand.o source/commands/unifracweightedcommand.o source/commands/venncommand.o source/communitytype/communitytype.o source/communitytype/kmeans.o source/communitytype/pam.o source/communitytype/qFinderDMM.o source/datastructures/alignment.o source/datastructures/alignmentcell.o source/datastructures/alignmentdb.o source/datastructures/blastalign.o source/datastructures/blastdb.o source/datastructures/counttable.o source/datastructures/designmap.o source/datastructures/distancedb.o source/datastructures/fastamap.o source/datastructures/fastqread.o source/datastructures/filefile.o source/datastructures/flowdata.o source/datastructures/fullmatrix.o source/datastructures/groupmap.o source/datastructures/kmer.o source/datastructures/kmeralign.o source/datastructures/kmerdb.o source/datastructures/listvector.o source/datastructures/nameassignment.o source/datastructures/oligos.o source/datastructures/optiblastmatrix.o source/datastructures/optidata.o source/datastructures/optidb.o source/datastructures/optimatrix.o source/datastructures/optirefmatrix.o source/datastructures/ordervector.o source/datastructures/qualityscores.o source/datastructures/rabundfloatvector.o source/datastructures/rabundvector.o source/datastructures/reportfile.o source/datastructures/sabundvector.o source/datastructures/sequence.o source/datastructures/sequencecountparser.o source/datastructures/sequencedb.o source/datastructures/sequenceparser.o source/datastructures/sffheader.o source/datastructures/sffread.o source/datastructures/sharedclrvector.o source/datastructures/sharedclrvectors.o source/datastructures/sharedlistvector.o source/datastructures/sharedordervector.o source/datastructures/sharedrabundfloatvector.o source/datastructures/sharedrabundfloatvectors.o source/datastructures/sharedrabundvector.o source/datastructures/sharedrabundvectors.o source/datastructures/sparsedistancematrix.o source/datastructures/sparsematrix.o source/datastructures/suffixdb.o source/datastructures/suffixnodes.o source/datastructures/suffixtree.o source/datastructures/taxonomy.o source/datastructures/tree.o source/datastructures/treemap.o source/datastructures/treenode.o source/engines/batchengine.o source/engines/interactengine.o source/engines/scriptengine.o source/metastats/mothurfisher.o source/metastats/mothurmetastats.o source/read/readblast.o source/read/readcluster.o source/read/readcolumn.o source/read/readphylip.o source/read/readphylipvector.o source/read/readtree.o source/read/splitmatrix.o source/read/treereader.o source/svm/svm.o source/averagelinkage.o source/calcsparcc.o source/cluster.o source/clusterclassic.o source/collect.o source/commandfactory.o source/commandoptionparser.o source/completelinkage.o source/consensus.o source/currentfile.o source/dlibshuff.o source/fileoutput.o source/gotohoverlap.o source/heatmap.o source/heatmapsim.o source/inputdata.o source/libshuff.o source/linearalgebra.o source/mothur.o source/mothurout.o source/myseqdist.o source/nast.o source/nastreport.o source/needlemanoverlap.o source/noalign.o source/opticluster.o source/optifitcluster.o source/optionparser.o source/overlap.o source/raredisplay.o source/rarefact.o source/refchimeratest.o source/sensspeccalc.o source/seqnoise.o source/singlelinkage.o source/slibshuff.o source/subsample.o source/summary.o source/trialSwap2.o source/trimoligos.o source/utils.o source/validcalculator.o source/validparameter.o source/venn.o source/vsearchfileparser.o source/weightedlinkage.o source/wilcox.o -L/usr/local/lib -lreadline
This is maybe tolerated by the linux gcc-based toolchain, but this isn't tolerated by the clang-based toolchain.
It looks like the source directory object files are getting added twice. Try changing this line in the make file:
subdirs := $(sort $(dir $(filter-out $(skipUchime), source/, $(wildcard source/*/))))
to
subdirs := $(sort $(dir $(filter-out $(skipUchime), $(wildcard source/*/))))
This issue is closed bu the bug is still present.
Version: 1.44.3 OS: FreeBSD 12.2 clang-10