pacemaker  2.1.0-7c3f660
Scalable High-Availability cluster resource manager
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
curses_internal.h
Go to the documentation of this file.
1 /*
2  * Copyright 2015-2021 the Pacemaker project contributors
3  *
4  * The version control history for this file may have further details.
5  *
6  * This source code is licensed under the GNU Lesser General Public License
7  * version 2.1 or later (LGPLv2.1+) WITHOUT ANY WARRANTY.
8  */
9 
10 #ifndef PCMK__CURSES_INTERNAL__H
11 # define PCMK__CURSES_INTERNAL__H
12 
13 # include <stdio.h>
14 
15 # ifndef PCMK__CONFIG_H
16 # define PCMK__CONFIG_H
17 # include <config.h>
18 # endif
19 
20 # include <crm/common/logging.h>
21 
22 /*
23  * The man pages for both curses and ncurses suggest inclusion of "curses.h".
24  * We believe the following to be acceptable and portable.
25  */
26 
27 # if defined(HAVE_LIBNCURSES) || defined(HAVE_LIBCURSES)
28 # if defined(HAVE_NCURSES_H) && !defined(HAVE_INCOMPATIBLE_PRINTW)
29 # include <ncurses.h>
30 # define CURSES_ENABLED 1
31 # elif defined(HAVE_NCURSES_NCURSES_H) && !defined(HAVE_INCOMPATIBLE_PRINTW)
32 # include <ncurses/ncurses.h>
33 # define CURSES_ENABLED 1
34 # elif defined(HAVE_CURSES_H) && !defined(HAVE_INCOMPATIBLE_PRINTW)
35 # include <curses.h>
36 # define CURSES_ENABLED 1
37 # elif defined(HAVE_CURSES_CURSES_H) && !defined(HAVE_INCOMPATIBLE_PRINTW)
38 # include <curses/curses.h>
39 # define CURSES_ENABLED 1
40 # else
41 # define CURSES_ENABLED 0
42 # endif
43 # else
44 # define CURSES_ENABLED 0
45 # endif
46 
47 #endif
Wrappers for and extensions to libqb logging.