[libc-commits] [libc] r374925 - [libc] Do not add unittests if LLVM_INCLUDE_TESTS is OFF.

Siva Chandra via libc-commits libc-commits at lists.llvm.org
Tue Oct 15 10:42:28 PDT 2019


Author: sivachandra
Date: Tue Oct 15 10:42:28 2019
New Revision: 374925

URL: http://llvm.org/viewvc/llvm-project?rev=374925&view=rev
Log:
[libc] Do not add unittests if LLVM_INCLUDE_TESTS is OFF.

Reviewers: nathanchance

Subscribers: mgorny, tschuett, libc-commits

Tags: #libc-project

Differential Revision: https://reviews.llvm.org/D68726

Modified:
    libc/trunk/cmake/modules/LLVMLibCRules.cmake

Modified: libc/trunk/cmake/modules/LLVMLibCRules.cmake
URL: http://llvm.org/viewvc/llvm-project/libc/trunk/cmake/modules/LLVMLibCRules.cmake?rev=374925&r1=374924&r2=374925&view=diff
==============================================================================
--- libc/trunk/cmake/modules/LLVMLibCRules.cmake (original)
+++ libc/trunk/cmake/modules/LLVMLibCRules.cmake Tue Oct 15 10:42:28 2019
@@ -220,6 +220,10 @@ function(add_entrypoint_library target_n
 endfunction(add_entrypoint_library)
 
 function(add_libc_unittest target_name)
+  if(NOT LLVM_INCLUDE_TESTS)
+    return()
+  endif()
+
   cmake_parse_arguments(
     "LIBC_UNITTEST"
     "" # No optional arguments




More information about the libc-commits mailing list