diff options
author | Mike Frysinger | 2013-09-29 06:44:43 +0200 |
---|---|---|
committer | Karel Zak | 2013-09-30 13:41:07 +0200 |
commit | 2b8f22bd90f8074c714afaa872c314287e54a9a6 (patch) | |
tree | 10ed8a0302cbc37aa0c3e904dea6f92e6ae7ce1b /misc-utils | |
parent | setterm: fix term.h/ncurses.h include ordering (diff) | |
download | kernel-qcow2-util-linux-2b8f22bd90f8074c714afaa872c314287e54a9a6.tar.gz kernel-qcow2-util-linux-2b8f22bd90f8074c714afaa872c314287e54a9a6.tar.xz kernel-qcow2-util-linux-2b8f22bd90f8074c714afaa872c314287e54a9a6.zip |
clean up term lib handling
The ncurses package has been providing pkg-config files for a while now.
So let's start using them to get the proper linker & compiler flags. It
can make a difference when ncurses is configured in a way that requires
extra link time flags but util-linux doesn't provide them, or when the
headers live in a weird place and util-linux can't find them.
Since the NCURSES_LIBS is always defined for the Makefile, there's no need
to gate on the HAVE_NCURSES conditional. When it's disabled, the var will
simply be empty.
With a minor tweak to how tinfo is handled, we can do the same thing -- we
just always use TINFO_LIBS in the Makefile's.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'misc-utils')
-rw-r--r-- | misc-utils/Makemodule.am | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/misc-utils/Makemodule.am b/misc-utils/Makemodule.am index fcfec7bac..70bb33988 100644 --- a/misc-utils/Makemodule.am +++ b/misc-utils/Makemodule.am @@ -10,19 +10,11 @@ if !HAVE_LANGINFO cal_SOURCES += lib/langinfo.c endif -cal_LDADD = $(LDADD) libcommon.la - -if HAVE_TINFO -cal_LDADD += -ltinfo @NCURSES_LIBS@ -else -if HAVE_NCURSES -cal_LDADD += @NCURSES_LIBS@ -else +cal_CFLAGS = $(AM_CFLAGS) $(NCURSES_CFLAGS) +cal_LDADD = $(LDADD) libcommon.la $(NCURSES_LIBS) $(TINFO_LIBS) if HAVE_TERMCAP cal_LDADD += -ltermcap endif -endif # !HAVE_NCURSES -endif # !HAVE_TINFO usrbin_exec_PROGRAMS += logger |