# Last edited on 2008-06-10 20:38:49 by stolfi FOUR_PROG = dnafour SAMP_PROG = dnasample PROGS := \ ${FOUR_PROG} \ ${SAMP_PROG} PROGDIR := .. RUNS := \ NC_004545:00000000:0100:4096:4096 \ NC_004545:00000000:0400:1024:1024 \ NC_001489:00000000:0050:0128:0128 \ NC_001489:00000000:0007:1024:1024 \ \ NC_002488:00000000:2500:1024:1024 \ NC_002488:00000000:0500:1024:1024 \ NC_002488:00500000:0500:1024:1024 \ NC_002488:01000000:0500:1024:1024 \ NC_002488:01500000:0500:1024:1024 .PHONY:: run-all run-single # all: clean run-all all: run-all run-all: for run in ${RUNS}; do make RUN=$$run run-single ; done clean:: -rm -f */*.smp */*.pot */*.eps ###################################################################### # Sub-make - caller must define ${RUN} RUN := RUN.IS.UNDEFINED ifneq "/${RUN}" "/RUN.IS.UNDEFINED" FIELDS := ${subst :, ,${RUN}} SNAME := ${word 1,${FIELDS}} SKIP := ${word 2,${FIELDS}} NSEQS := ${word 3,${FIELDS}} SZSEQ := ${word 4,${FIELDS}} STEP := ${word 5,${FIELDS}} OUTNAME := ${SNAME}/${SKIP}-${NSEQS}-${SZSEQ}-${STEP} run-single: ${OUTNAME}-pot.eps DATADIR := ${STOLFIHOME}/programs/c/DNA/small/DATA ${OUTNAME}-pot.eps: ${OUTNAME}.pot plot-pot plot-pot ${OUTNAME} ${NSEQS} ${SZSEQ} ${OUTNAME}.pot: ${OUTNAME}.smp ${PROGDIR}/${FOUR_PROG} cat ${OUTNAME}.smp \ | ${PROGDIR}/${FOUR_PROG} ${NSEQS} ${SZSEQ} \ > ${OUTNAME}.pot ${OUTNAME}.smp: ${DATADIR}/${SNAME}.bas ${PROGDIR}/${SAMP_PROG} mkdir -p ${SNAME} cat ${DATADIR}/${SNAME}.bas \ | ${PROGDIR}/${SAMP_PROG} ${SKIP} ${NSEQS} ${SZSEQ} ${STEP} \ > ${OUTNAME}.smp endif # end ${RUN} ######################################################################