gnuplot Mac pkg

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

gnuplot Mac pkg

Allin Cottrell
Thanks to those who tested the package I mentioned in
https://sourceforge.net/p/gnuplot/mailman/message/34907517/

I've put up a revised version at the same place,
http://ricardo.ecn.wfu.edu/pub/gretl/gnuplot-quartz.pkg

In this version I have removed from the Distribution XML file the line

<options hostArchitectures="x86_64"/>

which is apparently more restrictive than I thought. This package just
needs a 64-bit userspace, but including that line prevents
installation on systems, such as OS X 10.6, that are not "fully
64-bit" (10.6 has a 32-bit kernel). I think that should quell the
"Cannot be installed" message.

I've also found and deleted a few more libraries that are required by
gretl but not needed for gnuplot, so the package is a little slimmer.

A couple of comments on things I didn't include in the package:

* The libgd-based png terminal. I don't see much point in that one if
you have pngcairo (unless perhaps, as Ethan has pointed out, you want
to make animated GIFs). Also, including libgd will drag in a
fontconfig dependency which is not otherwise needed. (Pango doesn't
need fontconfig on OS X, it's better off using Apple's CoreText.)

* X11. Given the wxt terminal, IMO the X11 terminal doesn't add value.
I guess I might have included it if Apple still included an X server
with OS X by default, but making XQuartz a prerequisite for a gnuplot
package seems unnecessary.

--
Allin Cottrell
Department of Economics
Wake Forest University, NC


------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://makebettercode.com/inteldaal-eval
_______________________________________________
gnuplot-beta mailing list
[hidden email]
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-beta
Reply | Threaded
Open this post in threaded view
|

Re: gnuplot Mac pkg

Jun T.

On 2016/03/08, at 1:37, Allin Cottrell <[hidden email]> wrote:
> I've put up a revised version at the same place,
> http://ricardo.ecn.wfu.edu/pub/gretl/gnuplot-quartz.pkg


After install, I've 'sudo mv'ed the Gnuplot.app to places other
than /Applications/, and it seems it still works fine.

Since the startup script properly sets the environment variables,
the help file gnuplot.gih and the prologue files for postscript
terminal are correctly found even if I move the Gnuplot.app. Great!

Isn't it possible to make a dmg from which users can drag and drop
Gnuplot.app to anywhere they want?


One minor problem. If I run
gnuplot> help
and type 'q', then 'Help topics available:' is shown, but
it does not include 'terminal'. I don't now why. But
gnuplot> help terminal
still works. But in 'Subtopics available for terminal:', 'aqua'
is missing but 'x11' exists. And
gnuplot>help aqua
does not work.

Maybe a slightly old version of gnuplot.gih is included?

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
_______________________________________________
gnuplot-beta mailing list
[hidden email]
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-beta
Reply | Threaded
Open this post in threaded view
|

Re: gnuplot Mac pkg

Allin Cottrell
On Wed, 9 Mar 2016, Jun T. wrote:

> On 2016/03/08, at 1:37, Allin Cottrell <[hidden email]> wrote:
>> I've put up a revised version at the same place,
>> http://ricardo.ecn.wfu.edu/pub/gretl/gnuplot-quartz.pkg
>
> After install, I've 'sudo mv'ed the Gnuplot.app to places other
> than /Applications/, and it seems it still works fine.
>
> Since the startup script properly sets the environment variables,
> the help file gnuplot.gih and the prologue files for postscript
> terminal are correctly found even if I move the Gnuplot.app. Great!
>
> Isn't it possible to make a dmg from which users can drag and drop
> Gnuplot.app to anywhere they want?

Yes, it's possible. On recent OS X this is kind of an "expert" option,
since it may be non-obvious what double-clicking on a DMG file does
(it'll get mounted, but likely hidden at the bottom of the finder
window, so it can look as if "nothing happened"). However, I've now
added a dmg file at

http://ricardo.ecn.wfu.edu/pub/gnuplot/

(where the packaged gnuplot version is now 5.0.3).

> One minor problem. If I run
> gnuplot> help
> and type 'q', then 'Help topics available:' is shown, but
> it does not include 'terminal'. I don't now why. But
> gnuplot> help terminal
> still works. But in 'Subtopics available for terminal:', 'aqua'
> is missing but 'x11' exists.

Oops, yes, I included the wrong gih file. That's now fixed in

http://ricardo.ecn.wfu.edu/pub/gnuplot/gnuplot-5.0.3-quartz.pkg
http://ricardo.ecn.wfu.edu/pub/gnuplot/gnuplot-5.0.3-quartz.dmg

