Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked

Re: How to tell 32 or 64 bit

by bulk88 (Priest)
on Oct 08, 2012 at 03:30 UTC ( #997732=note: print w/replies, xml ) Need Help??

in reply to How to tell 32 or 64 bit

A 32 bit perl.
C:\p517\perl>perl -v This is perl 5, version 17, subversion 5 (v5.17.5 (v5.17.4-47-g432d456 +)) built for MSWin32-x86-multi-thread
A 64 bit perl.
C:\Documents and Settings\Administrator\Desktop>perl -v This is perl 5, version 14, subversion 2 (v5.14.2) built for MSWin32-x +64-multi-thread
To get it in a script
C:\p517\perl>perl -MConfig -e "print $Config{archname}" MSWin32-x86-multi-thread C:\p517\perl>

Replies are listed 'Best First'.
Re^2: How to tell 32 or 64 bit
by flexvault (Monsignor) on Oct 14, 2012 at 11:37 UTC


    I just used your code:

    email7: perl -MConfig -E 'say $Config{archname};'
    for 4 different Perls built on Linux and 3 built on AIX/Unix computers and none of them had 32 or 64 in the response. I then looped on the %Config hash with 'grep 32' for all platforms and nothing looks consistent between Linux and AIX/Unix. If the original question was for Windows, I guess it works, but it doesn't seem to be a platform independent solution.

    Just a heads-up...Ed

    Update: After commenting, I reread the original post and you're solution was right on for windows.

    "Well done is better than well said." - Benjamin Franklin

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://997732]
marto waves
[Marshall]: marto howdy!
[marto]: Hey there
[Marshall]: hope we get a good answer to Script stopped working... this OP is making serious efforts to solve problem on his own.
[Marshall]: I've become frustrated lately with some OP's.

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (4)
As of 2018-03-18 12:51 GMT
Find Nodes?
    Voting Booth?
    When I think of a mole I think of:

    Results (230 votes). Check out past polls.