OSDN Git Service

[UI][Qt] Remove unneeded Qt classes from GUI.
[csp-qt/common_source_project-fm7.git] / doc / cotire / Patches / llvm-3.3.src.patch
1 diff -rupN llvm-3.3.src/CMakeLists.txt llvm-3.3.src.cotire/CMakeLists.txt
2 --- llvm-3.3.src/CMakeLists.txt 2013-05-06 18:23:07.000000000 +0200
3 +++ llvm-3.3.src.cotire/CMakeLists.txt  2013-10-13 10:05:20.000000000 +0200
4 @@ -1,7 +1,7 @@
5  # See docs/CMake.html for instructions about how to build LLVM with CMake.
6  
7  project(LLVM)
8 -cmake_minimum_required(VERSION 2.8)
9 +cmake_minimum_required(VERSION 2.8.11)
10  
11  # Add path for custom modules
12  set(CMAKE_MODULE_PATH
13 @@ -21,6 +21,8 @@ if ( LLVM_USE_FOLDERS )
14  endif()
15  
16  include(VersionFromVCS)
17 +include(cotire)
18 +set_property(DIRECTORY PROPERTY COTIRE_UNITY_LINK_LIBRARIES_INIT "COPY_UNITY")
19  
20  option(LLVM_APPEND_VC_REV
21    "Append the version control system revision id to LLVM version" OFF)
22 @@ -187,7 +189,7 @@ option(LLVM_USE_OPROFILE
23  # If enabled, verify we are on a platform that supports oprofile.
24  if( LLVM_USE_OPROFILE )
25    if( NOT CMAKE_SYSTEM_NAME MATCHES "Linux" )
26 -    message(FATAL_ERROR "OProfile support is available on Linux only.") 
27 +    message(FATAL_ERROR "OProfile support is available on Linux only.")
28    endif( NOT CMAKE_SYSTEM_NAME MATCHES "Linux" )
29  endif( LLVM_USE_OPROFILE )
30  
31 diff -rupN llvm-3.3.src/cmake/modules/AddLLVM.cmake llvm-3.3.src.cotire/cmake/modules/AddLLVM.cmake
32 --- llvm-3.3.src/cmake/modules/AddLLVM.cmake    2013-04-21 11:04:59.000000000 +0200
33 +++ llvm-3.3.src.cotire/cmake/modules/AddLLVM.cmake     2013-10-13 10:43:04.000000000 +0200
34 @@ -34,6 +34,10 @@ macro(add_llvm_library name)
35    # property has been set to an empty value.
36    get_property(lib_deps GLOBAL PROPERTY LLVMBUILD_LIB_DEPS_${name})
37    target_link_libraries(${name} ${lib_deps})
38 +if (COMMAND cotire)
39 +  set_target_properties(${name} PROPERTIES COTIRE_UNITY_SOURCE_POST_UNDEFS "DEBUG_TYPE")
40 +  cotire(${name})
41 +endif()
42  endmacro(add_llvm_library name)
43  
44  macro(add_llvm_loadable_module name)
45 @@ -69,6 +73,10 @@ ${name} ignored.")
46          LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX}
47          ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX})
48      endif()
49 +if (COMMAND cotire)
50 +  set_target_properties(${name} PROPERTIES COTIRE_UNITY_SOURCE_POST_UNDEFS "DEBUG_TYPE")
51 +  cotire(${name})
52 +endif()
53    endif()
54  
55    set_target_properties(${name} PROPERTIES FOLDER "Loadable modules")
56 @@ -101,6 +109,10 @@ macro(add_llvm_tool name)
57      install(TARGETS ${name} RUNTIME DESTINATION bin)
58    endif()
59    set_target_properties(${name} PROPERTIES FOLDER "Tools")
60 +if (COMMAND cotire)
61 +  set_target_properties(${name} PROPERTIES COTIRE_UNITY_SOURCE_POST_UNDEFS "DEBUG_TYPE")
62 +  cotire(${name})
63 +endif()
64  endmacro(add_llvm_tool name)
65  
66  
67 @@ -114,12 +126,20 @@ macro(add_llvm_example name)
68      install(TARGETS ${name} RUNTIME DESTINATION examples)
69    endif()
70    set_target_properties(${name} PROPERTIES FOLDER "Examples")
71 +if (COMMAND cotire)
72 +  set_target_properties(${name} PROPERTIES COTIRE_UNITY_SOURCE_POST_UNDEFS "DEBUG_TYPE")
73 +  cotire(${name})
74 +endif()
75  endmacro(add_llvm_example name)
76  
77  
78  macro(add_llvm_utility name)
79    add_llvm_executable(${name} ${ARGN})
80    set_target_properties(${name} PROPERTIES FOLDER "Utils")
81 +if (COMMAND cotire)
82 +  set_target_properties(${name} PROPERTIES COTIRE_UNITY_SOURCE_POST_UNDEFS "DEBUG_TYPE")
83 +  cotire(${name})
84 +endif()
85  endmacro(add_llvm_utility name)
86  
87  
88 @@ -198,6 +218,10 @@ function(add_unittest test_suite test_na
89      set(target_compile_flags "${target_compile_flags} -Wno-variadic-macros")
90    endif ()
91    set_property(TARGET ${test_name} PROPERTY COMPILE_FLAGS "${target_compile_flags}")
92 +if (COMMAND cotire)
93 +  set_target_properties(${name} PROPERTIES COTIRE_UNITY_SOURCE_POST_UNDEFS "DEBUG_TYPE")
94 +  cotire(${name})
95 +endif()
96  endfunction()
97  
98  # This function provides an automatic way to 'configure'-like generate a file
99 diff -rupN llvm-3.3.src/include/llvm/Transforms/Utils/BlackList.h llvm-3.3.src.cotire/include/llvm/Transforms/Utils/BlackList.h
100 --- llvm-3.3.src/include/llvm/Transforms/Utils/BlackList.h      2013-04-11 15:20:00.000000000 +0200
101 +++ llvm-3.3.src.cotire/include/llvm/Transforms/Utils/BlackList.h       2013-10-13 11:52:41.000000000 +0200
102 @@ -30,6 +30,9 @@
103  //===----------------------------------------------------------------------===//
104  //
105  
106 +#ifndef LLVM_TRANSFORMS_UTILS_BLACKLIST_H
107 +#define LLVM_TRANSFORMS_UTILS_BLACKLIST_H
108 +
109  #include "llvm/ADT/StringMap.h"
110  
111  namespace llvm {
112 @@ -57,3 +60,5 @@ class BlackList {
113  };
114  
115  }  // namespace llvm
116 +
117 +#endif
118 diff -rupN llvm-3.3.src/lib/Support/CMakeLists.txt llvm-3.3.src.cotire/lib/Support/CMakeLists.txt
119 --- llvm-3.3.src/lib/Support/CMakeLists.txt     2013-04-23 10:28:39.000000000 +0200
120 +++ llvm-3.3.src.cotire/lib/Support/CMakeLists.txt      2013-10-13 10:25:45.000000000 +0200
121 @@ -1,3 +1,7 @@
122 +if (COMMAND cotire)
123 +       set_source_files_properties (IsInf.cpp IsNAN.cpp PROPERTIES COTIRE_EXCLUDED TRUE)
124 +endif()
125 +
126  add_llvm_library(LLVMSupport
127    APFloat.cpp
128    APInt.cpp