summaryrefslogtreecommitdiffstats
path: root/compiler-rt/CMakeLists.txt
Commit message (Collapse)AuthorAgeFilesLines
* [ASan] Bump min supported Mac OS X version to 10.6Alexey Samsonov2013-07-161-1/+1
| | | | llvm-svn: 186404
* Always set -m32/-m64 flags for targeting i386/x86_64 respectively. ↵Alexey Samsonov2013-06-301-13/+6
| | | | | | Apparently, there are platforms where the clang defaults are different from gcc llvm-svn: 185287
* Drop support for 32-bit PowerPC in sanitizer tools.Alexey Samsonov2013-06-071-1/+1
| | | | llvm-svn: 183499
* [ASan] lit tests: create common autogenerated config for running compiler-rt ↵Alexey Samsonov2013-06-061-0/+1
| | | | | | lit tests, and use it in ASan llvm-svn: 183400
* [sanitizer] Interceptors for gethostbyname and friends.Evgeniy Stepanov2013-05-231-0/+1
| | | | llvm-svn: 182573
* [nolibc] Disable the GCC stack protector when building sanitizer runtimes.Peter Collingbourne2013-05-081-0/+1
| | | | | | | | | | | | | | | | | | | This is the first in a sequence of changes designed to eliminate the libc dependency in sanitizer_common. The main motivation for these changes is to be able to provide an alternative for the current interceptor-based technique for instrumenting functions in libc. In this new technique, we compile libc with instrumentation. This has the potential advantages of being more accurate than interception and reducing the amount of custom code required for each libc function. As a side effect of this, we cannot depend on libc in the sanitizer runtime due to mutual dependency issues. This change disables the GCC stack protector, which introduces a libc dependency and is enabled by default in Ubuntu. Differential Revision: http://llvm-reviews.chandlerc.com/D755 llvm-svn: 181422
* Explicitly list all sanitizer headers in CMake build rules. Make sure ↵Alexey Samsonov2013-04-111-41/+5
| | | | | | sanitizer lit_tests depend on fresh headers. llvm-svn: 179293
* Change the cmake variable COMPILER_RT_CAN_EXECUTE_TESTS to be an option so ↵Michael Gottesman2013-04-011-3/+3
| | | | | | | | | | | | | that it can overwritten. The reason why this simple change is needed is that I am trying to set up a quick cmake/ninja based buildbot and apple-clang does not support using the sanitizers currently. The default behavior follows exactly what was there before implying that no ones builds should be affected at all. llvm-svn: 178455
* [Sanitizer] Compile sanitizer runtimes with -Wno-non-virtual-dtor. Virtual ↵Alexey Samsonov2013-03-251-0/+6
| | | | | | dtors may be a problem for us, as sanitizer runtime should not generally assume libstdc++ presence. llvm-svn: 177860
* Support CMake build of profile runtime library on LinuxAlexey Samsonov2013-03-191-3/+6
| | | | llvm-svn: 177382
* [CMake] set -mmacosx-version-min to 10.7 if compiler-rt is built with ↵Alexey Samsonov2013-02-081-1/+13
| | | | | | -stdlib=libc++ llvm-svn: 174699
* [sanitizer] Copy sanitizer headers to the build tree.Evgeniy Stepanov2013-01-291-0/+33
| | | | llvm-svn: 173794
* CMake: generalize checking for target availability and add initial support ↵Alexey Samsonov2013-01-211-21/+28
| | | | | | for PowerPC native arch. With this patch, building LLVM on PowerPC native arch produces a working ASan runtime. llvm-svn: 173044
* CMake: add functions creating universal runtime libraries for several ↵Alexey Samsonov2013-01-211-13/+0
| | | | | | architectures on OS X and use them in ASan and UBSan build rules llvm-svn: 173011
* CMake: Add add_compiler_rt_static_runtime function and use it to build ↵Alexey Samsonov2013-01-201-17/+17
| | | | | | generic compiler-rt libraries llvm-svn: 172977
* CMake: Generalize build rules for different arches for sanitizer_common, ↵Alexey Samsonov2013-01-181-0/+5
| | | | | | asan, ubsan llvm-svn: 172829
* CMake: create AddCompilerRT module and implement convenience ↵Alexey Samsonov2013-01-181-17/+1
| | | | | | add_compiler_rt_object_library function llvm-svn: 172826
* CMake: start to generalize rules for non-x86 architecturesAlexey Samsonov2013-01-181-16/+20
| | | | llvm-svn: 172816
* CMake variables renaming: X86_64->x86_64 I386->i386Alexey Samsonov2013-01-181-14/+14
| | | | llvm-svn: 172812
* Define COMPILER_RT_CAN_EXECUTE_TESTS variable on platforms where we can ↵Alexey Samsonov2012-12-271-0/+9
| | | | | | produce working binaries and use it in build rules for sanitizers tests llvm-svn: 171160
* [ASan] Support building both 32- and 64-bit unit tests if we can target both ↵Alexey Samsonov2012-12-191-0/+10
| | | | | | architectures llvm-svn: 170549
* Significantly change the way we build ASan unittests in CMakeAlexey Samsonov2012-12-191-0/+8
| | | | | | | | | | | | | | | build tree. Now just-built Clang is used to: 1) compile instrumented sources (as before); 2) compile non-instrumented sources; 3) compile our own instrumented version of googletest; 4) link it all together using -fsanitize=address flag (instead of trying to copy linker behavior in CMake build rules). This makes ASan unittests pretty much self-consistent and independent of other LLVM libraries. llvm-svn: 170541
* [ASan] Remove llvm-symbolizer from compiler-rt/utils/Alexander Potapenko2012-11-121-3/+0
| | | | | | | This is the first (1/2) part of a change that moves llvm-symbolizer to llvm/tools/, which will allow to build it with both cmake and configure+make. llvm-svn: 167722
* [Sanitizer] Build all sanitizer runtime libraries with debug info (with ↵Alexey Samsonov2012-11-081-0/+8
| | | | | | -gline-tables-only, if it's available) llvm-svn: 167584
* [ASan] Apply some ASan-relevant pieces of patch by Ruben Van Boxem. In the ↵Alexey Samsonov2012-09-241-1/+3
| | | | | | same time, remove ASan from CMake build on Windows after conversation with Timur. We don't want to support building ASan on Windows until it is in a working state. llvm-svn: 164486
* [Sanitizer] don't use -Werror as default compile flag for sanitizer runtimes ↵Alexey Samsonov2012-09-131-1/+0
| | | | | | - people may use too many distinct/old host compilers llvm-svn: 163784
* [Sanitizer] Please Android build. Re-check the availability of ↵Alexey Samsonov2012-09-121-2/+2
| | | | | | -Wno-variadic-macros flag. llvm-svn: 163688
* [Sanitizer] first effort to start building ASan runtime with -Werror in ↵Alexey Samsonov2012-09-121-0/+1
| | | | | | CMake build llvm-svn: 163686
* CMake build rules for ASan Android runtime and tests.Evgeniy Stepanov2012-09-111-14/+7
| | | | llvm-svn: 163613
* Fox a typo.Evgeniy Stepanov2012-09-111-1/+1
| | | | llvm-svn: 163611
* [compiler-rt] Install support for CMake build of compiler-rtAlexey Samsonov2012-09-111-0/+34
| | | | llvm-svn: 163607
* [ASan] hoist more compile flags to SANITIZER_COMMON_CFLAGS var and add the ↵Alexey Samsonov2012-09-051-0/+6
| | | | | | rest of flags/defs from old Makefile to CMake llvm-svn: 163204
* [compiler-rt] Recurse into 'utils' directory in CMake build of compiler-rt, ↵Alexey Samsonov2012-09-041-0/+3
| | | | | | enable build of llvm-symbolizer binary (currently for one target only) llvm-svn: 163138
* Relocate the external headers provided by ASan and the common sanitizerChandler Carruth2012-08-291-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | library. These headers are intended to be available to user code when built with AddressSanitizer (or one of the other sanitizer's in the future) to interface with the runtime library. As such, they form stable external C interfaces, and the headers shouldn't be located within the implementation. I've pulled them out into what seem like fairly obvious locations and names, but I'm wide open to further bikeshedding of these names and locations. I've updated the code and the build system to cope with the new locations, both CMake and Makefile. Please let me know if this breaks anyone's build. The eventual goal is to install these headers along side the Clang builtin headers when we build the ASan runtime and install it. My current thinking is to locate them at: <prefix>/lib/clang/X.Y/include/sanitizer/common_interface_defs.h <prefix>/lib/clang/X.Y/include/sanitizer/asan_interface.h <prefix>/lib/clang/X.Y/include/sanitizer/... But maybe others have different suggestions? Fixing the style of the #include between these headers at least unblocks experimentation with installing them as they now should work when installed in these locations. llvm-svn: 162822
* Some flag cleanup for the sanitizer runtimes.Chandler Carruth2012-08-291-0/+16
| | | | | | | | | | | | This hoists most of the CFLAGS into a common variable. It also adds detection for -Wno-c99-extensions and uses it to silence a pile of warnings. Finally, it switches to the proper flag -rdynamic. With this, the cmake build is warning free on my bootstrap Linux build. llvm-svn: 162809
* CMake build rules for ASan/Android runtime.Evgeniy Stepanov2012-08-271-0/+14
| | | | llvm-svn: 162675
* [ASan] CMake support for building ASan runtime as a universal binary on MacAlexey Samsonov2012-08-101-0/+12
| | | | llvm-svn: 161665
* [compiler-rt] CMake build: if LLVM_BUILD_32_BITS is on, then -m32 is added ↵Alexey Samsonov2012-08-071-1/+1
| | | | | | to llvm definitions. Let us override this by explicitly adding -m64 compiler flag when building compiler-rt libraries for x86_64 target llvm-svn: 161415
* Add support for building the ASan instrumentation unit tests with theChandler Carruth2012-06-271-0/+10
| | | | | | | | | | | | | | just-built Clang binary, and linking them against the just-built ASan runtime. This is *very* brittle. I expect it will require tweaking, and I've pro-actively disabled it on non-Unix builds and on cross-builds. It is also currently missing dependency edges on GoogleTest header files and a few other corner cases, but those can be fixed. This is the major milestone of a mini-bootstrap-like build of the unittest. llvm-svn: 159255
* Another big step toward a viable CMake build system for CompilerRT,Chandler Carruth2012-06-251-0/+6
| | | | | | | | | | | | | | | | | | | | | | | ASan, and friends. This explicitly switches the CompilerRT CMake build to require CMake version 2.8.8 or newer which provides first-class support for "object" libraries which consist of a pile of '.o' files -- exactly what is desired for composing runtime libraries. I've gone ahead and switched to using this. I've also added the interception library which I missed initially. And I've added proper dependencies between the various libraries. With this, I'm able to build archives for asan that appear to contain all of the necessary .o files. The final tweak here is to start setting up the compile flags and macro defines expected by ASan and its helper libraries. These may not be entirely correct currently, they're based loosely on my reading of the old Makefiles. However, they can be tweaked more easily now that they're wired up properly. llvm-svn: 159129
* Disable the test subdirectory entirely until we get fresh CMake filesChandler Carruth2012-06-221-1/+4
| | | | | | | there. I didn't notice this because I had a stub that wasn't checked in floating around in my client. llvm-svn: 159025
* Initial, very rough cut at a new CMake build system for compiler-rt.Chandler Carruth2012-04-041-0/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | Some high-level notes: 1) An explicit goal is to support building compiler-rt as a subproject build, checked out into the projects/compiler-rt directory. There are many other possible ways of building the code here, but this is optimized for development on LLVM/Clang/compiler-rt, and incremental trial and testing of the toolchain. 2) The current support is targeted at Linux. I would love to see this generalized to other platforms, but for the sake of simplicity in testing, I'm focusing here first. Much of this patch was paired with Manuel, and I credit him with the majority of the work here. Some important caveats that I'll be working on in subsequent patches: 1) This uses the host compiler rather than using the just-built-clang. 2) Currently only x86 is supported. 3) Currently, none of the tests are built or run. 4) Uses CMake's builtin globbing which doesn't update correctly. 5) This is still turned off from LLVM's CMake build until these issues are addressed llvm-svn: 154060
* Remove the old, and non-functional CMake build system from CompilerRT.Chandler Carruth2012-04-041-55/+0
| | | | | | | | | I cannot build any part of this successfully on either Linux or Darwin, and the replacement is worlds simpler by requiring that this be built as a subproject of LLVM. If this breaks you for any reason, please let me know, and let me know what your use case is. llvm-svn: 154059
* Sink {config.h,ConfigureChecks}.cmake into cmake directory.Daniel Dunbar2010-01-131-3/+4
| | | | llvm-svn: 93318
* Fix CMakeLists.txt comment.Edward O'Callaghan2009-10-311-1/+1
| | | | llvm-svn: 85686
* Fix cmake test suit for compiler-rt.Edward O'Callaghan2009-10-271-1/+1
| | | | llvm-svn: 85339
* Comment out broken tests and make the rest build in cmake build system.Edward O'Callaghan2009-10-171-1/+1
| | | | llvm-svn: 84330
* If the compiler does not support GCC-compatibleShantonu Sen2009-09-231-3/+13
| | | | | | atomic operations, skip building the blocks runtime llvm-svn: 82627
* 1) Remove cmake-specific #define usage from the exportedShantonu Sen2009-09-221-7/+0
| | | | | | | | | | | | | | | | | | | Block.h/Block_private.h headers, since clients won't know what to set. These are moved into runtime.c as appropriate 2) Use cmake checks for CAS builtins, instead of guessing based on GCC #defines (which aren't set by clang and llvm-gcc anyway) 3) "#pragma mark" isn't supported by FSF gcc, so "#if 0" it out. It should still show up in IDEs that support it 4) Fix some compiler warnings. GCC 4.3.3 seems super strict about %p. function pointers can't be cast to void * either. 5) Avoid a warning for apple_versioning.c that "ISO C does not allow empty files" llvm-svn: 82504
* Update cmake files for arm support hooks.Edward O'Callaghan2009-09-141-1/+1
| | | | llvm-svn: 81760
OpenPOWER on IntegriCloud