summaryrefslogtreecommitdiffstats
path: root/llvm/cmake/modules/LLVMExternalProjectUtils.cmake
Commit message (Collapse)AuthorAgeFilesLines
* [CMake] Multi-target builtins buildPetr Hosek2016-12-121-0/+9
| | | | | | | | | | | | | | This change enables building builtins for multiple different targets using LLVM runtimes directory. To specify the builtin targets to be built, use the LLVM_BUILTIN_TARGETS variable, where the value is the list of targets. To pass a per target variable to the builtin build, you can set BUILTINS_<target>_<variable> where <variable> will be passed to the builtin build for <target>. Differential Revision: https://reviews.llvm.org/D26652 llvm-svn: 289491
* [CMake] Cleanup LLVM_OPTIMIZED_TABLEGENChris Bieneman2016-09-061-2/+6
| | | | | | | | | | This cleanup removes the need for the native support library to have its own target. That target was only needed because makefile builds were tripping over each other if two tablegen targets were building at the same time. This causes problems because the parallel make invocations through CMake can't communicate with each other. This is fixed by invoking make directly instead of through CMake which is how we handle this in External Project invocations. The other part of the cleanup is to mark the custom commands as USES_TERMINAL. This is a bit of a hack, but we need to ensure that Ninja generators don't invoke multiple tablegen targets in the same build dir in parallel, because that too would be bad. Marking as USES_TERMINAL does have some downside for Ninja because it results in decreased parallelism, but correct builds are worth the minor loss and LLVM_OPTIMZIED_TABLEGEN is such a huge win, it is worth it. llvm-svn: 280748
* [CMake] Make llvm-config implicit dependency for subprojectsChris Bieneman2016-08-181-1/+1
| | | | | | | | The subproject interface being used for runtime libraries expects that llvm-config is passed into the subproject for consumption. We currently do this for every subproject, so we should expect that all LLVM ExternalProjects depend on llvm-config for the time being. Eventually I'd like to see the sub-projects using LLVMConfig.cmake instead of the llvm-config binary, but that will take time to roll out. llvm-svn: 279155
* [CMake] Add LLVM runtimes directoryChris Bieneman2016-06-231-10/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: There are a few LLVM projects that produce runtime libraries. Ideally runtime libraries should be built differently than other projects, specifically they should be built using the just-built toolchain. There is support for building compiler-rt in this way from the clang build. Moving this logic into the LLVM build is interesting because it provides a simpler way to extend the just-built toolchain to include LLD and the LLVM object file tools. Once this functionality is better fleshed out and tested we’ll want to encapsulate it in a module that can be used for clang standalone builds, and we’ll want to make it the default way to build compiler-rt. With this patch applied there is no immediate change in the build. Moving compiler-rt out from llvm/projects into llvm/runtimes enables the functionality. This code has a few improvements over the method provided by LLVM_BUILD_EXTERNAL_COMPILER_RT. Specifically the sub-ninja command is always invoked, so changes to compiler-rt source files will get built properly, so this patch can be used for iterative development with just-built tools. This first patch only works with compiler-rt. Support for other runtime projects will be coming in follow-up patches. Reviewers: chandlerc, bogner Subscribers: kubabrecka, llvm-commits Differential Revision: http://reviews.llvm.org/D20992 llvm-svn: 273620
* [CMake] Removing fallback code for CMake versions before 3.1Chris Bieneman2016-06-091-14/+0
| | | | | | This code is dead code now. Out with the old, in with the new! llvm-svn: 272347
* [CMake] Cleanup ExternalProject usage of CMake 3.x featuresChris Bieneman2016-06-091-19/+7
| | | | | | All the ExternalProject features in use here are supported by CMake 3.4.3, so we don't need these version checks anymore. llvm-svn: 272327
* [CMake] Cleanup uses of USES_TERMINALChris Bieneman2016-06-081-7/+3
| | | | | | Now that we are on CMake 3.4.3 we no longer need a version check around this. llvm-svn: 272211
* [CMake] Make llvm_ExternalProject always call the build actionChris Bieneman2016-04-081-9/+17
| | | | | | | | This makes it so that when running 'ninja test-suite' from the top-level LLVM ninja build it *always* re-runs the ninja command in the test-suite directory. This mechanism is required because the top-level ninja file doesn't have a view into the subdirectory dependency tree, so it can't know what, if anything, needs to be rebuilt. llvm-svn: 265863
* [CMake] Removing an unnecessary layer of variable indirectionChris Bieneman2015-12-031-1/+1
| | | | | | This prevents passthrough variables from having values. llvm-svn: 254641
* NFC. Fixing my consistently incorrect spelling.Chris Bieneman2015-11-231-4/+4
| | | | llvm-svn: 253936
* [CMake] Fix handling of passing through semi-colon separated lists.Chris Bieneman2015-11-201-1/+2
| | | | | | When passing around CMake arguments as lists of arguments any arguments containing lists need to have their semi-colons escaped otherwise CMake will split the arguments in the middle. llvm-svn: 253719
* [CMake] Fixing passthrough for variables starting with the sub-project nameChris Bieneman2015-11-111-1/+1
| | | | | | This allows TEST_SUITE variables to be passed from the top-level CMake into the external project. llvm-svn: 252810
* [CMake] Add support for building the llvm test-suite as part of an LLVM ↵Chris Bieneman2015-11-111-0/+194
build using clang and lld Summary: This patch adds a new CMake module for working with ExternalProjects. This wrapper for ExternalProject supports using just-built tools and can hook up dependencies properly so that projects get cleared out. The example usage here is for the llvm test-suite. In this example, the test-suite is setup as dependent on clang and lld if they are in-tree. If the clang or lld binaries change the test-suite is re-configured, cleaned, and rebuilt. This cleanup and abstraction wrapping ExternalProject can be extended and applied to other runtime libraries like compiler-rt and libcxx. Reviewers: samsonov, jroelofs, rengolin, jmolloy Subscribers: jmolloy, llvm-commits Differential Revision: http://reviews.llvm.org/D14513 llvm-svn: 252747
OpenPOWER on IntegriCloud