[all-commits] [llvm/llvm-project] ae044c: [CMAKE] Plumb include_directories() into tablegen()
stephenneuendorffer via All-commits
all-commits at lists.llvm.org
Fri Apr 3 10:38:35 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: ae044c5b0caa095602b6ef4cca40d57efc26a8f6
https://github.com/llvm/llvm-project/commit/ae044c5b0caa095602b6ef4cca40d57efc26a8f6
Author: Stephen Neuendorffer <stephen.neuendorffer at xilinx.com>
Date: 2020-04-03 (Fri, 03 Apr 2020)
Changed paths:
M clang/cmake/modules/AddClang.cmake
M llvm/cmake/modules/TableGen.cmake
M mlir/cmake/modules/AddMLIR.cmake
M mlir/examples/toy/Ch3/CMakeLists.txt
M mlir/examples/toy/Ch4/CMakeLists.txt
M mlir/examples/toy/Ch4/include/toy/CMakeLists.txt
M mlir/examples/toy/Ch5/CMakeLists.txt
M mlir/examples/toy/Ch5/include/toy/CMakeLists.txt
M mlir/examples/toy/Ch6/CMakeLists.txt
M mlir/examples/toy/Ch6/include/toy/CMakeLists.txt
M mlir/examples/toy/Ch7/CMakeLists.txt
M mlir/examples/toy/Ch7/include/toy/CMakeLists.txt
Log Message:
-----------
[CMAKE] Plumb include_directories() into tablegen()
Previously, the tablegen() cmake command, which defines custom
commands for running tablegen, included several hardcoded paths. This
becomes unwieldy as there are more users for which these paths are
insufficient. For most targets, cmake uses include_directories() and
the INCLUDE_DIRECTORIES directory property to specify include paths.
This change picks up the INCLUDE_DIRECTORIES property and adds it
to the include path used when running tablegen. As a side effect, this
allows us to remove several hard coded paths to tablegen that are redundant
with specified include_directories().
I haven't removed the hardcoded path to CMAKE_CURRENT_SOURCE_DIR, which
seems generically useful. There are several users in clang which apparently
don't have the current directory as an include_directories(). This could
be considered separately.
Differential Revision: https://reviews.llvm.org/D77156
More information about the All-commits
mailing list