[Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
This revision was automatically updated to reflect the committed changes. Closed by commit rL290044: Support of lldb on Kfreebsd (authored by sylvestre). Changed prior to commit: https://reviews.llvm.org/D23977?vs=77714=81842#toc Repository: rL LLVM https://reviews.llvm.org/D23977 Files: lldb/trunk/cmake/LLDBDependencies.cmake lldb/trunk/cmake/modules/LLDBConfig.cmake lldb/trunk/scripts/Python/modules/CMakeLists.txt lldb/trunk/scripts/utilsOsType.py Index: lldb/trunk/cmake/modules/LLDBConfig.cmake === --- lldb/trunk/cmake/modules/LLDBConfig.cmake +++ lldb/trunk/cmake/modules/LLDBConfig.cmake @@ -416,3 +416,5 @@ if(LLDB_USE_BUILTIN_DEMANGLER) add_definitions(-DLLDB_USE_BUILTIN_DEMANGLER) endif() + +find_package(Backtrace) Index: lldb/trunk/cmake/LLDBDependencies.cmake === --- lldb/trunk/cmake/LLDBDependencies.cmake +++ lldb/trunk/cmake/LLDBDependencies.cmake @@ -161,10 +161,7 @@ list(APPEND LLDB_SYSTEM_LIBS atomic) endif() -# On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc. -if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") - list(APPEND LLDB_SYSTEM_LIBS execinfo) -endif() +list(APPEND LLDB_SYSTEM_LIBS ${Backtrace_LIBRARY}) if (NOT LLDB_DISABLE_PYTHON AND NOT LLVM_BUILD_STATIC) list(APPEND LLDB_SYSTEM_LIBS ${PYTHON_LIBRARIES}) Index: lldb/trunk/scripts/utilsOsType.py === --- lldb/trunk/scripts/utilsOsType.py +++ lldb/trunk/scripts/utilsOsType.py @@ -36,14 +36,16 @@ Linux = 3 NetBSD = 4 Windows = 5 +kFreeBSD = 6 else: class EnumOsType(object): values = ["Unknown", "Darwin", "FreeBSD", "Linux", "NetBSD", - "Windows"] + "Windows", + "kFreeBSD"] class __metaclass__(type): #++ @@ -91,5 +93,7 @@ eOSType = EnumOsType.NetBSD elif strOS == "win32": eOSType = EnumOsType.Windows +elif strOS.startswith("gnukfreebsd"): +eOSType = EnumOsType.kFreeBSD return eOSType Index: lldb/trunk/scripts/Python/modules/CMakeLists.txt === --- lldb/trunk/scripts/Python/modules/CMakeLists.txt +++ lldb/trunk/scripts/Python/modules/CMakeLists.txt @@ -6,6 +6,6 @@ endif () # build the Python readline suppression module only on Linux -if (CMAKE_SYSTEM_NAME MATCHES "Linux") +if (CMAKE_SYSTEM_NAME MATCHES "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "GNU" OR CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") add_subdirectory(readline) endif() Index: lldb/trunk/cmake/modules/LLDBConfig.cmake === --- lldb/trunk/cmake/modules/LLDBConfig.cmake +++ lldb/trunk/cmake/modules/LLDBConfig.cmake @@ -416,3 +416,5 @@ if(LLDB_USE_BUILTIN_DEMANGLER) add_definitions(-DLLDB_USE_BUILTIN_DEMANGLER) endif() + +find_package(Backtrace) Index: lldb/trunk/cmake/LLDBDependencies.cmake === --- lldb/trunk/cmake/LLDBDependencies.cmake +++ lldb/trunk/cmake/LLDBDependencies.cmake @@ -161,10 +161,7 @@ list(APPEND LLDB_SYSTEM_LIBS atomic) endif() -# On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc. -if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") - list(APPEND LLDB_SYSTEM_LIBS execinfo) -endif() +list(APPEND LLDB_SYSTEM_LIBS ${Backtrace_LIBRARY}) if (NOT LLDB_DISABLE_PYTHON AND NOT LLVM_BUILD_STATIC) list(APPEND LLDB_SYSTEM_LIBS ${PYTHON_LIBRARIES}) Index: lldb/trunk/scripts/utilsOsType.py === --- lldb/trunk/scripts/utilsOsType.py +++ lldb/trunk/scripts/utilsOsType.py @@ -36,14 +36,16 @@ Linux = 3 NetBSD = 4 Windows = 5 +kFreeBSD = 6 else: class EnumOsType(object): values = ["Unknown", "Darwin", "FreeBSD", "Linux", "NetBSD", - "Windows"] + "Windows", + "kFreeBSD"] class __metaclass__(type): #++ @@ -91,5 +93,7 @@ eOSType = EnumOsType.NetBSD elif strOS == "win32": eOSType = EnumOsType.Windows +elif strOS.startswith("gnukfreebsd"): +eOSType = EnumOsType.kFreeBSD return eOSType Index: lldb/trunk/scripts/Python/modules/CMakeLists.txt === --- lldb/trunk/scripts/Python/modules/CMakeLists.txt +++
[Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
beanz added a comment. Looks fine to me. https://reviews.llvm.org/D23977 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
tfiala added a comment. Looks reasonable to me. @beanz, any comments on this? https://reviews.llvm.org/D23977 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
sylvestre.ledru updated this revision to Diff 77714. https://reviews.llvm.org/D23977 Files: cmake/LLDBDependencies.cmake cmake/modules/LLDBConfig.cmake scripts/Python/modules/CMakeLists.txt scripts/utilsOsType.py Index: scripts/utilsOsType.py === --- scripts/utilsOsType.py +++ scripts/utilsOsType.py @@ -36,6 +36,7 @@ Linux = 3 NetBSD = 4 Windows = 5 +kFreeBSD = 6 else: class EnumOsType(object): values = ["Unknown", @@ -43,7 +44,8 @@ "FreeBSD", "Linux", "NetBSD", - "Windows"] + "Windows", + "kFreeBSD"] class __metaclass__(type): #++ @@ -91,5 +93,7 @@ eOSType = EnumOsType.NetBSD elif strOS == "win32": eOSType = EnumOsType.Windows +elif strOS.startswith("gnukfreebsd"): +eOSType = EnumOsType.kFreeBSD return eOSType Index: scripts/Python/modules/CMakeLists.txt === --- scripts/Python/modules/CMakeLists.txt +++ scripts/Python/modules/CMakeLists.txt @@ -5,7 +5,7 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-macro-redefined") endif () -# build the Python readline suppression module only on Linux -if (CMAKE_SYSTEM_NAME MATCHES "Linux" AND NOT __ANDROID_NDK__) +# build the Python readline suppression module only on Linux or GNU systems +if ((CMAKE_SYSTEM_NAME MATCHES "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "GNU" OR CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") AND NOT __ANDROID_NDK__) add_subdirectory(readline) endif() Index: cmake/modules/LLDBConfig.cmake === --- cmake/modules/LLDBConfig.cmake +++ cmake/modules/LLDBConfig.cmake @@ -415,3 +415,5 @@ if(LLDB_USE_BUILTIN_DEMANGLER) add_definitions(-DLLDB_USE_BUILTIN_DEMANGLER) endif() + +find_package(Backtrace) Index: cmake/LLDBDependencies.cmake === --- cmake/LLDBDependencies.cmake +++ cmake/LLDBDependencies.cmake @@ -165,10 +165,7 @@ list(APPEND LLDB_SYSTEM_LIBS atomic) endif() -# On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc. -if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") - list(APPEND LLDB_SYSTEM_LIBS execinfo) -endif() +list(APPEND LLDB_SYSTEM_LIBS ${Backtrace_LIBRARY}) if (NOT LLDB_DISABLE_PYTHON AND NOT LLVM_BUILD_STATIC) list(APPEND LLDB_SYSTEM_LIBS ${PYTHON_LIBRARIES}) Index: scripts/utilsOsType.py === --- scripts/utilsOsType.py +++ scripts/utilsOsType.py @@ -36,6 +36,7 @@ Linux = 3 NetBSD = 4 Windows = 5 +kFreeBSD = 6 else: class EnumOsType(object): values = ["Unknown", @@ -43,7 +44,8 @@ "FreeBSD", "Linux", "NetBSD", - "Windows"] + "Windows", + "kFreeBSD"] class __metaclass__(type): #++ @@ -91,5 +93,7 @@ eOSType = EnumOsType.NetBSD elif strOS == "win32": eOSType = EnumOsType.Windows +elif strOS.startswith("gnukfreebsd"): +eOSType = EnumOsType.kFreeBSD return eOSType Index: scripts/Python/modules/CMakeLists.txt === --- scripts/Python/modules/CMakeLists.txt +++ scripts/Python/modules/CMakeLists.txt @@ -5,7 +5,7 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-macro-redefined") endif () -# build the Python readline suppression module only on Linux -if (CMAKE_SYSTEM_NAME MATCHES "Linux" AND NOT __ANDROID_NDK__) +# build the Python readline suppression module only on Linux or GNU systems +if ((CMAKE_SYSTEM_NAME MATCHES "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "GNU" OR CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") AND NOT __ANDROID_NDK__) add_subdirectory(readline) endif() Index: cmake/modules/LLDBConfig.cmake === --- cmake/modules/LLDBConfig.cmake +++ cmake/modules/LLDBConfig.cmake @@ -415,3 +415,5 @@ if(LLDB_USE_BUILTIN_DEMANGLER) add_definitions(-DLLDB_USE_BUILTIN_DEMANGLER) endif() + +find_package(Backtrace) Index: cmake/LLDBDependencies.cmake === --- cmake/LLDBDependencies.cmake +++ cmake/LLDBDependencies.cmake @@ -165,10 +165,7 @@ list(APPEND LLDB_SYSTEM_LIBS atomic) endif() -# On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc. -if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") - list(APPEND LLDB_SYSTEM_LIBS execinfo) -endif()
[Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
tfiala requested changes to this revision. tfiala added a comment. This revision now requires changes to proceed. Okay. I think we need a minor tweak, to drop the REQUIRED on the Backtrace usage. https://reviews.llvm.org/D23977 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
krytarowski added inline comments. Comment at: cmake/modules/LLDBConfig.cmake:414 + +find_package(Backtrace REQUIRED) tfiala wrote: > Hi Sylvestre! > > It's hard to tell without more context, but it looks like this location has > most/all configurations going through it. For OSes that don't actually have > a backtrace package, I think this emits a cmake error, doesn't it? > > This might need to be protected by the systems that need the backtrace > package. (Probably Unix-like systems only?) It's sufficient to drop the `REQUIRED` keyword and it will be fine. `${Backtrace_LIBRARY}` will be evaluated to NIL in case of lack of this dependency. I'm unsure whether `find_pacakge()` might be after usage of `${Backtrace_LIBRARY}`. I would reorder it at least for clarity for a reader. https://reviews.llvm.org/D23977 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Re: [Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
sylvestre.ledru updated this revision to Diff 72758. sylvestre.ledru added a comment. Herald added subscribers: mgorny, beanz. Updated by Pino! https://reviews.llvm.org/D23977 Files: cmake/LLDBDependencies.cmake cmake/modules/LLDBConfig.cmake scripts/Python/modules/CMakeLists.txt scripts/utilsOsType.py Index: cmake/modules/LLDBConfig.cmake === --- cmake/modules/LLDBConfig.cmake +++ cmake/modules/LLDBConfig.cmake @@ -410,3 +410,5 @@ list(APPEND system_libs ${CURSES_LIBRARIES}) include_directories(${CURSES_INCLUDE_DIR}) endif () + +find_package(Backtrace REQUIRED) Index: scripts/Python/modules/CMakeLists.txt === --- scripts/Python/modules/CMakeLists.txt +++ scripts/Python/modules/CMakeLists.txt @@ -5,7 +5,7 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-macro-redefined") endif () -# build the Python readline suppression module only on Linux -if (CMAKE_SYSTEM_NAME MATCHES "Linux" AND NOT __ANDROID_NDK__) +# build the Python readline suppression module only on Linux or GNU systems +if ((CMAKE_SYSTEM_NAME MATCHES "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "GNU" OR CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") AND NOT __ANDROID_NDK__) add_subdirectory(readline) endif() Index: scripts/utilsOsType.py === --- scripts/utilsOsType.py +++ scripts/utilsOsType.py @@ -35,6 +35,7 @@ Linux = 3 NetBSD = 4 Windows = 5 +kFreeBSD = 6 else: class EnumOsType(object): values = ["Unknown", @@ -42,7 +43,8 @@ "FreeBSD", "Linux", "NetBSD", - "Windows"] + "Windows", + "kFreeBSD"] class __metaclass__(type): #++--- # Details: Fn acts as an enumeration. @@ -86,5 +88,7 @@ eOSType = EnumOsType.NetBSD elif strOS == "win32": eOSType = EnumOsType.Windows +elif strOS.startswith("gnukfreebsd"): +eOSType = EnumOsType.kFreeBSD return eOSType Index: cmake/LLDBDependencies.cmake === --- cmake/LLDBDependencies.cmake +++ cmake/LLDBDependencies.cmake @@ -152,10 +152,7 @@ endif() endif() endif() -# On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc. -if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") - list(APPEND LLDB_SYSTEM_LIBS execinfo) -endif() +list(APPEND LLDB_SYSTEM_LIBS ${Backtrace_LIBRARY}) if (NOT LLDB_DISABLE_PYTHON AND NOT LLVM_BUILD_STATIC) list(APPEND LLDB_SYSTEM_LIBS ${PYTHON_LIBRARIES}) Index: cmake/modules/LLDBConfig.cmake === --- cmake/modules/LLDBConfig.cmake +++ cmake/modules/LLDBConfig.cmake @@ -410,3 +410,5 @@ list(APPEND system_libs ${CURSES_LIBRARIES}) include_directories(${CURSES_INCLUDE_DIR}) endif () + +find_package(Backtrace REQUIRED) Index: scripts/Python/modules/CMakeLists.txt === --- scripts/Python/modules/CMakeLists.txt +++ scripts/Python/modules/CMakeLists.txt @@ -5,7 +5,7 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-macro-redefined") endif () -# build the Python readline suppression module only on Linux -if (CMAKE_SYSTEM_NAME MATCHES "Linux" AND NOT __ANDROID_NDK__) +# build the Python readline suppression module only on Linux or GNU systems +if ((CMAKE_SYSTEM_NAME MATCHES "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "GNU" OR CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") AND NOT __ANDROID_NDK__) add_subdirectory(readline) endif() Index: scripts/utilsOsType.py === --- scripts/utilsOsType.py +++ scripts/utilsOsType.py @@ -35,6 +35,7 @@ Linux = 3 NetBSD = 4 Windows = 5 +kFreeBSD = 6 else: class EnumOsType(object): values = ["Unknown", @@ -42,7 +43,8 @@ "FreeBSD", "Linux", "NetBSD", - "Windows"] + "Windows", + "kFreeBSD"] class __metaclass__(type): #++--- # Details: Fn acts as an enumeration. @@ -86,5 +88,7 @@ eOSType = EnumOsType.NetBSD elif strOS == "win32": eOSType = EnumOsType.Windows +elif strOS.startswith("gnukfreebsd"): +eOSType = EnumOsType.kFreeBSD return eOSType Index: cmake/LLDBDependencies.cmake === --- cmake/LLDBDependencies.cmake +++ cmake/LLDBDependencies.cmake @@ -152,10 +152,7 @@ endif() endif() endif() -# On FreeBSD/NetBSD backtrace() is
Re: [Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
emaste requested changes to this revision. emaste added a reviewer: emaste. emaste added a comment. This revision now requires changes to proceed. Two requested changes called out in comments above https://reviews.llvm.org/D23977 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Re: [Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
tfiala added a comment. @sylvestre.ledru, I think this will be ready to go if you can convert that check to a CMake built-in check. Maybe you can pass that along to Pino Toscano? https://reviews.llvm.org/D23977 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Re: [Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
tfiala added inline comments. Comment at: cmake/LLDBDependencies.cmake:168 @@ -167,3 +167,3 @@ # On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc. -if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") +if ((CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") AND NOT CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") list(APPEND LLDB_SYSTEM_LIBS execinfo) krytarowski wrote: > brucem wrote: > > This really should turn into a check so that we don't need this to be > > extended for every single OS that gets added. > There is now support for CMake >= 3.0, which offers a builtin check for it. I agree with previous comments - if we can convert this to a CMake built-in check, that would be ideal. https://reviews.llvm.org/D23977 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Re: [Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
emaste added a subscriber: emaste. emaste added a comment. - in the future can you please upload with context (e.g. git diff -U) - I think the OS names in utilsOsType.py are kept sorted and the actual enum values are not part of an ABI https://reviews.llvm.org/D23977 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Re: [Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
krytarowski added a subscriber: krytarowski. Comment at: cmake/LLDBDependencies.cmake:168 @@ -167,3 +167,3 @@ # On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc. -if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") +if ((CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") AND NOT CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") list(APPEND LLDB_SYSTEM_LIBS execinfo) brucem wrote: > This really should turn into a check so that we don't need this to be > extended for every single OS that gets added. There is now support for CMake >= 3.0, which offers a builtin check for it. https://reviews.llvm.org/D23977 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Re: [Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
brucem added a subscriber: brucem. Comment at: cmake/LLDBDependencies.cmake:168 @@ -167,3 +167,3 @@ # On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc. -if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") +if ((CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") AND NOT CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") list(APPEND LLDB_SYSTEM_LIBS execinfo) This really should turn into a check so that we don't need this to be extended for every single OS that gets added. https://reviews.llvm.org/D23977 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [PATCH] D23977: Support of lldb on Kfreebsd
sylvestre.ledru created this revision. sylvestre.ledru added a reviewer: tfiala. sylvestre.ledru added a subscriber: LLDB. sylvestre.ledru added a project: LLDB. Herald added subscribers: srhines, danalbert, tberghammer. Patch by Pino Toscano. Reported in http://bugs.debian.org/835665 https://reviews.llvm.org/D23977 Files: cmake/LLDBDependencies.cmake scripts/Python/modules/CMakeLists.txt scripts/utilsOsType.py Index: scripts/utilsOsType.py === --- scripts/utilsOsType.py +++ scripts/utilsOsType.py @@ -35,6 +35,7 @@ Linux = 3 NetBSD = 4 Windows = 5 +kFreeBSD = 6 else: class EnumOsType(object): values = ["Unknown", @@ -42,7 +43,8 @@ "FreeBSD", "Linux", "NetBSD", - "Windows"] + "Windows", + "kFreeBSD"] class __metaclass__(type): #++--- # Details: Fn acts as an enumeration. @@ -86,5 +88,7 @@ eOSType = EnumOsType.NetBSD elif strOS == "win32": eOSType = EnumOsType.Windows +elif strOS.startswith("gnukfreebsd"): +eOSType = EnumOsType.kFreeBSD return eOSType Index: scripts/Python/modules/CMakeLists.txt === --- scripts/Python/modules/CMakeLists.txt +++ scripts/Python/modules/CMakeLists.txt @@ -5,7 +5,7 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-macro-redefined") endif () -# build the Python readline suppression module only on Linux -if (CMAKE_SYSTEM_NAME MATCHES "Linux" AND NOT __ANDROID_NDK__) +# build the Python readline suppression module only on Linux or GNU systems +if ((CMAKE_SYSTEM_NAME MATCHES "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "GNU" OR CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") AND NOT __ANDROID_NDK__) add_subdirectory(readline) endif() Index: cmake/LLDBDependencies.cmake === --- cmake/LLDBDependencies.cmake +++ cmake/LLDBDependencies.cmake @@ -165,7 +165,7 @@ endif() # On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc. -if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") +if ((CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") AND NOT CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") list(APPEND LLDB_SYSTEM_LIBS execinfo) endif() Index: scripts/utilsOsType.py === --- scripts/utilsOsType.py +++ scripts/utilsOsType.py @@ -35,6 +35,7 @@ Linux = 3 NetBSD = 4 Windows = 5 +kFreeBSD = 6 else: class EnumOsType(object): values = ["Unknown", @@ -42,7 +43,8 @@ "FreeBSD", "Linux", "NetBSD", - "Windows"] + "Windows", + "kFreeBSD"] class __metaclass__(type): #++--- # Details: Fn acts as an enumeration. @@ -86,5 +88,7 @@ eOSType = EnumOsType.NetBSD elif strOS == "win32": eOSType = EnumOsType.Windows +elif strOS.startswith("gnukfreebsd"): +eOSType = EnumOsType.kFreeBSD return eOSType Index: scripts/Python/modules/CMakeLists.txt === --- scripts/Python/modules/CMakeLists.txt +++ scripts/Python/modules/CMakeLists.txt @@ -5,7 +5,7 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-macro-redefined") endif () -# build the Python readline suppression module only on Linux -if (CMAKE_SYSTEM_NAME MATCHES "Linux" AND NOT __ANDROID_NDK__) +# build the Python readline suppression module only on Linux or GNU systems +if ((CMAKE_SYSTEM_NAME MATCHES "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "GNU" OR CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") AND NOT __ANDROID_NDK__) add_subdirectory(readline) endif() Index: cmake/LLDBDependencies.cmake === --- cmake/LLDBDependencies.cmake +++ cmake/LLDBDependencies.cmake @@ -165,7 +165,7 @@ endif() # On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc. -if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") +if ((CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD") AND NOT CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD") list(APPEND LLDB_SYSTEM_LIBS execinfo) endif() ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits