# -*-Mode: Makefile;-*- (emacs! this is a makefile!) .SUFFIXES: .doc .help .html # GENHELPDEST, GENDOCDEST and HELPFILELIST are passed from 'Makefile' HELP_NAMES=$(shell cat $(HELPFILELIST)) HELP_TARGETS=$(addprefix $(GENHELPDEST)/,$(HELP_NAMES)) HELP_PLAIN=./HELP_PLAIN HELP_WRITTEN=./HELP_WRITTEN HEADER=arb_help.head SED:=$(ARBHOME)/SH/arb_sed all: info forcedoc $(HELP_TARGETS) info: @echo "----------------------------------------------------------------" @echo "Collecting documentation for external programs used in GDE menus" # @echo "HELP_TARGETS=$(HELP_TARGETS)" # ------------------------------------------------------------ # rules to generate helpfiles # we need rules here for each helpfile specified on an 'itemhelp' line in GDE menus. # # Different ways to include help are (HOWTO_ADD_GDE_HELP): # - existing file in tool directory, e.g. .@FASTDNAML # - multiple existing files in tool directory, e.g. .@CLUSTALW # - single existing files in ./HELP_PLAIN or ./HELP_WRITTEN # - files generated into ./HELP_DOC_GEN (e.g. used for html ducumentation like proml) ARBHOME=.. GDE=$(ARBHOME)/GDE GENHELP_DEPENDS=genhelp.sh Makefile.helpfiles GENHELPTREE_DEPENDS=genhelptree.sh $(GENHELP_DEPENDS) # ---------- CLUSTALW CLUSTALW=$(GDE)/CLUSTALW CLUSTALW_HELP=$(CLUSTALW)/clustalw_help CLUSTALW_DOC=$(CLUSTALW)/clustalw.doc $(GENHELPDEST)/clustalw.help: $(CLUSTALW_HELP) $(CLUSTALW_DOC) $(GENHELPTREE_DEPENDS) ./genhelptree.sh $@ "$(subst .help,,$(notdir $@))" $(HEADER) $(CLUSTALW_HELP) $(CLUSTALW_DOC) # ---------- AXML / FASTDNAML AXML_HELP=$(GDE)/AxML/AxML.doc FASTDNAML_DOC=$(GDE)/FASTDNAML/fastDNAml.doc $(GENHELPDEST)/dnaml.help: $(AXML_HELP) $(FASTDNAML_DOC) $(GENHELPTREE_DEPENDS) ./genhelptree.sh $@ "$(subst .help,,$(notdir $@))" $(HEADER) $(AXML_HELP) $(FASTDNAML_DOC) # ---------- READSEQ READSEQ=$(ARBHOME)/READSEQ READSEQ_DOC_NAMES=Readme Formats Readseq.help READSEQ_DOCS=$(addprefix $(READSEQ)/,$(READSEQ_DOC_NAMES)) $(GENHELPDEST)/readseq.help: $(READSEQ_DOCS) $(GENHELPTREE_DEPENDS) ./genhelptree.sh $@ "$(subst .help,,$(notdir $@))" $(HEADER) $(READSEQ_DOCS) # ---------- PHYLIP PHYLIP_DISTANCE_HELP_NAMES=fitch kitsch neighbor dnadist protdist PHYLIP_DISTANCE_HELPS=$(addsuffix .doc,$(addprefix $(GENDOCDEST)/,$(PHYLIP_DISTANCE_HELP_NAMES))) $(GENHELPDEST)/phylip_distance.help: $(PHYLIP_DISTANCE_HELPS) $(GENHELPTREE_DEPENDS) ./genhelptree.sh $@ "$(subst .help,,$(notdir $@))" $(HEADER) $(PHYLIP_DISTANCE_HELPS) # ------------------------------------------------------------ # all help files in ./HELP_PLAIN are automatically found $(GENHELPDEST)/%.help: $(HELP_PLAIN)/%.help $(HEADER) $(GENHELP_DEPENDS) ./genhelp.sh $@ "$(subst .help,,$(notdir $@))" $(HEADER) $< # all help files in ./HELP_DOC_GEN are automatically found $(GENHELPDEST)/%.help: $(GENDOCDEST)/%.doc $(HEADER) $(GENHELP_DEPENDS) ./genhelp.sh $@ "$(subst .help,,$(notdir $@))" $(HEADER) $< # ------------------------------------------------------------ # rules to generate plain doc from provided html files HELP_TREEPUZZLE=../GDE/TREEPUZZLE/doc PHYLIP_MAIN=../GDE/PHYLIP HELP_PHYLIP=$(PHYLIP_MAIN)/doc HELP_PHYML=../GDE/PHYML FORCED_DOC_NAMES=proml dnapars protpars phyml phylip LYNX_PARA=-dump -nolist -display_charset=iso-8859-1 # - convert copyright symbol dumped by lynx # - remove underscore lines dumped for "