# Makefile for modern grids CC = gcc CFLAGS = -O2 SRC = ../../src BIN = ../../bin TBASE = ../../tbase/patched/tbase.bin ETOPO5 = ../../etopo5/etopo5.img all: grid10me.txt grid20me.txt grid25me.txt grid30me.txt grid35me.txt \ grid40me.txt grid45me.txt grid50me.txt grid60me.txt \ grid10mt.txt grid20mt.txt grid25mt.txt grid30mt.txt \ grid35mt.txt grid40mt.txt grid45mt.txt grid50mt.txt \ grid60mt.txt $(BIN)/subset_topo: $(SRC)/subset_topo.c $(CC) $(CFLAGS) $(SRC)/subset_topo.c -o $(BIN)/subset_topo -lm $(BIN)/q1x1: $(SRC)/q1x1.c $(CC) $(CFLAGS) $(SRC)/q1x1.c -o $(BIN)/q1x1 # Grids based on ETOPO5 grid10me.txt: $(ETOPO5) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(ETOPO5) -add -10 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid10me.txt rm topo.tmp grid20me.txt: $(ETOPO5) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(ETOPO5) -add -20 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid20me.txt rm topo.tmp grid25me.txt: $(ETOPO5) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(ETOPO5) -add -25 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid25me.txt rm topo.tmp grid30me.txt: $(ETOPO5) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(ETOPO5) -add -30 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid30me.txt rm topo.tmp grid35me.txt: $(ETOPO5) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(ETOPO5) -add -35 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid35me.txt rm topo.tmp grid40me.txt: $(ETOPO5) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(ETOPO5) -add -40 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid40me.txt rm topo.tmp grid45me.txt: $(ETOPO5) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(ETOPO5) -add -45 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid45me.txt rm topo.tmp grid50me.txt: $(ETOPO5) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(ETOPO5) -add -50 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid50me.txt rm topo.tmp grid60me.txt: $(ETOPO5) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(ETOPO5) -add -60 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid60me.txt rm topo.tmp # Grids based on TerrainBase grid10mt.txt: $(TBASE) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(TBASE) -add -10 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid10mt.txt rm topo.tmp grid20mt.txt: $(TBASE) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(TBASE) -add -20 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid20mt.txt rm topo.tmp grid25mt.txt: $(TBASE) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(TBASE) -add -25 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid25mt.txt rm topo.tmp grid30mt.txt: $(TBASE) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(TBASE) -add -30 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid30mt.txt rm topo.tmp grid35mt.txt: $(TBASE) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(TBASE) -add -35 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid35mt.txt rm topo.tmp grid40mt.txt: $(TBASE) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(TBASE) -add -40 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid40mt.txt rm topo.tmp grid45mt.txt: $(TBASE) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(TBASE) -add -45 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid45mt.txt rm topo.tmp grid50mt.txt: $(TBASE) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(TBASE) -add -50 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid50mt.txt rm topo.tmp grid60mt.txt: $(TBASE) $(BIN)/subset_topo $(BIN)/q1x1 $(BIN)/subset_topo $(TBASE) -add -60 -byte LSBfirst -output topo.tmp $(BIN)/q1x1 topo.tmp >grid60mt.txt rm topo.tmp # end