When linking with -lncurses[56]w we need to link with -lpanelw.
Signed-off-by: Vitezslav Samel <vitezslav(a)samel.cz>
---
Makefile | 22 ++++++++++++++--------
1 file changed, 14 insertions(+), 8 deletions(-)
diff --git a/Makefile b/Makefile
index 958b0fb..59b7c6f 100644
--- a/Makefile
+++ b/Makefile
@@ -218,7 +218,7 @@ ifdef NEEDS_NCURSESW5
NCURSES_CFLAGS := $(shell ncursesw5-config --cflags 2>/dev/null)
NCURSES_LDFLAGS := $(shell ncursesw5-config --libs 2>/dev/null)
ifndef NO_PANEL
- NCURSES_LDFLAGS += -lpanel
+ NCURSES_LDFLAGS += -lpanelw
endif
endif
endif
@@ -238,7 +238,7 @@ ifdef NEEDS_NCURSESW6
NCURSES_CFLAGS := $(shell ncursesw6-config --cflags 2>/dev/null)
NCURSES_LDFLAGS := $(shell ncursesw6-config --libs 2>/dev/null)
ifndef NO_PANEL
- NCURSES_LDFLAGS += -lpanel
+ NCURSES_LDFLAGS += -lpanelw
endif
endif
endif
@@ -248,21 +248,27 @@ ifndef NCURSES_LDFLAGS
ifneq ($(shell ncursesw6-config --libs 2>/dev/null),)
NCURSES_CFLAGS := $(shell ncursesw6-config --cflags 2>/dev/null)
NCURSES_LDFLAGS := $(shell ncursesw6-config --libs 2>/dev/null)
+ ifndef NO_PANEL
+ NCURSES_LDFLAGS += -lpanelw
+ endif
else ifneq ($(shell ncurses6-config --libs 2>/dev/null),)
NCURSES_CFLAGS := $(shell ncurses6-config --cflags 2>/dev/null)
NCURSES_LDFLAGS := $(shell ncurses6-config --libs 2>/dev/null)
+ ifndef NO_PANEL
+ NCURSES_LDFLAGS += -lpanel
+ endif
else ifneq ($(shell ncursesw5-config --libs 2>/dev/null),)
NCURSES_CFLAGS := $(shell ncursesw5-config --cflags 2>/dev/null)
NCURSES_LDFLAGS := $(shell ncursesw5-config --libs 2>/dev/null)
+ ifndef NO_PANEL
+ NCURSES_LDFLAGS += -lpanelw
+ endif
else ifneq ($(shell ncurses5-config --libs 2>/dev/null),)
NCURSES_CFLAGS := $(shell ncurses5-config --cflags 2>/dev/null)
NCURSES_LDFLAGS := $(shell ncurses5-config --libs 2>/dev/null)
- endif
-
- ifneq ($(NCURSES_LDFLAGS),)
- ifndef NO_PANEL
- NCURSES_LDFLAGS += -lpanel
- endif
+ ifndef NO_PANEL
+ NCURSES_LDFLAGS += -lpanel
+ endif
endif
endif
--
1.9.1