pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

lldb-netbsd: Fix build after switch to llvm::call_once



Module Name:	pkgsrc-wip
Committed By:	Kamil Rytarowski <n54%gmx.com@localhost>
Pushed By:	kamil
Date:		Sat Jan 28 16:30:41 2017 +0100
Changeset:	a3f2f332b5b7767fdefdc285bbd77b92019f9676

Modified Files:
	lldb-netbsd/distinfo
	lldb-netbsd/patches/patch-source_Core_ModuleList.cpp
	lldb-netbsd/patches/patch-source_Host_common_HostInfoBase.cpp
	lldb-netbsd/patches/patch-source_Plugins_Process_mach-core_ProcessMachCore.cpp

Log Message:
lldb-netbsd: Fix build after switch to llvm::call_once

Fix regular compilation issues on NetBSD. Other targets not tested.

Sponsored by <The NetBSD Foundation>

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=a3f2f332b5b7767fdefdc285bbd77b92019f9676

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 lldb-netbsd/distinfo                               |  6 ++--
 .../patches/patch-source_Core_ModuleList.cpp       | 14 ++++----
 .../patch-source_Host_common_HostInfoBase.cpp      | 38 +++++++++++++---------
 ...e_Plugins_Process_mach-core_ProcessMachCore.cpp | 12 +++++--
 4 files changed, 42 insertions(+), 28 deletions(-)

diffs:
diff --git a/lldb-netbsd/distinfo b/lldb-netbsd/distinfo
index 8cf6e6c..2ad7311 100644
--- a/lldb-netbsd/distinfo
+++ b/lldb-netbsd/distinfo
@@ -21,11 +21,11 @@ SHA1 (patch-source_CMakeLists.txt) = 5dacabc3f39c23bdfd432b5a4895866157b97aa0
 SHA1 (patch-source_Commands_CommandObjectPlatform.cpp) = 41efff0af1f21e42dc7c6291e12698a3585ad743
 SHA1 (patch-source_Core_ConstString.cpp) = 97165809067ed09aeb42395fa352bf7b14cd5afb
 SHA1 (patch-source_Core_Debugger.cpp) = 1548c96130453b7d9623def91057384230cc4ac5
-SHA1 (patch-source_Core_ModuleList.cpp) = e5a0cd12c70b26c397960e94189a4c37495b8f70
+SHA1 (patch-source_Core_ModuleList.cpp) = 2697f6d2c181fe602a56e9fd471f0345c838e0de
 SHA1 (patch-source_Host_CMakeLists.txt) = b7b5fbf2354e05c33c63bf47ffa1ef58f58727ef
 SHA1 (patch-source_Host_common_Editline.cpp) = 33d356079c71e78abe423b338fd5dedbfa2d1c15
 SHA1 (patch-source_Host_common_Host.cpp) = 4d9b4f9ef3c2600c46e5f5d5f1f11aa59f15e87f
-SHA1 (patch-source_Host_common_HostInfoBase.cpp) = 84ef02d17a7a87c86cf30dd83ed2af2d4429dfe2
+SHA1 (patch-source_Host_common_HostInfoBase.cpp) = 42919cd2d5ed702b2930716114efba81951421c6
 SHA1 (patch-source_Host_common_NativeProcessProtocol.cpp) = 23cc7da280b2123cf0206f3d5660d2647935edbc
 SHA1 (patch-source_Host_linux_HostInfoLinux.cpp) = 87c56f543d8ced086439db729d1d06cf3667d6b1
 SHA1 (patch-source_Host_netbsd_HostInfoNetBSD.cpp) = fd4035ec03f08ebba0c9f81e5a05939da436ec58
