OSDN Git Service

tools/thermal: tmon: use pkg-config also for CFLAGS
authorOlaf Hering <olaf@aepfle.de>
Fri, 2 Oct 2015 09:50:45 +0000 (09:50 +0000)
committerZhang Rui <rui.zhang@intel.com>
Sat, 10 Oct 2015 03:32:31 +0000 (11:32 +0800)
The header <panel.h> might be in /usr/include/ncursesw, which is not
part of the standard include path. This fixes compile on openSUSE.

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
tools/thermal/tmon/Makefile

index 2e83dd3..3a961e9 100644 (file)
@@ -22,6 +22,9 @@ TMON_LIBS += $(shell pkg-config --libs $(STATIC) panelw ncursesw 2> /dev/null ||
                     pkg-config --libs $(STATIC) panel ncurses 2> /dev/null || \
                     echo -lpanel -lncurses)
 
+CFLAGS    += $(shell pkg-config --cflags $(STATIC) panelw ncursesw 2> /dev/null || \
+                    pkg-config --cflags $(STATIC) panel ncurses 2> /dev/null)
+
 OBJS = tmon.o tui.o sysfs.o pid.o
 OBJS +=