Forum: Ruby Installing on MaxOSX?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
030c4387213f4db90112d28c69fbf152?d=identicon&s=25 unknown (Guest)
on 2005-12-11 17:27
(Received via mailing list)
Dear Ladies and Gentlemen,

Are there installation instructions for Mac OS X somewhere?

Log so far:

- Downloaded source files, unzipped, removed the black stuff.
- Read the README.  Accordingly:
- Checked that configure was a recent copy.
- typed ./configure
- typed make
- typed make test (successful)
- typed sudo make install
   (didn't know at this stage that mac already comes with ruby
installed.
   The last step probably replaced the preinstalled version if any.
   I don't really mind as the impression I get of Ruby is that it's a
fast
   developing language and so it's worth having the most up to date
copy.)

Now the exciting bit: typed ruby.
Basically nothing happens.  I can type commands but there is no prompt
and
the commands never return anything:

.../Languages/Ruby/ruby-1.8.3 max$ ruby
1
1*2
print "ElloElloEllo"
[pressed control C to escape]


Is there any more information I need to provide when compiling?

On the ruby wiki the installation instructions mention how to inform the
compiler of the location of X11, Tk, Tcl and a few other packages like
that, however make test succeeded so I doubt this.  What are all the
dependencies?  Why, for instance, might X11 be needed for a command line
program?

Does any of you use Mac OS X?  How do you compile?  Did you have to
install any other packages first?

Best Wishes, Max
8e44c65ac5b896da534ef2440121c953?d=identicon&s=25 Ezra Zygmuntowicz (Guest)
on 2005-12-11 17:27
(Received via mailing list)
> Max-

	You use the ruby command to run scripts that you type into a file.
Try to do thye same thing you did by typing ruby at the cli prompt
and then after typing a few expressions, hit Cntrl-D. That will cause
the code to execute. But You are better off using interactive ruby to
play with ruby on the command line. Type irb at your command line and
you will see what happens.


Cheers-

-Ezra Zygmuntowicz
Yakima Herald-Republic
WebMaster
http://yakimaherald.com
509-577-7732
ezra@yakima-herald.com
31af45939fec7e3c4ed8a798c0bd9b1a?d=identicon&s=25 Matthew Smillie (Guest)
on 2005-12-11 17:27
(Received via mailing list)
On Dec 1, 2005, at 22:36, m@de-minimis.co.uk wrote:
> .../Languages/Ruby/ruby-1.8.3 max$ ruby
> 1
> 1*2
> print "ElloElloEllo"
> [pressed control C to escape]

By default, Ruby installs to /usr/local/bin/ruby, while the original
one is at /usr/bin/ruby - so unless you changed it, the original's
still there.  You can set your path variable to determine which one
to use.  Mac's default Ruby is subtley broken, so you're likely
better off in the long run installing your own.

If you just type Ruby, then the interpreter is reading from the
standard input as if it were a file (this is pretty standard
behaviour, perl works the same way).  If you hit ctrl-D (which
indicates end-of-file) you should see something happen.  If nothing
happens when you do that, then something is very definitely UP.

Something better to try would be running 'irb' which is the
interactive interpreter, which sounds like what you were expecting to
get in the first place.

good luck,
matthew smillie.
030c4387213f4db90112d28c69fbf152?d=identicon&s=25 unknown (Guest)
on 2005-12-11 17:27
(Received via mailing list)
Thanks very much.  That's gut! Sehr gut.

Regards, Max
This topic is locked and can not be replied to.