[Soiltexture-commits] r40 - /

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Mon Sep 13 14:05:38 CEST 2010


Author: jmoeys
Date: 2010-09-13 14:05:37 +0200 (Mon, 13 Sep 2010)
New Revision: 40

Added:
   rcmdwrapper_1.1.zip
Modified:
   R_CMD_wrapper.R
Log:
change the script for testing compilation

Modified: R_CMD_wrapper.R
===================================================================
--- R_CMD_wrapper.R	2010-08-31 12:09:17 UTC (rev 39)
+++ R_CMD_wrapper.R	2010-09-13 12:05:37 UTC (rev 40)
@@ -224,26 +224,33 @@
 
 
 
-pkg.build.wrapper <- function 
+pkg.build.wrapper <- function( 
 ### A wrapper function for R CMD build, for building a package 
 ### from sources
-(   #
- pkg.name, 
+
+ pkg.name,
 ### Name of the package, and of the package directory
- pkg.dir, 
+
+ pkg.dir,
 ### Name of the directory in which the package directory is
 ### located 
- r.cmd= "R CMD build", 
+
+ r.cmd="R CMD build",
 ### Command send to windows shell. Default is "R CMD build" 
- bat.suffix="RCMDbuild"
+
+ bat.suffix="RCMDbuild",
 ### Suffix of the batch (.bat) file create for this operation, 
 ### without extension
+
+ r.cmd.op=""
+### Options to be passed after r.cmd, like "--no-tests" 
+
 ){  #
     cmd.build <- c( 
         "c:", 
         "cd \\", 
-        paste( sep = "", "cd ", normalizePath( file.path( pkg.dir ) )), 
-        paste( sep = "", r.cmd, " ", pkg.name )  
+        paste( sep = "", "cd \"", normalizePath( file.path( pkg.dir ) ), "\"" ), 
+        paste( sep = "", r.cmd, " ", r.cmd.op, " ", pkg.name )  
     )   #
     #
     cat( cmd.build ) 
@@ -263,6 +270,8 @@
         sep  = "\n"  
     )   #
     #
+    # print( as.character( bat.build ) )
+    #
     sys.res <- system( 
         command     = bat.build,  #
         intern      = TRUE, 
@@ -296,7 +305,7 @@
     cmd.install <- c( 
         "c:", 
         "cd \\", 
-        paste( sep = "", "cd ", normalizePath( file.path( pkg.dir ) )), 
+        paste( sep = "", "cd \"", normalizePath( file.path( pkg.dir ) ), "\"" ), 
         paste( sep = "", r.cmd, " ", pkg.name )  
     )   #
     #
@@ -355,7 +364,7 @@
     cmd.checks <- c( 
         "c:", 
         "cd \\", 
-        paste( sep = "", "cd ", normalizePath( file.path( pkg.dir ) )), 
+        paste( sep = "", "cd \"", normalizePath( file.path( pkg.dir ) ), "\"" ), 
         paste( sep = "", r.cmd, " ", r.cmd.op," ", pkg.name )  
     )   #
     #

Added: rcmdwrapper_1.1.zip
===================================================================
(Binary files differ)


Property changes on: rcmdwrapper_1.1.zip
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream



More information about the Soiltexture-commits mailing list