[OpenIndiana-discuss] [HEADS UP] Ruby 1.9 is obsolete
Tim Mooney
Tim.Mooney at ndsu.edu
Fri Dec 2 19:39:10 UTC 2016
In regard to: Re: [OpenIndiana-discuss] [HEADS UP] Ruby 1.9 is obsolete,...:
>> When there's a language (like, ruby, perl, python, etc.) where OI includes
>> multiple versions, is there any "supported" method for a system
>> administrator to choose which version is the default, similar to the
>> alternatives(8) system on Debian-derived and RHEL-derived Linux systems?
>
> There are pkg mediators. See
> https://docs.oracle.com/cd/E26502_01/html/E28984/gmagn.html or pkg(5).
> However, when packaging software, I prefer OI-shipped software to use fixed
> interpreter version,
> except trivial cases. So, setting mediator will influence user software,
> but ideally shouldn't break system software.
That's more-or-less the same practice that some of the Linux distros
I'm familiar with use. At least on RHEL-derived systems, if a particular
packaged script requires e.g. python 2.7 rather than python 3.3, then it
probably uses
#! /usr/bin/python2.7
as the sh-bang line, and the package will specifically require
that the 'python-2.7' package is installed. That way, even if
/etc/alternatives has been set so that /usr/bin/python points to
python 3.3, the script still gets the version of python that it needs.
Even that level of configurability makes distro packaging more complex,
though.
Thanks to you and Andreas for the heads-up about mediators. I had seen
package mediators mentioned before on the list, but the concept is
esoteric enough that I hadn't connected it to potentially being useful
for an alternatives-like system.
Tim
--
Tim Mooney Tim.Mooney at ndsu.edu
Enterprise Computing & Infrastructure 701-231-1076 (Voice)
Room 242-J6, Quentin Burdick Building 701-231-8541 (Fax)
North Dakota State University, Fargo, ND 58105-5164
More information about the openindiana-discuss
mailing list