[r-base] 01/01: Fix 2 of the FTBFS, the other one is not our problem

Ximin Luo infinity0 at debian.org
Tue May 2 17:33:19 UTC 2017


This is an automated email from the git hooks/post-receive script.

infinity0 pushed a commit to branch pu/reproducible-builds
in repository r-base.

commit ab10745cf06145ba1fd71b5d7fcecfa8f132e004
Author: Ximin Luo <infinity0 at debian.org>
Date:   Tue May 2 19:32:59 2017 +0200

    Fix 2 of the FTBFS, the other one is not our problem
---
 debian/changelog               |  4 ++--
 src/library/base/R/namespace.R | 12 +++++++++---
 2 files changed, 11 insertions(+), 5 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 7d3599b..5a39799 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,9 +1,9 @@
-r-base (3.4.0-1.0~reproducible1) UNRELEASED; urgency=medium
+r-base (3.4.0-1.0~reproducible2) UNRELEASED; urgency=medium
 
   * Non-maintainer upload.
   * Generate output reproducibly, independently of the build path.
 
- -- Ximin Luo <infinity0 at debian.org>  Thu, 20 Apr 2017 22:13:43 +0200
+ -- Ximin Luo <infinity0 at debian.org>  Tue, 02 May 2017 18:40:55 +0200
 
 r-base (3.4.0-1) unstable; urgency=medium
 
diff --git a/src/library/base/R/namespace.R b/src/library/base/R/namespace.R
index e82c612..b55358f 100644
--- a/src/library/base/R/namespace.R
+++ b/src/library/base/R/namespace.R
@@ -249,9 +249,9 @@ loadNamespace <- function (package, lib.loc = NULL,
             attr(dimpenv, "name") <- paste0("lazydata:", name)
             setNamespaceInfo(env, "lazydata", dimpenv)
             setNamespaceInfo(env, "imports", list("base" = TRUE))
-            path <- if (relpath) file.path(".", name)
-            else normalizePath(file.path(lib, name), "/", TRUE)
-            setNamespaceInfo(env, "path", path)
+            ## this should be an absolute path
+            setNamespaceInfo(env, "path",
+                             normalizePath(file.path(lib, name), "/", TRUE))
             setNamespaceInfo(env, "dynlibs", NULL)
             setNamespaceInfo(env, "S3methods", matrix(NA_character_, 0L, 3L))
             env$.__S3MethodsTable__. <-
@@ -507,6 +507,12 @@ loadNamespace <- function (package, lib.loc = NULL,
         # else warning(gettextf("package %s contains no R code",
         #                        sQuote(package)), call. = FALSE, domain = NA)
 
+        # if relpath is asked for, set this here. we do this *after* the
+        # sys.source() step just above, because some packages' top-level code
+        # like to call things like packageDescription() which requires an
+        # actually-existing path info for them to work.
+        if (relpath) setNamespaceInfo(ns, "path", file.path(".", package))
+
         ## partial loading stops at this point
         ## -- used in preparing for lazy-loading
         if (partial) return(ns)

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/r-base.git



More information about the Reproducible-commits mailing list