Why not change the test to verify if EXE and/or JSDIR exist at the location
rather than assume where they should be given the system type?

On Fri, Feb 17, 2012 at 3:50 AM, David Mitchell <davidmitch...@att.net>wrote:

> The locations in gnuplot.ijs are individually coded for 3 OS
> configurations:
>
> NB. set EXE   as path to gnuplot binary
> NB. set JSDIR as path to gnuplot javascript scripts
> NB. hardwired OS assumptions that may need tweaking
> 3 : 0''
> select. UNAME
> case. 'Win' do.
>  EXE  =: (jpath'~home/gnuplot/binary/gnuplot.exe')rplc'/';'\'
>  JSDIR=: '~home/gnuplot/binary/share/gnuplot/4.4/js/'
> case. 'Linux' do.
>  EXE  =: '/usr/bin/gnuplot'
>  JSDIR=: '~root/usr/share/gnuplot/gnuplot/4.4/js/'
> case. 'Darwin' do.
>  EXE  =: '/usr/local/bin/gnuplot'
>  JSDIR=: '~root/usr/local/share/gnuplot/4.4/js/'
> case. do. assert. 0['unknown UNAME'
> end.
>
> To me, it is a matter of personal taste if one decides to modify their
> system to
> match what the script expects or to modify gnuplot.ijs to match what is
> currently on your system.  There are several reasons I felt it is at least
> worth
> knowing about the path options in gnuplot.ijs.  One reason is that the
> install
> directory for gnuplot can be a personal choice and does not seem to be as
> standardized as some packages.  Another reason is that the path names
> include a
> version-specific element (/4.4/) that is likely to change depending on
> which
> version of gnuplot one decides to install.
>
> It is true that if you choose to update gnuplot.ijs, you will have to
> continue
> to manage that change when updates are made.
>
> On 2/17/2012 0:41, bill lam wrote:
> > I'm curious.  If the folders are symlinked, all files inside should
> > also be symlinked. eg, (untested)
> >
> > rm -rf /usr/local/share/gnuplot
> > ln -s /opt/local/share/gnuplot /usr/local/share/gnuplot
> >
> > not sure if mac need a sudo here.
> >
> > then confirm all files are available
> >
> > ls -R /usr/local/share/gnuplot
> >
> > Or Mac has some features in ln that I missed.
> >
> > Чтв, 16 Фев 2012, Murray Eisenberg писал(а):
> >> No, canvastext.js is not in /usr/local/share/gnuplot/4.4/js. Rather, on
> >> my Mac OS X 10.7 system, it's in /opt/local/share/gnuplot/4.4/js.
> >>
> >> So there seems to be the possibility of a whole cascading list of errors
> >> possible because J starts out thinking that the gnuplot files are in
> >> /usr/local/share/gnuplot/... whereas in fact they are in
> >> /opt/local/share/gnuplot.
> >>
> >> So what is a reasonable fix for this? Simply wht David Mitchell
> >> suggested in his follow-up response: to edit gnuplot.ijs?
> >>
> >> Was the location hard-coded into gnuplot.ijs designed for OS's other
> >> than Mac OS X? Or is there something weird about the location on my
> system?
> >>
> >> On 2/16/12 11:00 PM, general-requ...@jsoftware.com wrote:
> >>>
> >>> Message: 1
> >>> Date: Wed, 15 Feb 2012 23:38:59 -0500
> >>> From: Murray Eisenberg<mur...@math.umass.edu>
> >>> Subject: Re: [Jgeneral] General Digest, Vol 77, Issue 2
> >>> To: general@jsoftware.com
> >>> Message-ID:<4f3c8863.1010...@math.umass.edu>
> >>> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
> >>>
> >>> I created a symlink in /usr/local/bin for gnuplot to
> >>> /opt/local/bin/gnuplot. Now I don't get the same error as before when
> >>> loading ~addons/ide/jhs/gnuplot.ijs.
> >>>
> >>> But now I get the error:
> >>>
> >>>      /usr/local/share/gnuplot/4.4/js/canvastext.js not found
> >>>
> >>> I'm confused here, obviously.
> >>>
> >>> On 2/15/12 11:00 PM, general-requ...@jsoftware.com wrote:
> >>>> Date: Thu, 16 Feb 2012 10:18:02 +0800 From: bill lam
> >>>> <bbill....@gmail.com>   Subject: Re: [Jgeneral] gnuplot binary
> location on
> >>>> Mac OS X To: general@jsoftware.com Message-ID:
> >>>> <20120216021801.GC2804@debian.b2j>   Content-Type: text/plain;
> >>>> charset=utf-8
> >>>    >
> >>>> I assume you meant run gnuplot under JHS. JHS includes its
> >>>> own support for gnuplot, the file should be
> ~addons/ide/jhs/gnuplot.ijs
> >>>> Perhaps you want to symlink the path so that you will not need to edit
> >>>> again after the next jhs update.
> >>>    >
> >>>     ???, 15 ??? 2012, Murray Eisenberg wrote:
> >>>>
> >>>>>>    I'm trying to use the J gnuplot package under jhs on Mac OS X
> 10.7
> >>>>>>    (Lion). Trying to load the package gives error:
> >>>>>>
> >>>>>>       /usr/local/bin/gnuplot not found
> >>>>>>
> >>>>>>    In fact, that's not the path to a gnuplot binary. Using the OS X
> command
> >>>>>>    line, I found the binary:
> >>>>>>
> >>>>>>       /opt/local/bin/gnuplot
> >>>>>>
> >>>>>>    What ijs script needs to be edited to fix this? (I found no
> gnuplot file
> >>>>>>    in ~/addons/graphics, and jfif failed to find any file containing
> >>>>>>    'gnuplot'.)
> >>>
> >>
> >> --
> >> Murray Eisenberg                     mur...@math.umass.edu
> >> Mathematics&  Statistics Dept.
> >> Lederle Graduate Research Tower      phone 413 549-1020 (H)
> >> University of Massachusetts                413 545-2859 (W)
> >> 710 North Pleasant Street            fax   413 545-1801
> >> Amherst, MA 01003-9305
> >> ----------------------------------------------------------------------
> >> For information about J forums see http://www.jsoftware.com/forums.htm
> >
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to