[tex-live] ConTeXt: Ruby 1.9 deprecation warnings
mojca.miklavec.lists at gmail.com
Wed Jan 9 19:18:28 CET 2013
On Wed, Jan 9, 2013 at 3:30 PM, Ken Brown wrote:
> Using ConTeXt with Ruby 1.9 produces warnings like the following:
> $ texexec --version
> Use RbConfig instead of obsolete and deprecated Config.
> The attached patch, to be applied in
> trunk/Master/texmf-dist/scripts/context, silences the warnings without
> destroying compatibility with (at least) later versions of Ruby 1.8.
> I don't know if TeX Live wants to support older versions of Ruby. If so,
> you'd need a more complicated patch.
thank you very much for suggesting the patch. Do you happen to know if
my assumption that this would break on ruby 1.8.4 or older is correct?
If ConTeXt is semi-broken with ruby 1.9 that's definitely not
desirable, so I would vote *for* the patch and I can volunteer to
apply the patch to TeX Live's SVN (= backport the patch; for newer
versions Hans will apply the patch anyway, but those versions won't
end up in TL 2012), but it would also be nice to document the
consequences at least (the minimum ruby version that's required and
possibly check which OS is too old to support this construct). In
principle it's not that bad if ConTeXt depends on relatively recent
software (it would be worse if that was required for LaTeX). Apart
from that ConTeXt MKII which requires ruby is slowly becoming
deprecated anyway ;)
I've found this link:
> My friend James Turnbull came up with this little gem the other day:
> CONFIG = Object.const_get(defined?(RbConfig) ? :RbConfig : :Config)::CONFIG
> The idea being that since Config is now deprecated in Ruby 1.9.3 and yet RbConfig is not available pre-1.8.5. This work-around covers both angels.
So one can either borrow the hack from that website or simply
deprecate usage of ruby older than 1.8.5 (if the information above is
correct). The version 1.8.5 has been released in 2006, so probably
that's old enough to drop support for older versions?
More information about the tex-live