adjust hints/{linux,macOS}.370 for absence of pkg-config

This commit is contained in:
nhmall
2023-07-05 09:07:13 -04:00
parent c360822c89
commit 7c26410daf
2 changed files with 21 additions and 7 deletions
+10 -3
View File
@@ -70,10 +70,17 @@ CURSESLIB = -lncurses -ltinfo
ifdef MAKEFILE_SRC ifdef MAKEFILE_SRC
comma:=, comma:=,
NCURSES_LFLAGS = $(shell pkg-config ncursesw --libs) NCURSES_LFLAGS = $(shell pkg-config ncursesw --libs)
ifneq (,$(findstring ncursesw, $(NCURSES_LFLAGS))) ifeq (,$(findstring ncursesw, $(NCURSES_LFLAGS)))
HAVE_NCURSESW=1 ifeq (,$(findstring ncurses, $(NCURSES_LFLAGS)))
else #this indicates that pkg-config itself was unavailable
NCURSES_LFLAGS = -lncursesw -ltinfo
endif
endif
#$(info $(NCURSES_LFLAGS))
ifeq (,$(findstring ncursesw, $(NCURSES_LFLAGS)))
HAVE_NCURSESW=0 HAVE_NCURSESW=0
else
HAVE_NCURSESW=1
endif endif
#$(info $(NCURSES_LFLAGS)) #$(info $(NCURSES_LFLAGS))
#$(info HAVE_NCURSESW=$(HAVE_NCURSESW)) #$(info HAVE_NCURSESW=$(HAVE_NCURSESW))
+11 -4
View File
@@ -116,10 +116,18 @@ else
# CURSESLIB = -lncurses -ltinfo # CURSESLIB = -lncurses -ltinfo
comma:=, comma:=,
NCURSES_LFLAGS = $(shell pkg-config ncursesw --libs) NCURSES_LFLAGS = $(shell pkg-config ncursesw --libs)
ifneq (,$(findstring ncurses, $(NCURSES_LFLAGS))) ifeq (,$(findstring ncursesw, $(NCURSES_LFLAGS)))
HAVE_NCURSESW=1 ifeq (,$(findstring ncurses, $(NCURSES_LFLAGS)))
else #this indicates that pkg-config itself was unavailable
CURSESLIB = $(NCURSES_LFLAGS)
NHCFLAGS+=-DCURSES_UNICODE
endif
endif
#$(info $(NCURSES_LFLAGS))
ifeq (,$(findstring ncursesw, $(NCURSES_LFLAGS)))
HAVE_NCURSESW=0 HAVE_NCURSESW=0
else
HAVE_NCURSESW=1
endif endif
ifeq "$(HAVE_NCURSESW)" "1" ifeq "$(HAVE_NCURSESW)" "1"
CURSESLIB = $(NCURSES_LFLAGS) CURSESLIB = $(NCURSES_LFLAGS)
@@ -787,4 +795,3 @@ endif # end of build_qt_pkg
endif # WANT_WIN_QT for packaging endif # WANT_WIN_QT for packaging
endif # MAKEFILE_TOP endif # MAKEFILE_TOP
# #