[llvm-commits] [compiler-rt] r170695 - in /compiler-rt/trunk/lib/tsan: Makefile.old check_cmake.sh

David Blaikie dblaikie at gmail.com
Thu Dec 20 09:41:05 PST 2012


On Thu, Dec 20, 2012 at 9:37 AM, Dmitry Vyukov <dvyukov at google.com> wrote:
> On Thu, Dec 20, 2012 at 9:14 AM, David Blaikie <dblaikie at gmail.com> wrote:
>> On Thu, Dec 20, 2012 at 6:10 AM, Dmitry Vyukov <dvyukov at google.com> wrote:
>>> Author: dvyukov
>>> Date: Thu Dec 20 08:10:27 2012
>>> New Revision: 170695
>>>
>>> URL: http://llvm.org/viewvc/llvm-project?rev=170695&view=rev
>>> Log:
>>> tsan: add cmake build and tests into presubmit script
>>>
>>> Added:
>>>     compiler-rt/trunk/lib/tsan/check_cmake.sh   (with props)
>>> Modified:
>>>     compiler-rt/trunk/lib/tsan/Makefile.old
>>>
>>> Modified: compiler-rt/trunk/lib/tsan/Makefile.old
>>> URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/tsan/Makefile.old?rev=170695&r1=170694&r2=170695&view=diff
>>> ==============================================================================
>>> --- compiler-rt/trunk/lib/tsan/Makefile.old (original)
>>> +++ compiler-rt/trunk/lib/tsan/Makefile.old Thu Dec 20 08:10:27 2012
>>> @@ -73,6 +73,8 @@
>>>         ./check_analyze.sh
>>>         # Sanity check for Go runtime
>>>         (cd go && ./buildgo.sh)
>>> +       # Check cmake build
>>> +       ./check_cmake.sh
>>>         @ echo PRESUBMIT PASSED
>>>
>>>  install_deps:
>>>
>>> Added: compiler-rt/trunk/lib/tsan/check_cmake.sh
>>> URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/tsan/check_cmake.sh?rev=170695&view=auto
>>> ==============================================================================
>>> --- compiler-rt/trunk/lib/tsan/check_cmake.sh (added)
>>> +++ compiler-rt/trunk/lib/tsan/check_cmake.sh Thu Dec 20 08:10:27 2012
>>> @@ -0,0 +1,11 @@
>>> +#!/bin/bash
>>> +set -u
>>> +set -e
>>> +
>>> +ROOT="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
>>> +mkdir -p $ROOT/build
>>> +cd $ROOT/build
>>> +CC=gcc CXX=g++ cmake -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_ASSERTIONS=ON $ROOT/../../../..
>>
>> Any particular reason you're explicitly specifying gcc as the compiler
>> here? The general suggestion/original issue was that a clang + cmake +
>> werror build was not done & so I hit a break in that build. This
>> change would still not catch that.
>
>
> If I build it as follows, will it include all the necessary flags
> (e.g. -Wgnu and maybe something else that I don't know about)?
>
> CC=clang CXX=clang++ cmake -DCMAKE_BUILD_TYPE=Release
> -DLLVM_ENABLE_ASSERTIONS=ON $ROOT/../../../..

-DLLVM_ENABLE_WERROR=ON

would also be useful, other than that it looks fine. (you could verify
this by undoing your fix to the build gnu break I mentioned & see if
this reports it)

(we should probably just have -Werror on by default when clang is
detected as the compiler, but we don't have that yet)

> make -j64



More information about the llvm-commits mailing list