mirror of
https://github.com/jarun/nnn.git
synced 2024-11-24 03:41:27 +00:00
Makefile: use PKG_CONFIG instead of hardcoding pkg-config (#78)
This commit is contained in:
parent
e797a7eefd
commit
ff502f0b3e
7
Makefile
7
Makefile
|
@ -3,14 +3,15 @@ VERSION = 1.6
|
|||
PREFIX ?= /usr/local
|
||||
MANPREFIX ?= $(PREFIX)/share/man
|
||||
STRIP ?= strip
|
||||
PKG_CONFIG ?= pkg-config
|
||||
|
||||
CFLAGS ?= -O3
|
||||
CFLAGS += -Wall -Wextra -Wno-unused-parameter
|
||||
LDLIBS = -lreadline
|
||||
|
||||
ifeq ($(shell pkg-config ncursesw && echo 1),1)
|
||||
CFLAGS += $(shell pkg-config --cflags ncursesw)
|
||||
LDLIBS += $(shell pkg-config --libs ncursesw)
|
||||
ifeq ($(shell $(PKG_CONFIG) ncursesw && echo 1),1)
|
||||
CFLAGS += $(shell $(PKG_CONFIG) --cflags ncursesw)
|
||||
LDLIBS += $(shell $(PKG_CONFIG) --libs ncursesw)
|
||||
else
|
||||
LDLIBS += -lncurses
|
||||
endif
|
||||
|
|
Loading…
Reference in a new issue