1. Cat's Eye Technologies
  2. Wunnel

Commits

Cat's Eye Technologies  committed 58b4cfd

GNU Make-specific conditional that makes it "just work" under Cygwin.

  • Participants
  • Parent commits 356626a
  • Branches default

Comments (0)

Files changed (1)

File Makefile

View file
  • Ignore whitespace
 
 JAVAC?=javac
 JAVA?=java
-PATHSEP?=:
+ifeq ($(OS),Windows_NT)
+  PATHSEP=;
+else
+  PATHSEP=:
+endif
 
 JFLAGS?=-Xlint:deprecation -Xlint:unchecked
 CDIR=bin/tc/catseye/wunnel
 CLASSES=$(CDIR)/WunnelState.class
 
 YOOBDIR?=../yoob
-CLASSPATH?=bin$(PATHSEP)$(YOOBDIR)/bin
+CP?=bin$(PATHSEP)$(YOOBDIR)/bin
 
 all: $(CLASSES)
 
 $(CDIR)/WunnelState.class: src/WunnelState.java
-	$(JAVAC) $(JFLAGS) -cp "$(CLASSPATH)" -d bin src/WunnelState.java
+	$(JAVAC) $(JFLAGS) -cp "$(CP)" -d bin src/WunnelState.java
 
 clean:
 	rm -rf $(CDIR)/*.class
 
 test: $(CLASSES)
-	$(JAVA) -cp "$(CLASSPATH)" tc.catseye.yoob.GUI -c "tc.catseye.wunnel.WunnelState/Wunnel" -s Wunnel
+	$(JAVA) -cp "$(CP)" tc.catseye.yoob.GUI -c "tc.catseye.wunnel.WunnelState/Wunnel" -s Wunnel