Closed MatzFan closed 3 months ago
Hi, the aim of this project is to be a lightweight wrapper around downloading a Ruby source code tarball, running ./configure
, running make
, and finally make install
. We try to not deviate from defaults in this process, including setting configuration flags, unless there is a strong reason to do so.
(Note that we do not provide "pre-built" rubies, but compile a Ruby version every time ruby-build
gets invoked.)
The only non-default configure flag we currently set is --enable-shared
https://github.com/rbenv/ruby-build/issues/35. This is to help install some gems that need ruby to have a shared library. This was requested by multiple people after some frustration.
However, I haven't heard of --enable-socks
being a highly used or even requested feature. I'm not sure why this Ruby core feature is off by default, but I do not find sufficient evidence that this is a flag that we should turn on by default in ruby-build. That is why I'm deciding that this is a #wontfix. Thank you for explaining your perspective, though. We can refer to this thread if the issue of SOCKS comes up again.
Note that ruby-build users can opt into having SOCKS enabled in their ruby by doing ruby-build <version> /path/to/ruby -- --enable-socks=true
explicitly.
Understood @mislav, quite understand your rationale.
I'm not sure why this Ruby core feature is off by default
Indeed. My next stop is an enhancement suggestion to Ruby-Talk. Thanks for your time.
@mislav FYI my request was accepted and Ruby master now enables the SOCKS flag by default. AFAIK CI build envs like ubuntu-latest
don't have any socks libs installed, but at least users installing one of your builds who do will get Ruby's native SOCKS functionality in the future.
I'm the current maintainer of the
socksify
Ruby gem. This gem was originally created to permit users of rubies to make SOCKS connections vianet/http
and other libraries. The gem patches the private methodNet::HTTP#connect
which of course is highly undesirable, as it is subject to change with each new Ruby release. This is all necessary because pre-built rubies do not have socks support enabled by default.Is there any reason why pre-built rubies cannot have this support enabled by default? I understand that one needs to pass the
--enable-socks=true
configuration option when compiling in order for theSOCKSSocket
class to be enabled.Why the need? Well many Rubyists use SOCKS for various reasons (e.g to interact through SOCKS proxies like
dante
ortor
). Thesocksify
gem has 57M downloads for the current version. Many other languages offer native support for the SOCKS protocol and if there is no downside I'd love to see the pre-built rubies used by the Ruby community do the same - say from version 3.4 onwards - sosocksify
can be gracefully retired. \end pitch