[Rprotobuf-commits] r741 - in pkg: . inst/unitTests src
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Sat Jan 11 05:02:28 CET 2014
Author: jeroenooms
Date: 2014-01-11 05:02:26 +0100 (Sat, 11 Jan 2014)
New Revision: 741
Added:
pkg/configure.win
Modified:
pkg/inst/unitTests/runit.addressbook.R
pkg/src/Makevars.win
Log:
fixes for windows
Added: pkg/configure.win
===================================================================
Modified: pkg/inst/unitTests/runit.addressbook.R
===================================================================
--- pkg/inst/unitTests/runit.addressbook.R 2014-01-10 22:41:27 UTC (rev 740)
+++ pkg/inst/unitTests/runit.addressbook.R 2014-01-11 04:02:26 UTC (rev 741)
@@ -51,12 +51,15 @@
# (better than silently getting an empty proto.)
book4 <- checkException( readASCII( tutorial.AddressBook, file(out.file, "rt")))
- # Verify that we get an exception if the file is not readable.
- old.mode <- file.info(out.file)[["mode"]]
- Sys.chmod(out.file, "0000")
- book5 <- checkException( readASCII( tutorial.AddressBook, file(out.file, "rb")))
- # Set the permissions back to ensure the file is cleaned up properly.
- Sys.chmod(out.file, old.mode)
+ # Test does not work on windows because of chmod
+ if(!grepl("mingw", R.Version()$platform)){
+ # Verify that we get an exception if the file is not readable.
+ old.mode <- file.info(out.file)[["mode"]]
+ Sys.chmod(out.file, "0000")
+ book5 <- checkException( readASCII( tutorial.AddressBook, file(out.file, "rb")))
+ # Set the permissions back to ensure the file is cleaned up properly.
+ Sys.chmod(out.file, old.mode)
+ }
# Verify that we get an exception if the file is not parseable.
out.file2 <- tempfile()
Modified: pkg/src/Makevars.win
===================================================================
--- pkg/src/Makevars.win 2014-01-10 22:41:27 UTC (rev 740)
+++ pkg/src/Makevars.win 2014-01-11 04:02:26 UTC (rev 741)
@@ -1,13 +1,14 @@
# -*- mode: Makefile -*-
##
-## The folders C:/protobuf-2.5.0/lib/{i386,x64}/ contain static libraries for windows.
-## There is a problem with mingw64 and libprotobuf that results in ld reading symbols multiple times
-## We can workaround it using "-Wl,-allow-multiple-definition".
+## The folders ../protobuf-2.5.0/lib/{i386,x64}/ contain static
+libraries for windows.
+## mingw64-4.8.1 has an issue that results in ld reading symbols multiple times.
+## A workaround is to add "-Wl,-allow-multiple-definition" to RCPP_LDFLAGS.
## See also https://sourceware.org/bugzilla/show_bug.cgi?id=12762
+## However the problem did not appear for mingw 4.7.3.
##
-MINGW64HACK= "-Wl,-allow-multiple-definition"
-RCPP_LDFLAGS = $(shell "${R_HOME}/bin${R_ARCH_BIN}/Rscript.exe" -e "Rcpp:::LdFlags()") $(MINGW64HACK)
+## MINGW64HACK= "-Wl,-allow-multiple-definition"
+RCPP_LDFLAGS = $(shell "${R_HOME}/bin${R_ARCH_BIN}/Rscript.exe" -e "Rcpp:::LdFlags()")
PROTOBUFROOT= "../protobuf-2.5.0"
PKG_CPPFLAGS= -I$(PROTOBUFROOT)/src
PKG_LIBS=$(RCPP_LDFLAGS) -L$(PROTOBUFROOT)/lib${R_ARCH} -lprotobuf
-
More information about the Rprotobuf-commits
mailing list