Allin Cottrell

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
_______________________________________________
gnuplot-beta mailing list
[hidden email]
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-beta
Reply | Threaded
Open this post in threaded view
|

Re: gnuplot Mac pkg

Jun T.

2016/03/10 02:05, Allin Cottrell <[hidden email]> wrote:
>
> http://ricardo.ecn.wfu.edu/pub/gnuplot/gnuplot-5.0.3-quartz.pkg
> http://ricardo.ecn.wfu.edu/pub/gnuplot/gnuplot-5.0.3-quartz.dmg

Thanks. From the mounted dmg, I can install Gnuplot.app to anywhere,
for example to my Desktop. If a user has no admin privilege then
she/he can't install into /Applications.

> On recent OS X this is kind of an "expert" option, since it may be
> non-obvious what double-clicking on a DMG file does (it'll get mounted,
> but likely hidden at the bottom of the finder window, so it can look as
> if "nothing happened").

Usually, when I double click on a dmg file, it is mounted, and its
window is opened as a frontmost window, i.e., not covered by any other
windows (at least on OS X 10.9.5). What do you mean by 'recent OS X'?

But yes, if I double click on the gnuplot dmg, it is mounted but no
window opens. I don't know why.
Another problem is the dmg is writable.

How did you make the dmg file? Did you try DiskUtility.app? It can
make a read-only (and compressed) dmg file.

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
_______________________________________________
gnuplot-beta mailing list
[hidden email]
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-beta
Reply | Threaded
Open this post in threaded view
|

Re: gnuplot Mac pkg

Allin Cottrell
On Fri, 11 Mar 2016, Jun T. wrote:

>
> 2016/03/10 02:05, Allin Cottrell <[hidden email]> wrote:
>>
>> http://ricardo.ecn.wfu.edu/pub/gnuplot/gnuplot-5.0.3-quartz.pkg
>> http://ricardo.ecn.wfu.edu/pub/gnuplot/gnuplot-5.0.3-quartz.dmg
>
> Thanks. From the mounted dmg, I can install Gnuplot.app to anywhere,
> for example to my Desktop. If a user has no admin privilege then
> she/he can't install into /Applications.
>
>> On recent OS X this is kind of an "expert" option, since it may be
>> non-obvious what double-clicking on a DMG file does (it'll get mounted,
>> but likely hidden at the bottom of the finder window, so it can look as
>> if "nothing happened").
>
> Usually, when I double click on a dmg file, it is mounted, and its
> window is opened as a frontmost window, i.e., not covered by any other
> windows (at least on OS X 10.9.5). What do you mean by 'recent OS X'?

I'm not a Mac user myself, but... it seems to me that back on OS X
10.6 my dmg files would open as expected, while from Lion onwards
when I observed my students trying to install software from dmg
files they would end up mounted "invisibly". This may have to do
with settings that I don't understand.

> But yes, if I double click on the gnuplot dmg, it is mounted but no
> window opens. I don't know why.
> Another problem is the dmg is writable.
>
> How did you make the dmg file? Did you try DiskUtility.app? It can
> make a read-only (and compressed) dmg file.

No, I'm not using DiskUtility, I'm doing everything on Linux; that's
my working environment. (I have occasional access to a Mac for
testing.) But I think I've found a way of creating a more
"idiomatic" DMG. There's now an updated build at

http://ricardo.ecn.wfu.edu/pub/gnuplot/gnuplot-5.0.3-quartz.dmg

Allin Cottrell

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
_______________________________________________
gnuplot-beta mailing list
[hidden email]
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-beta
Reply | Threaded
Open this post in threaded view
|

Relative executable path. Was Re: gnuplot Mac pkg

Nicolas Brouard INED

Le 10 mars 2016 à 23:21, Allin Cottrell <[hidden email]> a écrit :

I looked at your dmg above and everything seems working but the hard link to gnuplot.gih could be replaced with its “standard" location -DHELPFILE=\"/usr/local/share/gnuplot/5.0/gnuplot.gih\" instead of yours at build time:
gnuplot> help set ter
/home/cottrell/stats/q2/Gretl.app/Contents/Resources/share/gnuplot/5.0/gnuplot.gih: No such file or directory
Then anyone could avoid the use of your script “gnuplot.sh" with the environments GNUHELP,GNUPLOT_PS_DIR. And at installation time the .dmg could move this important file to /usr/locall/share/gnuplot/5.0/. I agree that it is not completely the spirit of OS/X and Apps.

