diff --git a/config.h.in b/config.h.in index f98ea63..7abfbc9 100644 --- a/config.h.in +++ b/config.h.in @@ -21,6 +21,9 @@ /* Define to 1 if you have the `memset' function. */ #undef HAVE_MEMSET +/* Define to 1 if you have the header file. */ +#undef HAVE_NCURSES_PANEL_H + /* Define to 1 if you have the header file. */ #undef HAVE_PANEL_H diff --git a/configure.ac b/configure.ac index 26c781f..29806af 100644 --- a/configure.ac +++ b/configure.ac @@ -39,7 +39,7 @@ AC_SEARCH_LIBS([new_panel], [panel], , # Checks for header files. AC_HEADER_STDC -AC_CHECK_HEADERS([errno.h fcntl.h limits.h panel.h stdlib.h string.h unistd.h]) +AC_CHECK_HEADERS([errno.h fcntl.h limits.h panel.h ncurses/panel.h stdlib.h string.h unistd.h]) # Checks for typedefs, structures, and compiler characteristics. AC_HEADER_STDBOOL diff --git a/curses/ConWin.hpp b/curses/ConWin.hpp index 6ad2989..46c2f51 100644 --- a/curses/ConWin.hpp +++ b/curses/ConWin.hpp @@ -23,7 +23,14 @@ #define INCLUDED_CONWIN_HPP +#include "config.h" +#if defined(HAVE_PANEL_H) #include +#elif defined(HAVE_NCURSES_PANEL_H) +#include +#else +#error "Couldn't find a panel.h header." +#endif #undef border // It interferes with my member function #define KEY_ESCAPE 0x1B