[Lldb-commits] [lldb] r203850 - Fix cmake build issues on Darwin.

Todd Fiala tfiala at google.com
Thu Mar 13 14:16:14 PDT 2014


Author: tfiala
Date: Thu Mar 13 16:16:13 2014
New Revision: 203850

URL: http://llvm.org/viewvc/llvm-project?rev=203850&view=rev
Log:
Fix cmake build issues on Darwin.

Modified:
    lldb/trunk/source/CMakeLists.txt
    lldb/trunk/source/Plugins/JITLoader/CMakeLists.txt
    lldb/trunk/source/Plugins/Process/CMakeLists.txt
    lldb/trunk/tools/debugserver/source/CMakeLists.txt
    lldb/trunk/tools/debugserver/source/MacOSX/CMakeLists.txt
    lldb/trunk/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.cpp
    lldb/trunk/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.h

Modified: lldb/trunk/source/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/CMakeLists.txt?rev=203850&r1=203849&r2=203850&view=diff
==============================================================================
--- lldb/trunk/source/CMakeLists.txt (original)
+++ lldb/trunk/source/CMakeLists.txt Thu Mar 13 16:16:13 2014
@@ -135,6 +135,9 @@ if ( CMAKE_SYSTEM_NAME MATCHES "Darwin"
     lldbPluginProcessMacOSXKernel
     lldbPluginSymbolVendorMacOSX
     lldbPluginSystemRuntimeMacOSX
+    lldbPluginProcessPOSIX
+    lldbPluginProcessElfCore
+    lldbPluginJITLoaderGDB
     )
 endif()
 
@@ -167,6 +170,8 @@ if (NOT LLDB_DISABLE_PYTHON)
   list(APPEND LLDB_SYSTEM_LIBS ${PYTHON_LIBRARIES})
 endif()
 
+list(APPEND LLDB_SYSTEM_LIBS ${system_libs})
+
 set( LLVM_LINK_COMPONENTS
   ${LLVM_TARGETS_TO_BUILD}
   jit

Modified: lldb/trunk/source/Plugins/JITLoader/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/JITLoader/CMakeLists.txt?rev=203850&r1=203849&r2=203850&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/JITLoader/CMakeLists.txt (original)
+++ lldb/trunk/source/Plugins/JITLoader/CMakeLists.txt Thu Mar 13 16:16:13 2014
@@ -1,3 +1,4 @@
-if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "Linux" OR CMAKE_SYSTEM_NAME MATCHES "Windows")
+if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "Linux"
+    OR CMAKE_SYSTEM_NAME MATCHES "Windows" OR CMAKE_SYSTEM_NAME MATCHES "Darwin")
   add_subdirectory(GDB)
 endif()

Modified: lldb/trunk/source/Plugins/Process/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/CMakeLists.txt?rev=203850&r1=203849&r2=203850&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/CMakeLists.txt (original)
+++ lldb/trunk/source/Plugins/Process/CMakeLists.txt Thu Mar 13 16:16:13 2014
@@ -1,16 +1,15 @@
 if (CMAKE_SYSTEM_NAME MATCHES "Linux")
   add_subdirectory(Linux)
   add_subdirectory(POSIX)
-  add_subdirectory(elf-core)
 elseif (CMAKE_SYSTEM_NAME MATCHES "FreeBSD")
   add_subdirectory(FreeBSD)
   add_subdirectory(POSIX)
-  add_subdirectory(elf-core)
 elseif (CMAKE_SYSTEM_NAME MATCHES "Windows")
-  add_subdirectory(elf-core)
 elseif (CMAKE_SYSTEM_NAME MATCHES "Darwin")
+  add_subdirectory(POSIX)
   add_subdirectory(MacOSX-Kernel)
 endif()
 add_subdirectory(gdb-remote)
 add_subdirectory(Utility)
 add_subdirectory(mach-core)
+add_subdirectory(elf-core)

Modified: lldb/trunk/tools/debugserver/source/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/debugserver/source/CMakeLists.txt?rev=203850&r1=203849&r2=203850&view=diff
==============================================================================
--- lldb/trunk/tools/debugserver/source/CMakeLists.txt (original)
+++ lldb/trunk/tools/debugserver/source/CMakeLists.txt Thu Mar 13 16:16:13 2014
@@ -40,6 +40,8 @@ add_library(lldbDebugserverCommon
 add_dependencies(lldbDebugserverCommon generate_dnbconfig)
 
 if (CMAKE_SYSTEM_NAME MATCHES "Darwin")
+  find_library(COCOA_LIBRARY Cocoa)
+  target_link_libraries(lldbDebugserverCommon ${COCOA_LIBRARY})
   add_subdirectory(MacOSX)
 endif()
 

Modified: lldb/trunk/tools/debugserver/source/MacOSX/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/debugserver/source/MacOSX/CMakeLists.txt?rev=203850&r1=203849&r2=203850&view=diff
==============================================================================
--- lldb/trunk/tools/debugserver/source/MacOSX/CMakeLists.txt (original)
+++ lldb/trunk/tools/debugserver/source/MacOSX/CMakeLists.txt Thu Mar 13 16:16:13 2014
@@ -40,6 +40,12 @@ add_lldb_executable(debugserver
   ${generated_mach_interfaces}
   )
 
+set_source_files_properties(
+  HasAVX.s
+  # Necessary since compilation will fail with stand-alone assembler
+  PROPERTIES LANGUAGE C COMPILE_FLAGS "-x assembler-with-cpp"
+  )
+
 add_dependencies(debugserver generate_dnbconfig)
 target_link_libraries(debugserver ${DEBUGSERVER_USED_LIBS})
 

Modified: lldb/trunk/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.cpp?rev=203850&r1=203849&r2=203850&view=diff
==============================================================================
--- lldb/trunk/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.cpp (original)
+++ lldb/trunk/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.cpp Thu Mar 13 16:16:13 2014
@@ -18,6 +18,7 @@
 #include <sys/sysctl.h>
 
 #include "MacOSX/x86_64/DNBArchImplX86_64.h"
+#include "../HasAVX.h"
 #include "DNBLog.h"
 #include "MachThread.h"
 #include "MachProcess.h"

Modified: lldb/trunk/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.h?rev=203850&r1=203849&r2=203850&view=diff
==============================================================================
--- lldb/trunk/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.h (original)
+++ lldb/trunk/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.h Thu Mar 13 16:16:13 2014
@@ -16,7 +16,6 @@
 
 #if defined (__i386__) || defined (__x86_64__)
 #include "DNBArch.h"
-#include "../HasAVX.h"
 #include "MachRegisterStatesX86_64.h"
 
 #include <map>





More information about the lldb-commits mailing list