Can't install Gnuplot 4.4.0

Discussion in 'Mac Programming' started by tirwit, Jul 17, 2010.

  1. tirwit macrumors newbie

    Joined:
    Jan 20, 2010
    #1
    Hi

    I need to install gnuplot. SO following the instructions, I do:

    Code:
    ./configure
    Then I do:

    Code:
    ./make
    And it shows me this:

    Code:
    make  all-recursive
    Making all in config
    make[2]: Nothing to be done for `all'.
    Making all in m4
    make[2]: Nothing to be done for `all'.
    Making all in term
    make[2]: Nothing to be done for `all'.
    Making all in src
    Making all in wxterminal
    make[3]: Nothing to be done for `all'.
    g++  -g -O2   -o gnuplot alloc.o axis.o binary.o breaders.o bitmap.o color.o command.o contour.o datafile.o dynarray.o eval.o fit.o gadgets.o getcolor.o graph3d.o graphics.o help.o hidden3d.o history.o internal.o interpol.o matrix.o misc.o mouse.o parse.o plot.o plot2d.o plot3d.o pm3d.o readline.o save.o scanner.o set.o show.o specfun.o standard.o stdfn.o tables.o tabulate.o term.o time.o unset.o util.o util3d.o variable.o version.o   -lreadline  -lncurses  -lz   
    Undefined symbols:
      "_rl_ding", referenced from:
          _alert in mouse.o
      "_rl_complete_with_tilde_expansion", referenced from:
          _main in plot.o
      "_history_list", referenced from:
          _write_history_list in history.o
         (maybe you meant: _write_history_list)
      "_rl_reset_after_signal", referenced from:
          _main in plot.o
    ld: symbol(s) not found
    collect2: ld returned 1 exit status
    make[3]: *** [gnuplot] Error 1
    make[2]: *** [all-recursive] Error 1
    make[1]: *** [all-recursive] Error 1
    make: *** [all] Error 2
    
    Any idea what's wrong?
     
  2. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #2
  3. misee macrumors member

    Joined:
    Jul 4, 2010
    #3
    It worked for me when I installed the GNU Readline library in /usr/local and then did ./configure --with-readline=/usr/local. You could also try the --with-readline=builtin option.

    Edit: as chown33 stated, google is a very good problem-solving strategy. When you get an unkown symbol error, most likely you don't have a required library. So you google for rl_complete_with_tilde_expansion, find that it belongs to the readline lib. Then you can either check the ./configure --help and see that there is a --with-readline=builtin option, or you can install and download the library (and use the --with-readline=<path_to_readline_installation>.
     
  4. tirwit thread starter macrumors newbie

    Joined:
    Jan 20, 2010
    #4
    I installed the readline-6.1, and it installed to /usr/local/lib. Is there a difference between being installed in /usr/local/lib or /usr/local/lib?

    EDIT: My /usr/local/lib, looks like this:


    MacBook-de-Pedro-Gordo:lib Pedro_Gordo$ ls
    gcc libgomp.la
    i386 libgomp.spec
    libfrtbegin.a libhistory.6.1.dylib
    libg2c.0.0.0.dylib libhistory.6.1.dylib.old
    libg2c.0.dylib libhistory.6.dylib
    libg2c.a libhistory.a
    libg2c.dylib libhistory.dylib
    libg2c.la libhistory.old
    libgcc_ext.10.4.dylib libiberty.a
    libgcc_ext.10.5.dylib libmpc.a
    libgcc_s.1.dylib libmpc.la
    libgcc_s.10.4.dylib libmpfr.a
    libgcc_s.10.5.dylib libmpfr.la
    libgcc_s_ppc64.1.dylib libreadline.6.1.dylib
    libgcc_s_x86_64.1.dylib libreadline.6.dylib
    libgfortran.3.dylib libreadline.a
    libgfortran.a libreadline.dylib
    libgfortran.dylib libssp.0.dylib
    libgfortran.la libssp.a
    libgmp.a libssp.dylib
    libgmp.la libssp.la
    libgomp.1.dylib libssp_nonshared.a
    libgomp.a libssp_nonshared.la
    libgomp.dylib x86_64
     
  5. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #5
    If you mean "difference between /usr/lib and /usr/local/lib", the difference is that Apple updates (OS or other Software Update products) can replace things in /usr/lib, but will not do anything to /usr/local/lib. This is essentially the standard behavior:
    http://en.wikipedia.org/wiki/Unix_directory_structure

    Of course, this means you are responsible for performing all maintenance updates, compatibility checking, etc. in /usr/local/**.
     
  6. misee macrumors member

    Joined:
    Jul 4, 2010
    #6
    I think you would have to do this anyway, since apple usually won't update packages that you installed yourself (correct me if I'm wrong). Also, I can see at first glance which software I am responsible for.

    By the way, if you compile an application that uses the GNU autotools (./configure, make, make install) it's default installation directory will be /usr/local (type ./configure --help for details). Also, readline isn't only installed in the /usr/local/lib, but there are also header files installed in /usr/local/include, so make sure you pass /usr/local to the gnuplot configure script and not /usr/local/lib
     
  7. tirwit thread starter macrumors newbie

    Joined:
    Jan 20, 2010
    #7
    Problem solved!!! Thank you so much! God bless you all! :D
     

Share This Page