node.js on mac in 32 bit mode?

1.5k Views Asked by At

For the app.js I need to have my node.js in 32 bit mode.

node me$ file `which node`
/usr/local/bin/node: Mach-O universal binary with 2 architectures
/usr/local/bin/node (for architecture i386):    Mach-O executable i386
/usr/local/bin/node (for architecture x86_64):  Mach-O 64-bit executable x86_64
node me$ 

Does this mean, that it is installes in two executable versions(32 and 64 bit) on my system? If so, how can I tell the executable to run the 32 bit version?

1

There are 1 best solutions below

2
On

On this page: https://nodejs.org/download/ you can download and install the 32-bit version, and node should then run only the 32-bit version. Be sure to remove any other instances you have of it first. You can verify which you have with a command like this:

$ file `which node`

I have the 64-bit version and I get:

$ file `which node`
/usr/local/bin/node: Mach-O 64-bit executable x86_64

You should get something about 32-bit once you get the 32-bit version installed.