summaryrefslogtreecommitdiff
blob: 4a19d4f8a3ee235f3d4e87af70df1e054aa9ea81 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
INPUT_FILE = ../data/ast/best_chronometer_ever.xml

## Executables #################################################################
JAVAC = javac
JAVA = java
DOWNLOADER = wget

## Java Config #################################################################
CLASSPATH = "./src/"

## Dependencies ################################################################
JAR_SOURCE = https://noot-noot.org/onera_2017/jar/
REQUIRED_JARS =

## Makefile Magic ##############################################################
SOURCES = $(wildcard src/*.java)
CLASSES = $(SOURCES:.java=.class)

## Makefile Rules ##############################################################

all: structural.mod

clean:
	rm -f $(CLASSES)
	rm -f *.mod

structural.mod: $(CLASSES) $(REQUIRED_JARS) $(INPUT_FILE)
	$(JAVA) -cp $(CLASSPATH) Main $(INPUT_FILE)

%.class: %.java $(REQUIRED_JARS)
	$(JAVAC) -cp $(CLASSPATH) $<

%.jar:
	echo "Attempting to download missing jar '$@'"
	$(DOWNLOADER) "$(JAR_SOURCE)/$@"