From: "F. Senault" Date: 2008-09-04T08:44:24+09:00 Subject: Re: Can a Ruby program determine whether it's running on a 32-bit or 64-bit system? Le 3 septembre 2008 � 02:42, Eric Promislow a �crit : > I can't go by RUBY_PLATFORM -- I'm setting up a new 32-bit Linux box, > and RUBY_PLATFORM is set to "i686-linux". Pack has a support for native size : >> RUBY_PLATFORM => "i386-freebsd6" >> [ -1 ].pack('l!').length => 4 While... >> RUBY_PLATFORM => "amd64-freebsd7" >> [ -1 ].pack('l!').length => 8 (From the Pickaxe : 'Any of the directives "sSiIlL" may be followed by an underscore (_) or bang (!) to use the underlying platform's native size for the specified type') Fred -- When I was a child I had a fever. My hands felt just like two balloons. Now I got that feeling once again. I can't explain, you would not understand. This is not how I am. I have become comfortably numb. (Pink Floyd, Comfortably Numb)