Skip to content

Issues building from svn

3 messages · Dirk Eddelbuettel, Peter Dalgaard

#
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
#
This also breaks plain builds of r-devel. 

Subdir make is such a pain! Top level Makefile has

SUBDIRS = m4 tools doc etc share src tests
...
        @for d in $(SUBDIRS); do \
          (cd $${d} && $(MAKE) R) || exit 1; \
        done

so building something in doc that relies on something built in src ends badly. Preliminary fiddling indicates that it might work to move doc after src in SUBDIRS, but the reverse (src to before doc) did not. 

[snippage]
Er, a "not" went missing in there??

-p

  
    
#
On 20 July 2016 at 00:21, peter dalgaard wrote:
|
| > On 19 Jul 2016, at 22:05 , Dirk Eddelbuettel <edd at debian.org> wrote:
| > 
| > 
| > 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:
| 
| This also breaks plain builds of r-devel. 
| 
| Subdir make is such a pain! Top level Makefile has
| 
| SUBDIRS = m4 tools doc etc share src tests
| ...
|         @for d in $(SUBDIRS); do \
|           (cd $${d} && $(MAKE) R) || exit 1; \
|         done
| 
| so building something in doc that relies on something built in src ends badly. Preliminary fiddling indicates that it might work to move doc after src in SUBDIRS, but the reverse (src to before doc) did not. 

Per the (now deleted by you) diff, the NEWS.rds needs ../bin/R to be
processed which is constructed only via src/ but now needed in doc/. Bang.
 
| [snippage]
| 
| > 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
| > 
| 
| Er, a "not" went missing in there??

Certainly, thanks.  And fortunes::fortune(112) still holds.

Dirk