R = $(R_HOME)/bin/R

# rules
%.R: %.Rnw
	@echo "Stangle $<";$(R) CMD Stangle $<

%.tex:%.Rnw
	@echo "Sweave $<";$(R) CMD Sweave $<

%.pdf:%.tex
	@echo "making $@";$(R) CMD texi2dvi --pdf -c -q $<

all:
	echo "Usage: make -f devmakefile YourSlides.pdf"



# PDF = NativeInterfaces.pdf
# RNW = NativeInterfaces.Rnw
# TEX = NativeInterfaces.tex

# all: $(PDF)

# $(PDF): $(TEX)
# 	$(R) CMD texi2dvi --pdf -q -c $<

# $(TEX): $(RNW)
# 	$(R) CMD Sweave $<

# clean:
# 	-rm -v $(PDF) $(TEX)
