diff options
author | NAKAMURA Takumi <geek4civic@gmail.com> | 2014-01-26 12:41:33 +0000 |
---|---|---|
committer | NAKAMURA Takumi <geek4civic@gmail.com> | 2014-01-26 12:41:33 +0000 |
commit | 9def8b2640cfb3d04ab5fdbb560502d5e7ad8617 (patch) | |
tree | 19867fa35bb6b1fdd574b942970d6a24af2cfc3f /cmake | |
parent | 9df203d30ea737e820ceddacebfb7350fa6fe089 (diff) | |
download | llvm-9def8b2640cfb3d04ab5fdbb560502d5e7ad8617.tar.gz llvm-9def8b2640cfb3d04ab5fdbb560502d5e7ad8617.tar.bz2 llvm-9def8b2640cfb3d04ab5fdbb560502d5e7ad8617.tar.xz |
[CMake] Functionalize tblgen().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@200149 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'cmake')
-rw-r--r-- | cmake/modules/TableGen.cmake | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cmake/modules/TableGen.cmake b/cmake/modules/TableGen.cmake index 93f8f8cd01..b1e1549247 100644 --- a/cmake/modules/TableGen.cmake +++ b/cmake/modules/TableGen.cmake @@ -2,7 +2,7 @@ # Extra parameters for `tblgen' may come after `ofn' parameter. # Adds the name of the generated file to TABLEGEN_OUTPUT. -macro(tablegen project ofn) +function(tablegen project ofn) file(GLOB local_tds "*.td") file(GLOB_RECURSE global_tds "${LLVM_MAIN_INCLUDE_DIR}/llvm/*.td") @@ -40,10 +40,10 @@ macro(tablegen project ofn) set_property(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES ${ofn}.tmp ${ofn}) - set(TABLEGEN_OUTPUT ${TABLEGEN_OUTPUT} ${CMAKE_CURRENT_BINARY_DIR}/${ofn}) + set(TABLEGEN_OUTPUT ${TABLEGEN_OUTPUT} ${CMAKE_CURRENT_BINARY_DIR}/${ofn} PARENT_SCOPE) set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/${ofn} PROPERTIES GENERATED 1) -endmacro(tablegen) +endfunction(tablegen) macro(add_public_tablegen_target target) # Creates a target for publicly exporting tablegen dependencies. |