@@ -60,7 +60,7 @@ SHA1 (patch-source_Plugins_Process_elf-core_ProcessElfCore.cpp) = b4cb6dfb073a33
 SHA1 (patch-source_Plugins_Process_gdb-remote_GDBRemoteCommunicationServerPlatform.cpp) = 3282168834ca689c4b2b3a022ab2e4320772eec4
 SHA1 (patch-source_Plugins_Process_gdb-remote_ProcessGDBRemote.cpp) = a801891e542934ffe39d837d50fc8d7316774a8e
 SHA1 (patch-source_Plugins_Process_gdb-remote_ProcessGDBRemoteLog.cpp) = 7e6877baa38faf81130e403e98452a505d940f54
-SHA1 (patch-source_Plugins_Process_mach-core_ProcessMachCore.cpp) = 74a9e7be3a9e33bb18017af1720ebe0b74d4bc7a
+SHA1 (patch-source_Plugins_Process_mach-core_ProcessMachCore.cpp) = 5660588507f211005f2f866784cc5f5cc86af7bf
 SHA1 (patch-source_Plugins_Process_minidump_ProcessMinidump.cpp) = cab0af49ee18dd69cc66b92d20f6c2defae92dae
 SHA1 (patch-source_Plugins_ScriptInterpreter_None_ScriptInterpreterNone.cpp) = e24000a7a5a959c40a54c9623e5c2edb3cd4fea9
 SHA1 (patch-source_Plugins_ScriptInterpreter_Python_ScriptInterpreterPython.cpp) = f05df4842751fa76a358723b970a5050fb2c39da
diff --git a/lldb-netbsd/patches/patch-source_Core_ModuleList.cpp b/lldb-netbsd/patches/patch-source_Core_ModuleList.cpp
index 030c2f8..6adbdfe 100644
--- a/lldb-netbsd/patches/patch-source_Core_ModuleList.cpp
+++ b/lldb-netbsd/patches/patch-source_Core_ModuleList.cpp
@@ -2,21 +2,19 @@ $NetBSD$
 
 --- source/Core/ModuleList.cpp.orig	2016-12-17 10:30:30.000000000 +0000
 +++ source/Core/ModuleList.cpp
-@@ -1,4 +1,4 @@
--//===-- ModuleList.cpp ------------------------------------------*- C++ -*-===//
-+~//===-- ModuleList.cpp ------------------------------------------*- C++ -*-===//
- //
- //                     The LLVM Compiler Infrastructure
- //
-@@ -28,6 +28,7 @@
+@@ -26,8 +26,11 @@
+ #include "lldb/Symbol/SymbolFile.h"
+ #include "lldb/Symbol/VariableList.h"
  
++#include "llvm/Support/Threading.h"
++
  using namespace lldb;
  using namespace lldb_private;
 +using namespace llvm;
  
  ModuleList::ModuleList()
      : m_modules(), m_modules_mutex(), m_notifier(nullptr) {}