But it seems that the following command to get the correct relative path to binary doesn’t go into error but does a simple ‘touch’ without any warinng!
install_name_tool -change /usr/local/share/gnuplot/5.0/gnuplot.gih @executable_path/../share/gnuplot.gih bin/gnuplot

@executable_path works only (yet?) for objects.

On Linux we could use readlink("/proc/self/exe", buf, bufsize) or argv[0] to get the binary location, but on OS/X I don’t know.

After the error No such file or directory, does gnuplot search for any other location? On OS/X we could try the path given by -DHELPFILE=\”$BINDIR/../share/gnuplot/5.0/gnuplot.gih\” before displaying the error but BINDIR should not be hardcoded but equivalent to @executable_path, that is dependent on where the binary is installed and executed. I even don’t know if it exists on Linux. 

But the success of OS/X resides in the fact any App is using its own dated libraries (under the lib, share etc subdirectories) giving to the application a longer life expectancy. The time where disk space was a problem is over today. Thus we can have many different versions of a library on our hard disk. What  the user is expecting is a working App. Moving the App to the bin if it is too old.


--
Nicolas


Allin Cottrell

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
_______________________________________________
gnuplot-beta mailing list
[hidden email]
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-beta


------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
_______________________________________________
gnuplot-beta mailing list
[hidden email]
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-beta
Reply | Threaded
Open this post in threaded view
|

Re: Relative executable path. Was Re: gnuplot Mac pkg

Allin Cottrell
On Fri, 11 Mar 2016, Nicolas Brouard (INED) wrote:

>
>> Le 10 mars 2016 à 23:21, Allin Cottrell <[hidden email]> a écrit :
>> There's now an updated build at
>>
>> http://ricardo.ecn.wfu.edu/pub/gnuplot/gnuplot-5.0.3-quartz.dmg <http://ricardo.ecn.wfu.edu/pub/gnuplot/gnuplot-5.0.3-quartz.dmg>
>
> I looked at your dmg above and everything seems working but the
> hard link to gnuplot.gih could be replaced with its “standard"
> location -DHELPFILE=\"/usr/local/share/gnuplot/5.0/gnuplot.gih\"
> instead of yours at build time:
>
> gnuplot> help set ter
>
> /home/cottrell/stats/q2/Gretl.app/Contents/Resources/share/gnuplot/5.0/gnuplot.gih: No such file or directory
>
> Then anyone could avoid the use of your script “gnuplot.sh" with
> the environments GNUHELP,GNUPLOT_PS_DIR. And at installation time
> the .dmg could move this important file to
> /usr/locall/share/gnuplot/5.0/. I agree that it is not completely
> the spirit of OS/X and Apps.
I think that if I were going to insert a more helpful default path
for gnuplot.gih at build time (not a bad idea) it would be better to
make it the canonical path for a Mac-type installation, namely under

/Applications/Gnuplot.app/Contents/Resources/share

>
> But it seems that the following command to get the correct relative path to binary doesn’t go into error but does a simple ‘touch’ without any warinng!
> $ install_name_tool -change /usr/local/share/gnuplot/5.0/gnuplot.gih @executable_path/../share/gnuplot.gih bin/gnuplot
>
> @executable_path works only (yet?) for objects.

Yes. I don't expect that's going to change.

Allin Cottrell

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
_______________________________________________
gnuplot-beta mailing list
[hidden email]
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-beta
Reply | Threaded
Open this post in threaded view
|

Re: Relative executable path. Was Re: gnuplot Mac pkg

Allin Cottrell
On Fri, 11 Mar 2016, Allin Cottrell wrote:

> I think that if I were going to insert a more helpful default path for
> gnuplot.gih at build time (not a bad idea) it would be better to make it the
> canonical path for a Mac-type installation, namely under
>
> /Applications/Gnuplot.app/Contents/Resources/share

Actually, that's such an obvious improvement that I've now rebuilt
my pkg and dmg with PREFIX set to

/Applications/Gnuplot.app/Contents/Resources

I think this means that if you install in the standard location you
should be able to run gnuplot from the shell just my making a
suitable symlink to the gnuplot binary at

/Applications/Gnuplot.app/Contents/Resources/bin/gnuplot

If you install elsewhere it'll still be necessary to use my wrapper
script to get the envionment right.

Allin Cottrell

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
_______________________________________________
gnuplot-beta mailing list
[hidden email]
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-beta