From e46b2e5b14fab7f6f165598db5b944e67101ab00 Mon Sep 17 00:00:00 2001 From: Chris Bieneman Date: Fri, 5 Feb 2016 03:02:40 +0000 Subject: [PATCH] [CMake] One more try to fix this. This change will catch any bots that generated the order file that GNU ld doesn't like and delete it before trying to generate one that I think GNU ld will deal with. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@259871 91177308-0d34-0410-b5e6-96231b3b80d8 --- CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 514cea16ff..bdd0ec9124 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -595,6 +595,11 @@ endif() set(CLANG_ORDER_FILE ${CMAKE_CURRENT_BINARY_DIR}/clang.order CACHE FILEPATH "Order file to use when compiling clang in order to improve startup time.") +file(READ ${CLANG_ORDER_FILE} order_file 20) +if(order_file STREQUAL "") + file(REMOVE ${CLANG_ORDER_FILE}) +endif() + if(CLANG_ORDER_FILE AND NOT EXISTS ${CLANG_ORDER_FILE}) file(WRITE ${CLANG_ORDER_FILE} "\n") endif() -- 2.40.0