Index: cmake/LLDBDependencies.cmake =================================================================== --- cmake/LLDBDependencies.cmake +++ cmake/LLDBDependencies.cmake @@ -37,6 +37,7 @@ lldbPluginPlatformFreeBSD lldbPluginPlatformKalimba lldbPluginPlatformLinux + lldbPluginPlatformNetBSD lldbPluginPlatformPOSIX lldbPluginPlatformWindows lldbPluginObjectContainerMachOArchive @@ -102,6 +103,13 @@ ) endif () +# NetBSD-only libraries +if ( CMAKE_SYSTEM_NAME MATCHES "NetBSD" ) + list(APPEND LLDB_USED_LIBS + lldbPluginProcessPOSIX + ) +endif () + # Darwin-only libraries if ( CMAKE_SYSTEM_NAME MATCHES "Darwin" ) list(APPEND LLDB_USED_LIBS Index: cmake/modules/LLDBConfig.cmake =================================================================== --- cmake/modules/LLDBConfig.cmake +++ cmake/modules/LLDBConfig.cmake @@ -377,7 +377,8 @@ # ensure we build lldb-server when an lldb target is being built. if ((CMAKE_SYSTEM_NAME MATCHES "Darwin") OR (CMAKE_SYSTEM_NAME MATCHES "FreeBSD") OR - (CMAKE_SYSTEM_NAME MATCHES "Linux")) + (CMAKE_SYSTEM_NAME MATCHES "Linux") OR + (CMAKE_SYSTEM_NAME MATCHES "NetBSD")) set(LLDB_CAN_USE_LLDB_SERVER 1) else() set(LLDB_CAN_USE_LLDB_SERVER 0) Index: scripts/buildSwigWrapperClasses.py =================================================================== --- scripts/buildSwigWrapperClasses.py +++ scripts/buildSwigWrapperClasses.py @@ -414,6 +414,25 @@ return (bExeFileFound, strStatusMsg); #++--------------------------------------------------------------------------- +# Details: Locate the SWIG executable file in a NetBSD system. Several hard +# coded predetermined possible file path locations are searched. +# (This is good candidate for a derived class object) +# Args: vDictArgs - (W) Program input parameters. +# Returns: Bool - True = Success. +# - False = Failure file not found. +# Str - Error message. +# Throws: None. +#-- +def check_lldb_swig_executable_file_exists_NetBSD( vDictArgs ): + dbg = utilsDebug.CDebugFnVerbose( "check_lldb_swig_executable_file_exists_NetBSD()" ); + bExeFileFound = False; + # ToDo: Find the SWIG executable and add the path to the args dictionary + #vDictArgs.[ "--swigExePath" ] = "/usr/bin/swig"; + strStatusMsg = "Sorry function 'check_lldb_swig_executable_file_exists_NetBSD()' is not implemented"; + + return (bExeFileFound, strStatusMsg); + +#++--------------------------------------------------------------------------- # Details: Locate the SWIG executable file. Several hard coded predetermined # possible file path locations are searched. # Args: vDictArgs - (RW) Program input parameters. @@ -437,6 +456,7 @@ EnumOsType.Darwin : check_lldb_swig_executable_file_exists_Darwin, EnumOsType.FreeBSD : check_lldb_swig_executable_file_exists_FreeBSD, EnumOsType.Linux : check_lldb_swig_executable_file_exists_Linux, + EnumOsType.NetBSD : check_lldb_swig_executable_file_exists_NetBSD, EnumOsType.Windows : check_lldb_swig_executable_file_exists_Windows } bExeFileFound, strStatusMsg = switch[ veOSType ]( vDictArgs ); return (bExeFileFound, strStatusMsg); Index: source/Initialization/SystemInitializerCommon.cpp =================================================================== --- source/Initialization/SystemInitializerCommon.cpp +++ source/Initialization/SystemInitializerCommon.cpp @@ -34,6 +34,7 @@ #include "Plugins/Platform/MacOSX/PlatformiOSSimulator.h" #include "Plugins/Platform/MacOSX/PlatformMacOSX.h" #include "Plugins/Platform/MacOSX/PlatformRemoteiOS.h" +#include "Plugins/Platform/NetBSD/PlatformNetBSD.h" #include "Plugins/Platform/Windows/PlatformWindows.h" #include "Plugins/Process/gdb-remote/ProcessGDBRemoteLog.h" Index: source/lldb.cpp =================================================================== --- source/lldb.cpp +++ source/lldb.cpp @@ -67,7 +67,7 @@ return g_version_string; #else - // On Linux/FreeBSD/Windows, report a version number in the same style as the clang tool. + // On platforms other than Darwin, report a version number in the same style as the clang tool. static std::string g_version_str; if (g_version_str.empty()) { Index: tools/Makefile =================================================================== --- tools/Makefile +++ tools/Makefile @@ -13,7 +13,7 @@ DIRS := # enable lldb-gdbserver for supported platforms -ifneq (,$(strip $(filter $(HOST_OS), FreeBSD Linux GNU/kFreeBSD))) +ifneq (,$(strip $(filter $(HOST_OS), FreeBSD Linux NetBSD GNU/kFreeBSD))) DIRS += lldb-server endif Index: tools/lldb-mi/CMakeLists.txt =================================================================== --- tools/lldb-mi/CMakeLists.txt +++ tools/lldb-mi/CMakeLists.txt @@ -76,7 +76,7 @@ Platform.cpp ) -if ( CMAKE_SYSTEM_NAME MATCHES "Windows" ) +if ( CMAKE_SYSTEM_NAME MATCHES "Windows" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD" ) add_definitions( -DIMPORT_LIBLLDB ) list(APPEND LLDB_MI_SOURCES ${LLDB_SOURCE_ROOT}/Host/common/GetOptInc.cpp