-@@ -644,8 +645,8 @@ size_t ModuleList::GetIndexForModule(con
+@@ -644,8 +647,8 @@ size_t ModuleList::GetIndexForModule(con
  
  static ModuleList &GetSharedModuleList() {
    static ModuleList *g_shared_module_list = nullptr;
diff --git a/lldb-netbsd/patches/patch-source_Host_common_HostInfoBase.cpp b/lldb-netbsd/patches/patch-source_Host_common_HostInfoBase.cpp
index f169885..6fe5d64 100644
--- a/lldb-netbsd/patches/patch-source_Host_common_HostInfoBase.cpp
+++ b/lldb-netbsd/patches/patch-source_Host_common_HostInfoBase.cpp
@@ -2,7 +2,15 @@ $NetBSD$
 
 --- source/Host/common/HostInfoBase.cpp.orig	2016-12-17 10:30:38.000000000 +0000
 +++ source/Host/common/HostInfoBase.cpp
-@@ -29,6 +29,7 @@
+@@ -22,6 +22,7 @@
+ #include "llvm/Support/Host.h"
+ #include "llvm/Support/Path.h"
+ #include "llvm/Support/ScopedPrinter.h"
++#include "llvm/Support/Threading.h"
+ #include "llvm/Support/raw_ostream.h"
+ 
+ #include <mutex> // std::once
+@@ -29,6 +30,7 @@
  
  using namespace lldb;
  using namespace lldb_private;
@@ -10,7 +18,7 @@ $NetBSD$
  
  namespace {
  //----------------------------------------------------------------------
-@@ -79,8 +80,8 @@ void HostInfoBase::Terminate() {
+@@ -79,8 +81,8 @@ void HostInfoBase::Terminate() {
  }
  
  uint32_t HostInfoBase::GetNumberCPUS() {
@@ -21,7 +29,7 @@ $NetBSD$
      g_fields->m_number_cpus = std::thread::hardware_concurrency();
    });
    return g_fields->m_number_cpus;
-@@ -89,8 +90,8 @@ uint32_t HostInfoBase::GetNumberCPUS() {
+@@ -89,8 +91,8 @@ uint32_t HostInfoBase::GetNumberCPUS() {
  uint32_t HostInfoBase::GetMaxThreadNameLength() { return 0; }
  
  llvm::StringRef HostInfoBase::GetVendorString() {
@@ -32,7 +40,7 @@ $NetBSD$
      g_fields->m_vendor_string =
          HostInfo::GetArchitecture().GetTriple().getVendorName().str();
    });
-@@ -98,8 +99,8 @@ llvm::StringRef HostInfoBase::GetVendorS
+@@ -98,8 +100,8 @@ llvm::StringRef HostInfoBase::GetVendorS
  }
  
  llvm::StringRef HostInfoBase::GetOSString() {
@@ -43,7 +51,7 @@ $NetBSD$
      g_fields->m_os_string =
          std::move(HostInfo::GetArchitecture().GetTriple().getOSName());
    });
-@@ -107,8 +108,8 @@ llvm::StringRef HostInfoBase::GetOSStrin
+@@ -107,8 +109,8 @@ llvm::StringRef HostInfoBase::GetOSStrin
  }
  
  llvm::StringRef HostInfoBase::GetTargetTriple() {
@@ -54,7 +62,7 @@ $NetBSD$
      g_fields->m_host_triple =
          HostInfo::GetArchitecture().GetTriple().getTriple();
    });
-@@ -116,8 +117,8 @@ llvm::StringRef HostInfoBase::GetTargetT
+@@ -116,8 +118,8 @@ llvm::StringRef HostInfoBase::GetTargetT
  }
  
  const ArchSpec &HostInfoBase::GetArchitecture(ArchitectureKind arch_kind) {
@@ -65,7 +73,7 @@ $NetBSD$
      HostInfo::ComputeHostArchitectureSupport(g_fields->m_host_arch_32,
                                               g_fields->m_host_arch_64);
    });
-@@ -144,9 +145,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
+@@ -144,9 +146,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
    FileSpec *result = nullptr;
    switch (type) {
    case lldb::ePathTypeLLDBShlibDir: {
@@ -77,7 +85,7 @@ $NetBSD$
        success =
            HostInfo::ComputeSharedLibraryDirectory(g_fields->m_lldb_so_dir);
        Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST);
-@@ -158,9 +159,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
+@@ -158,9 +160,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
        result = &g_fields->m_lldb_so_dir;
    } break;
    case lldb::ePathTypeSupportExecutableDir: {
@@ -89,7 +97,7 @@ $NetBSD$
        success = HostInfo::ComputeSupportExeDirectory(
            g_fields->m_lldb_support_exe_dir);
        Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST);
-@@ -173,9 +174,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
+@@ -173,9 +175,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
        result = &g_fields->m_lldb_support_exe_dir;
    } break;
    case lldb::ePathTypeHeaderDir: {
@@ -101,7 +109,7 @@ $NetBSD$
        success = HostInfo::ComputeHeaderDirectory(g_fields->m_lldb_headers_dir);
        Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST);
        if (log)
-@@ -186,9 +187,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
+@@ -186,9 +188,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
        result = &g_fields->m_lldb_headers_dir;
    } break;
    case lldb::ePathTypePythonDir: {
@@ -113,7 +121,7 @@ $NetBSD$
        success = HostInfo::ComputePythonDirectory(g_fields->m_lldb_python_dir);
        Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST);
        if (log)
