JARFLAGS = cf
INTFACE_DIR = iotcode/interfaces
-all: light camera labroom
+all: light camera labroom greenlawn sprinkler moisture weathergateway
# Compile
#
cp LabRoom/LabRoom.config $(BIN_DIR)/iotcode/LabRoom
cd $(BIN_DIR)/iotcode/LabRoom; $(JAR) $(JARFLAGS) LabRoom.jar ../../iotcode/LabRoom/*.class ../../iotcode/interfaces/Room*.class
+PHONY += greenlawn
+greenlawn:
+ $(JAVAC) $(JFLAGS) GreenLawn/*.java
+ cp GreenLawn/GreenLawn.config $(BIN_DIR)/iotcode/GreenLawn
+ cd $(BIN_DIR)/iotcode/GreenLawn; $(JAR) $(JARFLAGS) GreenLawn.jar ../../iotcode/GreenLawn/*.class ../../iotcode/interfaces/Lawn*.class
+
+PHONY += sprinkler
+sprinkler:
+ $(JAVAC) $(JFLAGS) EspSprinkler/*.java
+ cp EspSprinkler/EspSprinkler.config $(BIN_DIR)/iotcode/EspSprinkler
+ cd $(BIN_DIR)/iotcode/EspSprinkler; $(JAR) $(JARFLAGS) EspSprinkler.jar ../../iotcode/EspSprinkler/*.class ../../iotcode/interfaces/Sprinkler*.class ../../iotcode/interfaces/ZoneState*.class
+
+PHONY += moisture
+moisture:
+ $(JAVAC) $(JFLAGS) SpruceSensor/*.java
+ cp SpruceSensor/SpruceSensor.config $(BIN_DIR)/iotcode/SpruceSensor
+ cd $(BIN_DIR)/iotcode/SpruceSensor; $(JAR) $(JARFLAGS) SpruceSensor.jar ../../iotcode/SpruceSensor/*.class ../../iotcode/interfaces/MoistureSensor*.class ../../iotcode/
+
+PHONY += weathergateway
+weathergateway:
+ $(JAVAC) $(JFLAGS) WeatherPhoneGateway/*.java
+ cp WeatherPhoneGateway/WeatherPhoneGateway.config $(BIN_DIR)/iotcode/WeatherPhoneGateway
+ cd $(BIN_DIR)/iotcode/WeatherPhoneGateway; $(JAR) $(JARFLAGS) WeatherPhoneGateway.jar ../../iotcode/WeatherPhoneGateway/*.class ../../iotcode/interfaces/WeatherGateway*.class
+
.PHONY: $(PHONY)