-
Notifications
You must be signed in to change notification settings - Fork 7.3k
./configure report 'Unknown compiler' error #3601
Comments
Why can't anything be easy, eh? Can you try this patch? diff --git a/configure b/configure
index 7bf4536..810d423 100755
--- a/configure
+++ b/configure
@@ -265,19 +265,11 @@ def target_arch():
def compiler_version():
proc = subprocess.Popen(CC.split() + ['--version'], stdout=subprocess.PIPE)
- version_line = proc.communicate()[0].split('\n')[0]
+ is_clang = 'clang' in proc.communicate()[0].split('\n')[0]
- if 'clang' in version_line:
- version, is_clang = version_line.split()[2], True
- elif 'gcc' in version_line:
- version, is_clang = version_line.split()[-1], False
- else:
- raise Exception(
- 'Unknown compiler. Please open an issue at ' +
- 'https://github.com/joyent/node/issues and ' +
- 'include the output of `%s --version`' % CC)
+ proc = subprocess.Popen(CC.split() + ['-dumpversion'], stdout=subprocess.PIPE)
+ version = tuple(map(int, proc.communicate()[0].split('.')))
- version = tuple(map(int, version.split('.')))
return (version, is_clang)
|
Hi, With the patch, Trace included below (the
Thanks! Best regards, Fermín |
Thanks. Can you try this (additional) patch? I'm afraid that anything before 4.6.0 is a lost cause... diff --git a/configure b/configure
index 7bf4536..05a26d8 100755
--- a/configure
+++ b/configure
@@ -295,12 +295,9 @@ def configure_node(o):
# turn off strict aliasing if gcc < 4.6.0 unless it's llvm-gcc
# see http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45883
# see http://code.google.com/p/v8/issues/detail?id=884
- o['variables']['strict_aliasing'] = b(is_clang or cc_version >= (4,6,0))
-
- # disable strict aliasing in V8 if we're compiling with gcc 4.5.x,
- # it makes V8 crash in various ways
- o['variables']['v8_no_strict_aliasing'] = b(
- not is_clang and (4,5,0) <= cc_version < (4,6,0))
+ strict_aliasing = is_clang or cc_version >= (4,6,0)
+ o['variables']['strict_aliasing'] = b(strict_aliasing)
+ o['variables']['v8_no_strict_aliasing'] = b(not strict_aliasing)
# clang has always supported -fvisibility=hidden, right?
if not is_clang and cc_version < (4,0,0): |
Both patches applied fix this problem for me--on Ubuntu 12.04 with |
@bnoordhuis I hadn't chance to test the last patch you post, sorry (I started my vacations just after my last post) but I've checked that the problem has been solved in 0.8.3, so everithing is ok :). Thanks! |
Hi,
Working on v0.8 branch, running
./configure
I get the following message:So I'm opening this issue. This is the output of
cc --version
Note that it's different from the output of
gcc -v
, that I'm pasting below just in case it is needed:Thanks!
Best regards,
Fermín
The text was updated successfully, but these errors were encountered: