-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
28 lines (19 loc) · 752 Bytes
/
Copy pathMakefile
File metadata and controls
28 lines (19 loc) · 752 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
all: clean install
PKG_VERS = $(shell grep -i ^version DESCRIPTION | cut -d : -d \ -f 2)
PKG_NAME = $(shell grep -i ^package DESCRIPTION | cut -d : -d \ -f 2)
.PHONY: all install build check clean vignettes
install: $(PKG_NAME)_$(PKG_VERS).tar.gz
R CMD INSTALL $<
build: $(PKG_NAME)_$(PKG_VERS).tar.gz
check: $(PKG_NAME)_$(PKG_VERS).tar.gz
R CMD check --as-cran $<
clean:
-rm $(PKG_NAME)_*.tar.gz
-rm -rf $(PKG_NAME).Rcheck
$(PKG_NAME)_$(PKG_VERS).tar.gz: DESCRIPTION
Rscript -e "Rcpp::compileAttributes()"
R CMD build ../OptimalDesign
vignettes: inst/doc/optimalDesign.pdf
inst/doc/optimalDesign.pdf: vignettes/optimalDesign.Rnw
Rscript -e "knitr::knit2pdf(\"vignettes/optimalDesign.Rnw\")"
mv vignettes/optimalDesign.pdf inst/doc/