Refactor the Makefile into pieces. This commit inspired by AncientGeek, my hatred...
[freeems-vanilla.git] / Makefile
blob1a8e4aa69c5fa33af36f5c977b782218ab1624ff
1 # Top level convenience make file
3 Help:
4 @echo
5 @echo "######################## Welcome to FreeEMS! ########################"
6 @echo
7 @echo "To build, choose a target from the below list and type 'make target'!"
8 @echo "For example, to build blank unconfigured firmware type 'make BLANK'"
9 @echo "Note: For BenchTest to work you MUST build using the BENCHTEST target!"
10 @echo "Advanced users can find more options available in the src/main directory!"
11 @echo
12 @echo "Options:"
13 @echo
14 @make -qp | awk -F':' '/^[a-zA-Z0-9][^$$#\/\t=]*:([^=]|$$)/ {split($$1,A,/ /);for(i in A)print A[i]}'
16 TEST_AND_SAVE_ALL:
17 cd src/main; ../../bin/testclibuilds.bash
19 BLANK:
20 cd src/main; make clean s19
22 clean:
23 cd src/main; make clean
25 SPECIAL: # Can use a dependency here instead.
26 cd src/main; make clean EvenTeeth-Distributor-4of6and1
29 # Other special builds
31 BENCHTEST:
32 cd src/main; CLIFLAGS="DEFAULT" make clean BenchTest
33 TRUCK:
34 cd src/main; CLIFLAGS="$@" make clean MitsiAndMazda-CAS-4and1
35 HOTEL:
36 cd src/main; CLIFLAGS="$@" make clean HallOrOptical-Distributor-4of90
37 PRESTO:
38 cd src/main; CLIFLAGS="$@" make clean EvenTeeth-Cam-24and1
39 SEANKLT1:
40 cd src/main; CLIFLAGS="$@" make clean GM-LT1-CAS-360and8
41 SNOTROCKET:
42 cd src/main; CLIFLAGS="$@" make clean EvenTeeth-Cam-24and1
43 SPUDMN:
44 cd src/main; CLIFLAGS="$@" make clean MissingTeeth-Crank-8minus1
45 SLATER:
46 cd src/main; CLIFLAGS="$@" make clean MissingTeeth-Crank-12minus1
47 PETERJSERIES:
48 cd src/main; CLIFLAGS="$@" make clean JSeries-12CrankWith6-2Cam
49 DEUCECOUPE:
50 cd src/main; CLIFLAGS="$@" make clean EvenTeeth-Cam-6and1
51 PETERTRUCK:
52 cd src/main; CLIFLAGS="$@" make clean MissingTeeth-Cam-12minus1
53 SCAVENGER:
54 cd src/main; CLIFLAGS="$@" make clean MitsiAndMazda-CAS-4and2
55 DEUCES10:
56 cd src/main; CLIFLAGS="$@" make clean EvenTeeth-Cam-4and1