[Lldb-commits] [PATCH] D14037: Reuse native curses(8) library on NetBSD

Kamil Rytarowski via lldb-commits lldb-commits at lists.llvm.org
Fri Oct 23 19:38:01 PDT 2015


krytarowski created this revision.
krytarowski added subscribers: lldb-commits, joerg.
krytarowski set the repository for this revision to rL LLVM.

The reason for it is limit of detecting ncurses on various systems. For
example, Ubuntu ships with <curses.h> and linkage from <ncurses.h>, <ncurses.h>
isn't detected by CMake. Detecting `<curses.h>` on NetBSD is reusing
conflicting header from the host curses(8) and pkgsrc's ncurses library.

ncurses ships on most (till conflicting) systems with curses.h. On NetBSD it
might be conflicting, so the ncurses headers are installed with pkgsrc to a
subdirectory "ncurses/".

Repository:
  rL LLVM

http://reviews.llvm.org/D14037

Files:
  source/Core/IOHandler.cpp

Index: source/Core/IOHandler.cpp
===================================================================
--- source/Core/IOHandler.cpp
+++ source/Core/IOHandler.cpp
@@ -29,7 +29,7 @@
 #include "lldb/Target/ThreadPlan.h"
 
 #ifndef LLDB_DISABLE_CURSES
-#include <ncurses.h>
+#include <curses.h>
 #include <panel.h>
 #endif
 
@@ -4133,7 +4133,9 @@
         case KEY_UNDO:      return "undo key";
         case KEY_MOUSE:     return "Mouse event has occurred";
         case KEY_RESIZE:    return "Terminal resize event";
+#ifdef KEY_EVENT
         case KEY_EVENT:     return "We were interrupted by an event";
+#endif
         case KEY_RETURN:    return "return";
         case ' ':           return "space";
         case '\t':          return "tab";


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D14037.38292.patch
Type: text/x-patch
Size: 746 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20151024/071a5cc3/attachment.bin>


More information about the lldb-commits mailing list