[Rd] R CMD build with mingw and msys (PR#9766)

From: <sneumann_at_pubhealth.ku.dk>
Date: Fri, 29 Jun 2007 13:53:33 +0200 (CEST)


Full_Name: Steffen
Version: 2-5-0
OS: Windows
Submission from: (NULL) (192.124.243.162)

Hi,

the R CMD build script is using

    if($WINDOWS) {

        ## workaround for paths in Cygwin tar
        $filepath =~ s+^([A-Za-z]):+/cygdrive/\1+;
    }

which does not work if the build environment is a MINGW. I have added the patch below,

Yours,
Steffen

$ diff -u build build.orig
--- build Fri Jun 29 13:50:16 2007 +++ build.orig Fri Jun 29 08:51:48 2007
@@ -47,7 +47,6 @@

 R::Vars::error("R_HOME", "R_EXE");  

 my $WINDOWS = ($R::Vars::OSTYPE eq "windows"); -my $MSYS = ( $ENV{OSTYPE} eq "msys" );  

 my @exclude_patterns = R::Utils::get_exclude_patterns();  

@@ -222,14 +221,10 @@

     my $filepath = &file_path($startdir, $filename);
     ## under Windows, need separate Cygwin and Windows versions of path.
     my $origfilepath = $filepath;
-    if ($MSYS) {
-               ## different workwaround for MSYS
-               $filepath =~ s+^([A-Za-z]):+/\1/+;
-    } elsif ($WINDOWS) {
-               ## workaround for paths in Cygwin tar
-               $filepath =~ s+^([A-Za-z]):+/cygdrive/\1+;
+    if($WINDOWS) {
+       ## workaround for paths in Cygwin tar
+       $filepath =~ s+^([A-Za-z]):+/cygdrive/\1+;
     }
-       
     R_system(join(" ",
                  ("$tar chf",
                   &shell_quote_file_path($filepath),

______________________________________________
R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Fri 29 Jun 2007 - 15:32:00 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Mon 02 Jul 2007 - 22:35:53 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-devel. Please read the posting guide before posting to the list.