./configure --dist-cpu=x64 not working on Mac OS X Lion #2535

Closed
englishmatt opened this Issue Jan 15, 2012 · 7 comments

Projects

None yet

4 participants

@englishmatt

When attempting to build to a 64-bit architecture on Lion, the configure script is still reporting a 32-bit host environment (and subsequently, setting the target architecture as such (output below)). Also reported on stackoverflow with more anecdotal information.

'{ 'target_defaults': { 'cflags': [],
               'defines': [],
               'include_dirs': [],
               'libraries': ['-lz']},
'variables': { 'host_arch': 'ia32',
         'node_debug': 'false',
         'node_install_npm': 'true',
         'node_prefix': '/usr/local',
         'node_shared_cares': 'false',
         'node_shared_v8': 'false',
         'node_use_dtrace': 'false',
         'node_use_isolates': 'true',
         'node_use_openssl': 'true',
         'node_use_system_openssl': 'false',
         'target_arch': 'ia32',
         'v8_use_snapshot': 'true'}}
@bnoordhuis
Member

Thanks for the report. I've committed a fix in 93465d3. Let me know if you still have issues.

@bnoordhuis bnoordhuis closed this Jan 15, 2012
@yeysus
yeysus commented Jan 15, 2012

@bnoordhuis: I am not able to find some documentation on this --dist-cpu switch. Where can I find some benchmark or recommendation for building on linux? Thanks. And btw: I think, in the wiki, the note regarding the python switch should include exporting PYTHONHOME.

@bnoordhuis
Member

@yeysus: Try ./configure --help (There's a typo in the headline, by the way. The option is called --dest-cpu.)

Where can I find some benchmark or recommendation for building on linux?

You mean what's best from a performance perspective, ia32 or x64 builds? I don't know of any benchmarks but from personal experience, the performance gap for I/O bound applications is small to non-existent. The ia32 builds use a little less memory though.

And btw: I think, in the wiki, the note regarding the python switch should include exporting PYTHONHOME.

It's a wiki, feel free to add it. :-)

@yeysus
yeysus commented Jan 15, 2012

config option: OK. I may try a few things. wiki: Done.

@englishmatt

Just tried to get this going again. Turns out target architecture is now reporting correctly (x64), but the host architecture still reports ia32.

{ 'target_defaults': { 'cflags': [],
                   'defines': [],
                   'include_dirs': [],
                   'libraries': ['-lz']},
'variables': { 'host_arch': 'ia32',
             'node_install_npm': 'true',
             'node_install_waf': 'true',
             'node_prefix': '/usr/local',
             'node_shared_cares': 'false',
             'node_shared_v8': 'false',
             'node_use_dtrace': 'false',
             'node_use_isolates': 'true',
             'node_use_openssl': 'true',
             'node_use_system_openssl': 'false',
             'target_arch': 'x64',
             'v8_use_snapshot': 'true'}}

To prove to myself I'm running Lion in 64-bit, I ran a sysctl -a hw, results below:

hw.cpu64bit_capable: 1
...
hw.optional.x86_64: 1
....
hw.machine = x86_64
@bnoordhuis
Member

englishmatt: That probably doesn't matter. What does file out/Release/node say?

@kyteague
kyteague commented Feb 8, 2012

I am having the same issue. I can't get it to compile to x86_64 despite setting --dest-cpu to x64.

$ file out/Release/node
out/Release/node: Mach-O executable i386
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment