Bug 48851 - [Chromium] Build failure with clang
Summary: [Chromium] Build failure with clang
Status: RESOLVED DUPLICATE of bug 48414
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-02 10:55 PDT by Cosmin Truta
Modified: 2010-11-02 14:38 PDT (History)
3 users (show)

See Also:


Attachments
Fix (1.66 KB, patch)
2010-11-02 11:46 PDT, Cosmin Truta
dglazkov: review+
dglazkov: commit-queue+
Details | Formatted Diff | Diff
Fix (fixed) (1.66 KB, patch)
2010-11-02 13:08 PDT, Cosmin Truta
dglazkov: review+
ctruta: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Cosmin Truta 2010-11-02 10:55:37 PDT
I tried building Chromium with clang, according to the instructions posted at
http://code.google.com/p/chromium/wiki/Clang

The build failed because of the following compiler warning-turned-error:
DumpRenderTree/chromium/TestShell.h:147:68: error: comparison of unsigned expression >= 0 is always true [-Wtautological-compare]

This was introduced in changeset 70537:
http://trac.webkit.org/changeset/70537
Comment 1 Cosmin Truta 2010-11-02 11:46:23 PDT
Created attachment 72708 [details]
Fix

Here is the fix.

Since gcc doesn't issue this warning by default, would it not be worth adding -Wtype-limits (and possibly others) to all CFLAGS, to ensure a smoother gcc <-> clang transition in the future?
Comment 2 Dimitri Glazkov (Google) 2010-11-02 11:57:39 PDT
Comment on attachment 72708 [details]
Fix

ok.
Comment 3 Cosmin Truta 2010-11-02 13:08:07 PDT
Created attachment 72723 [details]
Fix (fixed)

Oops, I accidentally made changes in the wrong git branch, and my previous patch turned out backwards.
Here is the correct fix.
Comment 4 Dimitri Glazkov (Google) 2010-11-02 13:11:06 PDT
Comment on attachment 72723 [details]
Fix (fixed)

ok.
Comment 5 Søren Gjesse 2010-11-02 14:07:07 PDT
Isn't this what is already fixed by https://bugs.webkit.org/show_bug.cgi?id=48414?
Comment 6 Cosmin Truta 2010-11-02 14:31:21 PDT
(In reply to comment #5)
> Isn't this what is already fixed by https://bugs.webkit.org/show_bug.cgi?id=48414?

Oh, yeah, it is...
I had a 1-day-old copy of WebKit that I should have refreshed...
Comment 7 Cosmin Truta 2010-11-02 14:35:20 PDT
Comment on attachment 72723 [details]
Fix (fixed)

Setting cq-.
This was already fixed yesterday in bug 48414, and I haven't noticed.
Comment 8 Cosmin Truta 2010-11-02 14:38:57 PDT

*** This bug has been marked as a duplicate of bug 48414 ***