aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/colors.h4
-rw-r--r--src/command.h1
-rw-r--r--src/list_window.h7
-rw-r--r--src/ncu.c4
-rw-r--r--src/screen.h7
-rw-r--r--src/screen_artist.c1
-rw-r--r--src/screen_file.c1
-rw-r--r--src/screen_help.c1
-rw-r--r--src/screen_keydef.c1
-rw-r--r--src/screen_list.h4
-rw-r--r--src/screen_lyrics.c1
-rw-r--r--src/screen_play.c1
-rw-r--r--src/screen_utils.h5
-rw-r--r--src/wreadln.h7
14 files changed, 36 insertions, 9 deletions
diff --git a/src/colors.h b/src/colors.h
index 051aa9e26..dec3ecd28 100644
--- a/src/colors.h
+++ b/src/colors.h
@@ -3,7 +3,11 @@
#include "config.h"
+#ifdef HAVE_NCURSESW_NCURSES_H
+#include <ncursesw/ncurses.h>
+#else
#include <ncurses.h>
+#endif
enum color {
COLOR_TITLE = 1,
diff --git a/src/command.h b/src/command.h
index 63d83b0a4..b48bf80f6 100644
--- a/src/command.h
+++ b/src/command.h
@@ -3,7 +3,6 @@
#include <stddef.h>
#include <stdio.h>
-#include <ncurses.h>
#define MAX_COMMAND_KEYS 3
diff --git a/src/list_window.h b/src/list_window.h
index 1d93a363e..11c4cddab 100644
--- a/src/list_window.h
+++ b/src/list_window.h
@@ -4,9 +4,14 @@
#include "../config.h"
#include "command.h"
-#include <ncurses.h>
#include <glib.h>
+#ifdef HAVE_NCURSESW_NCURSES_H
+#include <ncursesw/ncurses.h>
+#else
+#include <ncurses.h>
+#endif
+
#define LW_HIDE_CURSOR 0x01
typedef const char *(*list_window_callback_fn_t)(unsigned index,
diff --git a/src/ncu.c b/src/ncu.c
index 1ade90b40..c31f97d6b 100644
--- a/src/ncu.c
+++ b/src/ncu.c
@@ -26,7 +26,11 @@
#include "options.h"
#endif
+#ifdef HAVE_NCURSESW_NCURSES_H
+#include <ncursesw/ncurses.h>
+#else
#include <ncurses.h>
+#endif
void
ncu_init(void)
diff --git a/src/screen.h b/src/screen.h
index ef7940a31..404d0a8d5 100644
--- a/src/screen.h
+++ b/src/screen.h
@@ -5,9 +5,14 @@
#include "mpdclient.h"
#include "command.h"
-#include <ncurses.h>
#include <glib.h>
+#ifdef HAVE_NCURSESW_NCURSES_H
+#include <ncursesw/ncurses.h>
+#else
+#include <ncurses.h>
+#endif
+
#define IS_PLAYING(s) (s==MPD_STATUS_STATE_PLAY)
#define IS_PAUSED(s) (s==MPD_STATUS_STATE_PAUSE)
#define IS_STOPPED(s) (!(IS_PLAYING(s) | IS_PAUSED(s)))
diff --git a/src/screen_artist.c b/src/screen_artist.c
index 846902e0a..5fec3c04c 100644
--- a/src/screen_artist.c
+++ b/src/screen_artist.c
@@ -32,7 +32,6 @@
#include <stdlib.h>
#include <string.h>
#include <glib.h>
-#include <ncurses.h>
#define BUFSIZE 1024
diff --git a/src/screen_file.c b/src/screen_file.c
index bef155f59..b14b3b104 100644
--- a/src/screen_file.c
+++ b/src/screen_file.c
@@ -32,7 +32,6 @@
#include <stdlib.h>
#include <string.h>
#include <glib.h>
-#include <ncurses.h>
static struct screen_browser browser;
diff --git a/src/screen_help.c b/src/screen_help.c
index 3b66403d7..1f0043c09 100644
--- a/src/screen_help.c
+++ b/src/screen_help.c
@@ -27,7 +27,6 @@
#include <stdlib.h>
#include <string.h>
#include <glib.h>
-#include <ncurses.h>
typedef struct {
signed char highlight;
diff --git a/src/screen_keydef.c b/src/screen_keydef.c
index 86faabaf4..4e42b386f 100644
--- a/src/screen_keydef.c
+++ b/src/screen_keydef.c
@@ -29,7 +29,6 @@
#include <stdlib.h>
#include <string.h>
#include <glib.h>
-#include <ncurses.h>
#define STATIC_ITEMS 0
#define STATIC_SUB_ITEMS 1
diff --git a/src/screen_list.h b/src/screen_list.h
index 27c034676..e208a8bfe 100644
--- a/src/screen_list.h
+++ b/src/screen_list.h
@@ -22,7 +22,11 @@
#include "config.h"
+#ifdef HAVE_NCURSESW_NCURSES_H
+#include <ncursesw/ncurses.h>
+#else
#include <ncurses.h>
+#endif
extern const struct screen_functions screen_playlist;
extern const struct screen_functions screen_browse;
diff --git a/src/screen_lyrics.c b/src/screen_lyrics.c
index 2a8e10b67..6d9c6e4af 100644
--- a/src/screen_lyrics.c
+++ b/src/screen_lyrics.c
@@ -33,7 +33,6 @@
#include <stdlib.h>
#include <string.h>
#include <glib.h>
-#include <ncurses.h>
#include <unistd.h>
#include <stdio.h>
diff --git a/src/screen_play.c b/src/screen_play.c
index 37705c559..90b06aa0e 100644
--- a/src/screen_play.c
+++ b/src/screen_play.c
@@ -36,7 +36,6 @@
#include <string.h>
#include <time.h>
#include <glib.h>
-#include <ncurses.h>
#define MAX_SONG_LENGTH 512
diff --git a/src/screen_utils.h b/src/screen_utils.h
index a550f1742..335faceb2 100644
--- a/src/screen_utils.h
+++ b/src/screen_utils.h
@@ -1,10 +1,15 @@
#ifndef SCREEN_UTILS_H
#define SCREEN_UTILS_H
+#include "config.h"
#include "list_window.h"
#include "command.h"
+#ifdef HAVE_NCURSESW_NCURSES_H
+#include <ncursesw/ncurses.h>
+#else
#include <ncurses.h>
+#endif
struct mpdclient;
diff --git a/src/wreadln.h b/src/wreadln.h
index e1efe1c50..e1ac67318 100644
--- a/src/wreadln.h
+++ b/src/wreadln.h
@@ -1,8 +1,15 @@
#ifndef WREADLN_H
#define WREADLN_H
+#include "config.h"
+
#include <glib.h>
+
+#ifdef HAVE_NCURSESW_NCURSES_H
+#include <ncursesw/ncurses.h>
+#else
#include <ncurses.h>
+#endif
/* completion callback data */
extern void *wrln_completion_callback_data;