Menu

#1606 "make info" fails

None
closed-fixed
None
2015-05-02
2015-04-28
No

For gnuplot5, the docs/Makefile.am file says that to generate the info file, one needs "make info". But I get the following error (under Debian):

/bin/bash /home/vlefevre/software/gnuplot5-5.0.0+dfsg1/missing makeinfo -I../../../docs ../../../docs/gnuplot.texi --no-split --output=gnuplot.info
could not open ../../../docs/gnuplot.texi: No such file or directory
Makefile:1095: recipe for target 'gnuplot.info' failed

The docs/README file says that gnuplot.info is generated from the gnuplot.doc file. So, there seems to be something incorrect in the rules.

Discussion

  • Vincent Lefevre

    Vincent Lefevre - 2015-04-28

    Indeed, the rule seems to take gnuplot.texi from the source directory instead of the build directory.

     
  • Ethan Merritt

    Ethan Merritt - 2015-04-28

    I think you may be mis-reading something.

    FYI to help figure out what might be going wrong,

    [406] make -n info
    echo "Creating texinfo and eldoc strings file"
    if test "emacs" != no; then \
       test ".." = ".." || cp ./gnuplot.doc . ; \
       emacs -batch -q --no-site-file -l ./doc2texi.el -f d2t-doc-to-texi ; \
       echo "Compiling gnuplot-eldoc.el" ; \
       emacs -batch -q --no-site-file -f batch-byte-compile gnuplot-eldoc.el ; \
       test ".." = ".." || rm -f ./gnuplot.doc ; \
    else \
       echo "No emacs found - cannot create texinfo file" ; \
    fi
    /bin/sh $HOME/gnuplot-cvs/missing makeinfo -I. ./gnuplot.texi --no-split --output=gnuplot.info
    

    Note that
    1) emacs is needed to convert gnuplot.doc to gnuplot.texi
    2) makeinfo is needed to convert gnuplot.texi to gnuplot.info

    I think the message you show is telling you that one or both of these tools is missing.

     
  • Vincent Lefevre

    Vincent Lefevre - 2015-04-28

    No, I have both of these tools (gnuplot.texi has successfully been created and I have makeinfo). And modifying the Makefile rule solves the problem:

    $(MAKEINFO) -I$(srcdir) $(srcdir)/gnuplot.texi --no-split --output=$@
    

    needs to be changed to:

    $(MAKEINFO) -I$(srcdir) gnuplot.texi --no-split --output=$@
    
     
    • Hans-Bernhard Broeker

      Modifying the rule that way solves this problem. Unfortunately it creates a new one. Now the info file is built, but the .texi file in the source tree fails to be updated.

       
  • Ethan Merritt

    Ethan Merritt - 2015-04-28

    Pretty sure that is not the underlying cause of your problem. For one thing the unmodified Makefile works fine for me, For another the $(srcdir) is not referring to ../src, it's referring to the location of your gnuplot source tree as opposed to your build tree. At least that's my understanding. This is what lets you custom build/install into a different directory than the source.

    So I'm glad you got it working for your machine, but I don't think that your modification is a correct fix for the upstream source. I think it's more likely that the definition of $srcdir itself got messed up somewhere.

     
    • Hans-Bernhard Broeker

      For one thing the unmodified Makefile works fine for me, For another the
      $(srcdir) is not referring to ../src, it's referring to the location of your
      gnuplot source tree as opposed to your build tree.

      Actually, neither. $(srcdir) is the location of no directory called 'src', nor of the source tree as such (that would be $(top_srcdir)). It's the location of the source tree's directory corresponding to the one make is currently being run in. E.g. if you build like I usually do (and Vincent, too):

      cd /some/where/gnuplot && mkdir build_sub && cd build_sub
      ../configure && make
      

      then seen from build_sub/docs, $(srcdir)==../../docs, which is equivalent to /some/where/gnuplot/docs.

       
  • Vincent Lefevre

    Vincent Lefevre - 2015-04-28

    This is working for you only because you use the same build dir as srcdir. Try to build in a different directory, and you'll see. Note that gnuplot.texi is generated, so that it must not be taken from $(srcdir) but from the build directory, which is the same as the current directory. Hence my suggested change (which I tested in the case of a build directory different from the source tree and which works here).

     
  • Ethan Merritt

    Ethan Merritt - 2015-04-29

    Both automake and texinfo are beyond my meager powers of understanding. While what you say is logical, note the following caveat in the automake documentation:

    "It is worth noting that, contrary to what happens with the other formats,
     the generated .info files are by default placed in srcdir rather than in
     the builddir. This can be changed with the info-in-builddir option."
    

    I'm currently fighting automake configuration on another front and losing badly. This one almost makes sense, by comparison.

     
  • Vincent Lefevre

    Vincent Lefevre - 2015-04-29

    The rule was already written by a gnuplot developer in docs/Makefile.am. You just need to change it as I've said above.

     
  • Vincent Lefevre

    Vincent Lefevre - 2015-04-29

    Currently on http://gnuplot.cvs.sourceforge.net/viewvc/gnuplot/gnuplot/docs/Makefile.am?view=markup it is line 337.

    Note: this will fix the build of the gnuplot.info file. I have not tried "make install" yet, but according to lines 339 and 341 (install-info rule), it seems to be OK since gnuplot.info is taken from the current directory.

     
  • Vincent Lefevre

    Vincent Lefevre - 2015-04-29

    Also, note the full rule about gnuplot.info currently in docs/Makefile.am:

    gnuplot.info: gnuplot.texi
            $(MAKEINFO) -I$(srcdir) $(srcdir)/gnuplot.texi --no-split --output=$@
    

    Having gnuplot.texi in the prerequisites and $(srcdir)/gnuplot.texi in the command is an obvious inconsistency. The gnuplot.texi is the correct one.

     
  • Hans-Bernhard Broeker

    • status: open --> closed-fixed
    • assigned_to: Hans-Bernhard Broeker
    • Group: -->
    • Priority: -->
     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.