From 70e16d8ca726ed9d894bd219018838ce4b0f22a0 Mon Sep 17 00:00:00 2001 From: Johannes Ranke Date: Thu, 13 Oct 2016 20:13:27 +0200 Subject: chents for windows! --- GNUmakefile | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) (limited to 'GNUmakefile') diff --git a/GNUmakefile b/GNUmakefile index 3051dfb..dfea847 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -2,13 +2,12 @@ PKGSRC := $(shell basename $(CURDIR)) PKGNAME := $(shell sed -n "s/Package: *\([^ ]*\)/\1/p" DESCRIPTION) PKGVERS := $(shell sed -n "s/Version: *\([^ ]*\)/\1/p" DESCRIPTION) TGZ := $(PKGNAME)_$(PKGVERS).tar.gz +WINBIN := $(PKGNAME)_$(PKGVERS).zip R_HOME ?= $(shell R RHOME) DATE := $(shell date +%Y-%m-%d) all: install -.PHONEY: usage check clean roxygen sd - pkgfiles = DESCRIPTION \ README.html \ R/* \ @@ -19,7 +18,7 @@ pkgfiles = DESCRIPTION \ roxygen: @echo "Roxygenizing package..." - "$(R_HOME)/bin/Rscript" -e 'library(devtools); document(".")' + "$(R_HOME)/bin/Rscript" -e 'library(devtools); document()' @echo "DONE." sd: roxygen @@ -30,7 +29,7 @@ sd: roxygen $(TGZ): $(pkgfiles) sed -i -e "s/Date:.*/Date: $(DATE)/" DESCRIPTION @echo "Roxygenizing package..." - "$(R_HOME)/bin/Rscript" -e 'library(devtools); document(".")' + "$(R_HOME)/bin/Rscript" -e 'library(devtools); document()' @echo "Building package..." git log --no-merges -M --date=iso > ChangeLog "$(R_HOME)/bin/R" CMD build . @@ -41,9 +40,16 @@ README.html: README.md build: $(TGZ) +$(WINBIN): build + @echo "Building windows binary package..." + "$(R_HOME)/bin/R" CMD INSTALL $(TGZ) --build + @echo "DONE." + +winbin: $(WINBIN) + test: build @echo "Running testthat tests..." - "$(R_HOME)/bin/Rscript" -e 'library(devtools); devtools::test(".")' 2>&1 | tee test.log + "$(R_HOME)/bin/Rscript" -e 'library(devtools); devtools::test()' 2>&1 | tee test.log @echo "DONE." quickcheck: build @@ -64,6 +70,9 @@ install: build drat: build "$(R_HOME)/bin/Rscript" -e "drat::insertPackage('$(TGZ)', commit = TRUE)" +dratwin: winbin + "$(R_HOME)/bin/Rscript" -e "drat::insertPackage('$(WINBIN)', 'e:/git/drat/', commit = TRUE)" + winbuilder: build date @echo "Uploading to R-release on win-builder" -- cgit v1.2.1