From edd at debian.org  Tue Jul 19 22:05:58 2016
From: edd at debian.org (Dirk Eddelbuettel)
Date: Tue, 19 Jul 2016 15:05:58 -0500
Subject: [Rd] Issues building from svn
Message-ID: <22414.34854.561908.558020@max.nulle.part>


On a fresh svn checkout in a fresh directory, following up on 'configure'
(with many options, pointer to exact invocation below) by 'make' ends in
tears:

root at 09c079b7388b:/tmp/R-devel# make
make[1]: Entering directory '/tmp/R-devel/doc/manual'
creating RESOURCES
creating FAQ
creating doc/html/resources.html
make[1]: Leaving directory '/tmp/R-devel/doc/manual'
make[1]: Entering directory '/tmp/R-devel/m4'
make[1]: Nothing to be done for 'R'.
make[1]: Leaving directory '/tmp/R-devel/m4'
make[1]: Entering directory '/tmp/R-devel/tools'
make[1]: Nothing to be done for 'R'.
make[1]: Leaving directory '/tmp/R-devel/tools'
make[1]: Entering directory '/tmp/R-devel/doc'
/bin/bash: line 2: ../bin/R: No such file or directory
Makefile:48: recipe for target 'NEWS.rds' failed
make[1]: *** [NEWS.rds] Error 127
make[1]: Leaving directory '/tmp/R-devel/doc'
Makefile:60: recipe for target 'R' failed
make: *** [R] Error 1
root at 09c079b7388b:/tmp/R-devel#

Somehow ../bin/R is not made, but needed by doc/Makefile.  Running 'cd src;
make' builds R.

The exact details are in this file:
  https://github.com/rocker-org/rocker/blob/master/r-devel/Dockerfile
Some of the standard build commands are prefixed by Docker commands such as
RUN which you can ignore.  It also fails when I run the same commands
manually.  Needless to say, this used to work just fine.

Re-running 'make' then works.  When I tried to code this up, it fell over for
lack a SVN stamp ...

Looking at the svn log the likely culprit may be this as it is most recent, I
am however not sure why NEWS.rds would get in the way.

root at 09c079b7388b:/tmp/R-devel/doc# svn di -r68786 Makefile.in
Index: Makefile.in
===================================================================
--- Makefile.in (revision 68786)
+++ Makefile.in (working copy)
@@ -28,7 +28,7 @@
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
        @cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@

-R: Makefile svnonly
+R: Makefile svnonly NEWS.rds
        @for d in $(SUBDIRS); do \
          (cd $${d} && $(MAKE) $@) || exit 1; \
        done
root at 09c079b7388b:/tmp/R-devel/doc# 

The problem does manifest itself when the svn directory is not 'fresh' as in
the case of the Docker builds as ../bin/R exists from the previous builds.

Dirk

-- 
http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org



[Rd] Issues building from svn
Dirk Eddelbuettel