1 #Directory structure for web targets
3 HTSRCDIR
:= $(PROJDIR
)/html
4 JSSRCDIR
:= $(HTSRCDIR
)/js
6 #Discover each type of object supported
7 HTSRC
:= $(wildcard $(HTSRCDIR
)/*.html
)
8 JSSRC
:= $(wildcard $(JSSRCDIR
)/*.js
)
9 WEBSRC
:= $(HTSRC
) $(JSSRC
)
11 #Translate sources into their required targets in APPDIR
12 WEBTARG
:= $(patsubst $(HTSRCDIR
)/%,$(DISTDIR
)/%,$(WEBSRC
))
14 #Add APPDEPS for all web objects so they must be created
15 #at build time, before compilation of the main executable
17 APPDIRS
+= $(dir $(WEBTARG
))
19 #In Makefile, we will use WEBTARG to define rules for "making"
20 #these targets (with a cp action) and cleaning (with rm)