[libc-commits] [libc] [libc][NFC] Remove incorrect file level dependency in CMake (PR #132937)

via libc-commits libc-commits at lists.llvm.org
Tue Mar 25 07:27:48 PDT 2025


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-libc

Author: Joseph Huber (jhuber6)

<details>
<summary>Changes</summary>

Summary:
CMake doesn't support this type of dependency so it keeps emitting a
warning. Just remove it, because it's not doing anything currently
anyway. If we really wanted this to work you'd need to add a custom
target that has a dependency on the output of a custom command, but that
would only be worhwhile if we ever expected this file to change.


---
Full diff: https://github.com/llvm/llvm-project/pull/132937.diff


1 Files Affected:

- (modified) libc/test/src/__support/CMakeLists.txt (-3) 


``````````diff
diff --git a/libc/test/src/__support/CMakeLists.txt b/libc/test/src/__support/CMakeLists.txt
index 8d175e857fcd1..8cb99f19df0c3 100644
--- a/libc/test/src/__support/CMakeLists.txt
+++ b/libc/test/src/__support/CMakeLists.txt
@@ -267,12 +267,9 @@ if(NOT LIBC_TARGET_OS_IS_GPU)
     str_to_float_comparison_test.cpp
   )
 
-  set(float_test_file ${CMAKE_CURRENT_SOURCE_DIR}/str_to_float_comparison_data.txt)
-
   add_custom_command(TARGET libc_str_to_float_comparison_test
                      POST_BUILD
                      COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $<TARGET_FILE:libc_str_to_float_comparison_test> ${float_test_file}
-                     DEPENDS ${float_test_file}
                      COMMENT "Test the strtof and strtod implementations against precomputed results."
                      VERBATIM)
 endif()

``````````

</details>


https://github.com/llvm/llvm-project/pull/132937


More information about the libc-commits mailing list