Bug #37743 | BUILD/check-cpu fails on openSUSE Linux 11.0 | ||
---|---|---|---|
Submitted: | 30 Jun 2008 15:36 | Modified: | 30 Sep 2008 7:24 |
Reporter: | Lenz Grimmer | Email Updates: | |
Status: | Duplicate | Impact on me: | |
Category: | MySQL Server: Compiling | Severity: | S3 (Non-critical) |
Version: | 5.0 and up | OS: | Linux (openSUSE 11.0) |
Assigned to: | Assigned Account | CPU Architecture: | Any |
Tags: | compiling, Contribution, gcc, opensuse, patch |
[30 Jun 2008 15:36]
Lenz Grimmer
[30 Jun 2008 17:50]
Sveta Smirnova
Thank you for the report. Please indicate which shell do you use.
[1 Jul 2008 6:02]
Lenz Grimmer
Hi Sveta, thanks for your message. Not that I think it matters, I usually use zsh. However, the scripts in the BUILD subdirectory all use #!/bin/sh and this is what I used to debug and isolate the problem as well. It's not a shell problem, the sed call in line 172 that tries to determine the gcc version fails on openSUSE 11.0, because the first regexp is too greedy and matches on the second "gcc". This is the code in question: cc_ver=`$cc --version | sed 1q` cc_verno=`echo $cc_ver | sed -e 's/^.*gcc/gcc/g; s/[^0-9. ]//g; s/^ *//g; s/ .*//g'` The "s/^.*gcc/gcc/g" removes too much of the "gcc (SUSE Linux) 4.3.1 20080507 (prerelease) [gcc-4_3-branch revision 135036]" string (as "gcc" occurs a second time at the end of the string")
[1 Jul 2008 8:26]
Lenz Grimmer
Setting it to verified as per our IRC discussion.
[1 Jul 2008 11:01]
Lenz Grimmer
Patch to fix BUG#37743 - correct the regexp to match the compiler string on openSUSE 11.0
Attachment: check-cpu.patch (text/x-patch), 444 bytes.
[1 Jul 2008 11:03]
Lenz Grimmer
The patch attached fixes the issue (thanks to Daniel for the suggestion). Please apply! Thanks.
[29 Sep 2008 9:35]
Lenz Grimmer
Seems like this is a duplicate of Bug#36519 (check-cpu fails with gcc 4.3.1) - I can not reproduce it anymore. Sorry for the noise!