Digest/md5 problem when using Net::SMTP

If I use the Net::SMTP module I get

Script started on Fri 05 Jul 2002 16:25:35 BST
neelix hgs 11 %> cat ruby_bug
/usr/local/bin/ruby --version
/usr/local/bin/ruby -e ‘require “net/smtp”’

neelix hgs 12 %> sh ruby_bug
ruby 1.6.7 (2002-03-01) [sparc-solaris2.7]
/usr/local/lib/ruby/1.6/net/smtp.rb:216:in require': No such file to load -- digest/md5 (LoadError) from /usr/local/lib/ruby/1.6/net/smtp.rb:216 from -e:1:inrequire’
from -e:1
neelix hgs 13 %> exit
neelix hgs 14 %>
script done on Fri 05 Jul 2002 16:25:50 BST

So this is with the latest stable ruby but I do have (results of find,
remove Perl etc refs):

/usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so

So I have the md5 modules, but not in a digest dir. Searching with
Google for more info on this, I find it came up with 1.6.5, but the
information about this is in Japanese, so I don’t know what was done.

The ext/digest directory in the Source tree seems to have been made
successfully. How should I proceed?

    Hugh

Script started on Fri 05 Jul 2002 16:25:35 BST
neelix hgs 11 %> cat ruby_bug
/usr/local/bin/ruby --version
/usr/local/bin/ruby -e 'require "net/smtp"'

neelix hgs 12 %> sh ruby_bug
ruby 1.6.7 (2002-03-01) [sparc-solaris2.7]
/usr/local/lib/ruby/1.6/net/smtp.rb:216:in `require': No such file to load -- digest/md5 (LoadError)
  from /usr/local/lib/ruby/1.6/net/smtp.rb:216
  from -e:1:in `require'
  from -e:1
neelix hgs 13 %> exit
neelix hgs 14 %>
script done on Fri 05 Jul 2002 16:25:50 BST

So this is with the latest stable ruby but I do have (results of find,
remove Perl etc refs):

/usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so

So I have the md5 modules, but not in a digest dir. Searching with
Google for more info on this, I find it came up with 1.6.5, but the
information about this is in Japanese, so I don't know what was done.

The ext/digest directory in the Source tree seems to have been made
successfully. How should I proceed?

It's odd that md5.so isn't in a digest directory. I'd suggest
upgrading, but you seem to be running a current version. It's odd
that Digest::MD5 isn't installed. Plain 'MD5' has been
depreciated/removed due to conflicting method names with external
libraries. That said, what are the odds of you trying to upgrade to
the latest 1.6? Something tells me your install is wonky. -sc

···

--
Sean Chittenden

> Script started on Fri 05 Jul 2002 16:25:35 BST
> neelix hgs 11 %> cat ruby_bug
> /usr/local/bin/ruby --version
> /usr/local/bin/ruby -e 'require "net/smtp"'
>
> neelix hgs 12 %> sh ruby_bug
> ruby 1.6.7 (2002-03-01) [sparc-solaris2.7]
> /usr/local/lib/ruby/1.6/net/smtp.rb:216:in `require': No such file to load -- digest/md5 (LoadError)
> from /usr/local/lib/ruby/1.6/net/smtp.rb:216
> from -e:1:in `require'
> from -e:1
> neelix hgs 13 %> exit
> neelix hgs 14 %>
> script done on Fri 05 Jul 2002 16:25:50 BST
>
> So this is with the latest stable ruby but I do have (results of find,
> remove Perl etc refs):
>
> /usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so
> /usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so
>
> So I have the md5 modules, but not in a digest dir. Searching with
> Google for more info on this, I find it came up with 1.6.5, but the
> information about this is in Japanese, so I don't know what was done.
>
> The ext/digest directory in the Source tree seems to have been made
> successfully. How should I proceed?

It's odd that md5.so isn't in a digest directory. I'd suggest
upgrading, but you seem to be running a current version. It's odd

Yes.

that Digest::MD5 isn't installed. Plain 'MD5' has been
depreciated/removed due to conflicting method names with external
libraries. That said, what are the odds of you trying to upgrade to
the latest 1.6? Something tells me your install is wonky. -sc

According the the main ruby site I have the latest (1.6.7 2002-03-01).
Could this be something to do with my previously having 1.4.3, 1.6.5,
and possibly other stable versions and it not clearing things out when
installing over the top? There doesn't seem to be an "uninstall" target
in the makefile for ruby. Should there be one? (RCR??)

        Thank you,
        Hugh

···

On Fri, 5 Jul 2002, Sean Chittenden wrote:

--
Sean Chittenden

According the the main ruby site I have the latest (1.6.7 2002-03-01).
Could this be something to do with my previously having 1.4.3, 1.6.5,
and possibly other stable versions and it not clearing things out when
installing over the top? There doesn’t seem to be an “uninstall” target
in the makefile for ruby. Should there be one? (RCR??)

Verify when you compile ruby, that it make the extension ext/digest/md5

moulon% find /usr/local/lib/ruby/ -name md5.so -print
/usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/digest/md5.so
moulon%

1.6/sparc-solaris2.7/md5.so is the version for 1.6.4
1.6/sparc-solaris2.7/digest/md5.so is 1.6.7

Guy Decoux

    [ output was trimmed....]

According the the main ruby site I have the latest (1.6.7 2002-03-01).
Could this be something to do with my previously having 1.4.3, 1.6.5,
and possibly other stable versions and it not clearing things out when
installing over the top? There doesn’t seem to be an “uninstall” target
in the makefile for ruby. Should there be one? (RCR??)

Verify when you compile ruby, that it make the extension ext/digest/md5
Did this in the output you trimmed:

moulon% find /usr/local/lib/ruby/ -name md5.so -print
/usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so

Yes

/usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so
Yes

/usr/local/lib/ruby/1.6/sparc-solaris2.7/digest/md5.so
No.
moulon%

1.6/sparc-solaris2.7/md5.so is the version for 1.6.4
1.6/sparc-solaris2.7/digest/md5.so is 1.6.7

So why didn’t this get installed and how should I fix it?
Hence my point about make uninstall. I could than
do a make install and be sure of having a clean start.

Guy Decoux

    Hugh
···

On Tue, 9 Jul 2002, ts wrote:

So why didn't this get installed and how should I fix it?
Hence my point about make uninstall. I could than
do a make install and be sure of having a clean start.

I don't need a 'make uninstall'

moulon# rm /usr/local/lib/ruby/1.6/sparc-solaris2.7/digest/md5.so
moulon#

moulon# find /usr/local/lib/ruby -name md5.so
/usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so
moulon#

moulon# make install
./miniruby ./instruby.rb
[...]
installing digest/md5
make[1]: Entering directory `/space/msys/decoux/ruby/ruby-1.6.7/ext/digest/md5'
md5.so -> /usr/local/lib/ruby/1.6/sparc-solaris2.7/digest/md5.so
chmod 0555 /usr/local/lib/ruby/1.6/sparc-solaris2.7/digest/md5.so
make[1]: Leaving directory `/space/msys/decoux/ruby/ruby-1.6.7/ext/digest/md5'
[...]
moulon#

moulon# find /usr/local/lib/ruby -name md5.so
/usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/digest/md5.so
moulon#

Guy Decoux

So why didn’t this get installed and how should I fix it?
Hence my point about make uninstall. I could than
do a make install and be sure of having a clean start.

I don’t need a ‘make uninstall’

moulon# rm /usr/local/lib/ruby/1.6/sparc-solaris2.7/digest/md5.so

Missed that step as I don’t have the file…

moulon#
[…]
moulon# make install

Gave me:
[…]
chmod 0644 /usr/local/lib/ruby/1.6/sparc-solaris2.5.1/config.h
/home/hgs/ruby/ruby-1.6.7/libruby.a ->
/usr/local/lib/ruby/1.6/sparc-solaris2.5.
1/libruby.a
chmod 0644 /usr/local/lib/ruby/1.6/sparc-solaris2.5.1/libruby.a
rbconfig.rb -> /usr/local/lib/ruby/1.6/sparc-solaris2.5.1/rbconfig.rb
chmod 0644 /usr/local/lib/ruby/1.6/sparc-solaris2.5.1/rbconfig.rb

find /usr/local -type f -name “md5*” -print

/usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris/sys/md5.ph
/usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris/sys/md5_consts.ph
/usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so
/usr/local/lib/python1.5/lib-dynload/md5module.so
/usr/local/lib/python2.2/lib-dynload/md5.so
/usr/local/teTeX/share/texmf/teTeX-1.0/libs/libwww/md5.c
/usr/local/teTeX/share/texmf/teTeX-1.0/libs/libwww/md5.h
/usr/local/ssl/man/man3/md5.3
/usr/local/ssl/include/openssl/md5.h

···

On Tue, 9 Jul 2002, ts wrote:

So it is still not built…
[…]

Guy Decoux

    Hugh

chmod 0644 /usr/local/lib/ruby/1.6/sparc-solaris2.5.1/config.h

                                      ^^^^^^^^^^^^^^^^^^

What is this ?

/home/hgs/ruby/ruby-1.6.7/libruby.a ->
/usr/local/lib/ruby/1.6/sparc-solaris2.5.
1/libruby.a
chmod 0644 /usr/local/lib/ruby/1.6/sparc-solaris2.5.1/libruby.a
rbconfig.rb -> /usr/local/lib/ruby/1.6/sparc-solaris2.5.1/rbconfig.rb
chmod 0644 /usr/local/lib/ruby/1.6/sparc-solaris2.5.1/rbconfig.rb
# find /usr/local -type f -name "md5*" -print
/usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris/sys/md5.ph
/usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris/sys/md5_consts.ph
/usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so

                           ^^^^^^^^^^^^^^^^

/usr/local/lib/python1.5/lib-dynload/md5module.so

Guy Decoux

chmod 0644 /usr/local/lib/ruby/1.6/sparc-solaris2.5.1/config.h
^^^^^^^^^^^^^^^^^^

What is this ?

    [...]

/usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so
^^^^^^^^^^^^^^^^

Hmm. Yes, together with that it is rather suspicious…

OK, cleared that dir out, and completely re-installed ruby…

find /usr/local -type f -name “md5.so” -print

/usr/local/lib/ruby/1.4/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/md5.so
/usr/local/lib/ruby/1.6/sparc-solaris2.7/digest/md5.so
/usr/local/lib/python2.2/lib-dynload/md5.so

···

On Tue, 9 Jul 2002, ts wrote:

That looks better. It looks like I botched the install 2 ways last
time: I did it from my nfs-mounted home dir, which root on this machine
can’t write to during the install, so I got errors in extmk.rb;
I also had config information left over from the installation on the
other machines. It is amazing it has worked so well for so long!

Thank you for spotting this!

Guy Decoux

    Hugh