| JDK_HOME := /opt/openjdk7 |
| JDK_JAVAC = $(JDK_HOME)/bin/javac |
| #JDK_JAVAC_FLAGS += -source 1.7 -target 1.7 |
| JAR = $(JDK_HOME)/bin/jar |
| |
| COMMONMARK_VERSION := 0.12.1 |
| #COMMONMARK_VERSION := 0.15.2 |
| #COMMONMARK_VERSION := 0.16.1 |
| SERVLET_VERSION := 2.5.0.v201103041518 |
| JETTY_VERSION := 9.2.30.v20200428 |
| |
| CLASS_PATH := ../blame-cache/blame-cache.jar:../gitiles-servlet/gitiles-servlet.jar:/opt/apache-commons/commons-lang3/commons-lang3-3.8.1.jar:/opt/gson/gson-2.7.jar:/opt/guava/guava-20.0.jar:/opt/joda-time/joda-time-2.12.7.jar:/opt/jsr305/jsr305-3.0.2.jar:/opt/commonmark-java/commonmark/commonmark-$(COMMONMARK_VERSION).jar:/opt/commonmark-java/commonmark-ext-autolink/commonmark-ext-autolink-$(COMMONMARK_VERSION).jar:/opt/commonmark-java/commonmark-ext-gfm-strikethrough/commonmark-ext-gfm-strikethrough-$(COMMONMARK_VERSION).jar:/opt/commonmark-java/commonmark-ext-gfm-tables/commonmark-ext-gfm-tables-$(COMMONMARK_VERSION).jar:/opt/java-prettify/java-prettify.jar:/opt/org.eclipse.jgit.archive/org.eclipse.jgit.archive-4.5.7.201904151645-r.jar:/opt/org.eclipse.jgit.http.server/org.eclipse.jgit.http.server-4.5.7.201904151645-r.jar:/opt/org.eclipse.jgit/org.eclipse.jgit-4.5.7.201904151645-r.jar:/opt/slf4j-api/slf4j-api-1.7.36.jar:/opt/closure-templates/soy/soy-2017-08-08.jar:/opt/javax.servlet-api/javax.servlet-$(SERVLET_VERSION).jar:/opt/jetty-distribution-$(JETTY_VERSION)/lib/jetty-servlet-$(JETTY_VERSION).jar:/opt/jetty-distribution-$(JETTY_VERSION)/lib/jetty-server-$(JETTY_VERSION).jar:/opt/jetty-distribution-$(JETTY_VERSION)/lib/jetty-util-$(JETTY_VERSION).jar |
| |
| CLASSES := \ |
| build/com/google/gitiles/dev/DevServer.class \ |
| build/com/google/gitiles/dev/Main.class |
| |
| default: build gitiles-dev.jar |
| |
| gitiles-dev.jar: $(CLASSES) |
| cd build && $(JAR) -c $(patsubst build/%,%,$(subst $$,\$$,$^)) > ../$@ |
| |
| clean: |
| rm -f gitiles-dev.jar $(subst $$,\$$,$(CLASSES)) |
| |
| build: |
| mkdir $@ |
| |
| build/%.class: src/main/java/%.java |
| $(JDK_JAVAC) $(JDK_JAVAC_FLAGS) -classpath build:$(CLASS_PATH):src/main/java -d build $< |
| |
| build/%$$*.class: src/main/java/%.java |