-@@ -199,9 +200,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
+@@ -199,9 +201,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
        result = &g_fields->m_lldb_python_dir;
    } break;
    case lldb::ePathTypeClangDir: {
@@ -125,7 +133,7 @@ $NetBSD$
        success =
            HostInfo::ComputeClangDirectory(g_fields->m_lldb_clang_resource_dir);
        Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST);
-@@ -214,9 +215,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
+@@ -214,9 +216,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
        result = &g_fields->m_lldb_clang_resource_dir;
    } break;
    case lldb::ePathTypeLLDBSystemPlugins: {
@@ -137,7 +145,7 @@ $NetBSD$
        success = HostInfo::ComputeSystemPluginsDirectory(
            g_fields->m_lldb_system_plugin_dir);
        Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST);
-@@ -229,9 +230,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
+@@ -229,9 +231,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
        result = &g_fields->m_lldb_system_plugin_dir;
    } break;
    case lldb::ePathTypeLLDBUserPlugins: {
@@ -149,7 +157,7 @@ $NetBSD$
        success = HostInfo::ComputeUserPluginsDirectory(
            g_fields->m_lldb_user_plugin_dir);
        Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST);
-@@ -244,9 +245,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
+@@ -244,9 +246,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
        result = &g_fields->m_lldb_user_plugin_dir;
    } break;
    case lldb::ePathTypeLLDBTempSystemDir: {
@@ -161,7 +169,7 @@ $NetBSD$
        success = HostInfo::ComputeProcessTempFileDirectory(
            g_fields->m_lldb_process_tmp_dir);
        Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST);
-@@ -259,9 +260,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
+@@ -259,9 +261,9 @@ bool HostInfoBase::GetLLDBPath(lldb::Pat
        result = &g_fields->m_lldb_process_tmp_dir;
    } break;
    case lldb::ePathTypeGlobalLLDBTempSystemDir: {
diff --git a/lldb-netbsd/patches/patch-source_Plugins_Process_mach-core_ProcessMachCore.cpp b/lldb-netbsd/patches/patch-source_Plugins_Process_mach-core_ProcessMachCore.cpp
index af19488..caf174d 100644
--- a/lldb-netbsd/patches/patch-source_Plugins_Process_mach-core_ProcessMachCore.cpp
+++ b/lldb-netbsd/patches/patch-source_Plugins_Process_mach-core_ProcessMachCore.cpp
@@ -2,7 +2,15 @@ $NetBSD$
 
 --- source/Plugins/Process/mach-core/ProcessMachCore.cpp.orig	2016-12-17 10:30:06.000000000 +0000
 +++ source/Plugins/Process/mach-core/ProcessMachCore.cpp
-@@ -45,6 +45,7 @@
+@@ -39,12 +39,15 @@
+ // Needed for the plug-in names for the dynamic loaders.
+ #include "lldb/Utility/SafeMachO.h"
+ 
++#include "llvm/Support/Threading.h"
++
+ #include "Plugins/DynamicLoader/Darwin-Kernel/DynamicLoaderDarwinKernel.h"
+ #include "Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.h"
+ #include "Plugins/ObjectFile/Mach-O/ObjectFileMachO.h"
  
  using namespace lldb;
  using namespace lldb_private;
@@ -10,7 +18,7 @@ $NetBSD$
  
  ConstString ProcessMachCore::GetPluginNameStatic() {
    static ConstString g_name("mach-o-core");
-@@ -579,9 +580,9 @@ Error ProcessMachCore::GetMemoryRegionIn
+@@ -579,9 +582,9 @@ Error ProcessMachCore::GetMemoryRegionIn
  void ProcessMachCore::Clear() { m_thread_list.Clear(); }
  
  void ProcessMachCore::Initialize() {


Home | Main Index | Thread Index | Old Index