Author: teemperor
Date: Fri Oct  4 02:52:26 2019
New Revision: 373723

URL: http://llvm.org/viewvc/llvm-project?rev=373723&view=rev
Log:
[lldb] Fix that 'ninja clean' breaks the build by deleting debugserver_vers.c

Summary:
We mark debugserver_vers.c as a generated file in CMake. This means that when 
we run `ninja clean` we end up deleting that file,
but any following `ninja` invocation will fail due to the file missing. The 
file can't be generated as `ninja` doesn't know it has to
rerun CMake to create the file. Turns out that marking the output of 
configure_file as generated is wrong as explained in this bug report:
https://gitlab.kitware.com/cmake/cmake/issues/18032

This patch just removes that property. The only side effect of this seems to be 
that this file maybe shows up in your IDE when
opening our CMake project, but that seems like a small sacrifice.

This patch can be quickly tested by running `ninja clean ; ninja 
lldbDebugserverCommon`. Before this patch the build will fail
due to debugserver_vers.c missing.

Reviewers: JDevlieghere, labath

Reviewed By: labath

Subscribers: mgorny, abidh, lldb-commits

Tags: #lldb

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

Modified:
    lldb/trunk/tools/debugserver/source/CMakeLists.txt

Modified: lldb/trunk/tools/debugserver/source/CMakeLists.txt
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/debugserver/source/CMakeLists.txt?rev=373723&r1=373722&r2=373723&view=diff
==============================================================================
--- lldb/trunk/tools/debugserver/source/CMakeLists.txt (original)
+++ lldb/trunk/tools/debugserver/source/CMakeLists.txt Fri Oct  4 02:52:26 2019
@@ -136,7 +136,6 @@ add_custom_command(OUTPUT ${generated_ma
   )
 
 set(DEBUGSERVER_VERS_GENERATED_FILE 
${CMAKE_CURRENT_BINARY_DIR}/debugserver_vers.c)
-set_source_files_properties(${DEBUGSERVER_VERS_GENERATED_FILE} PROPERTIES 
GENERATED 1)
 configure_file(debugserver_vers.c.in
                ${DEBUGSERVER_VERS_GENERATED_FILE} @ONLY)
 


_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to