# Last edited on 2021-03-30 04:13:38 by jstolfi # The caller must define ${IN_PREFIX} # ${OUT_PREFIX} ${SHOW}. # # For "make coords-plot", The input file must be # "${IN_PREFIX}-pts.txt". The output will be # "${OUT_PREFIX}-pts-mag${MAG}.png" # For "make spectrum-plot" the input file must be # "${IN_PREFIX}-pts.txt". The outputs will be # "${OUT_PREFIX}-rms-${AXIS}-mag${MAG}.png" # # The ${SHOW} should be 1 to display the plots, 0 to just generate them. PROGDIR := .. ANALYZER := ${PROGDIR}/curve_spectrum.py ANALYZER_IMPORTS := \ ${PROGDIR}/curve_filter.py .PHONY: all spectrum-plot all: echo "make what?" 1>&2 ; exit 1 # ---------------------------------------------------------------------- # For "make coords-plot": ifneq "/${IN_PREFIX}" "/" ifneq "/${OUT_PREFIX}" "/" PTS_FILE := ${IN_PREFIX}-pts.txt PTS_PLOT := ${OUT_PREFIX}-pts-mag0.png coords-plot: ${PTS_FILE} ${PTS_PLOT} ${PTS_PLOT}: ${PTS_FILE} ${PROGDIR}/plot_coords.sh ${PROGDIR}/plot_coords.sh ${PTS_FILE} ${OUT_PREFIX} ${SHOW} PTS_FILE := ${IN_PREFIX}-pts.txt RMS_FILE := ${OUT_PREFIX}-rms.txt RMS_PLOT := ${OUT_PREFIX}-rms-X-mag0.png spectrum-plot: ${PTS_FILE} ${RMS_FILE} ${RMS_PLOT} ${RMS_FILE}: ${ANALYZER} ${ANALYZER_IMPORTS} ${PTS_FILE} ${ANALYZER} ${PTS_FILE} ${OUT_PREFIX} ${RMS_PLOT}: ${RMS_FILE} ${PROGDIR}/plot_spectrum.sh ${PROGDIR}/plot_spectrum.sh ${RMS_FILE} ${OUT_PREFIX} ${SHOW} endif endif # End of recursive make stuff. # ----------------------------------------------------------------------