Skip to content

Commit 4ef482b

Browse files
committed
Add missing PCP include path for dynamic PMDA
The dynamic PMDA uses internal PCP headers (libpcp.h) that require -I$(PCP_INC_DIR) to be found. The GNUmakefile.install was stripping all -I flags from builddefs and only adding back -I$(PCP_INC_DIR)/.. which works for public headers like <pcp/pmapi.h> but not for internal headers like "libpcp.h". This was causing compilation failures when building the dynamic PMDA from the installed testsuite with: fatal error: 'libpcp.h' file not found
1 parent f360f6e commit 4ef482b

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

qa/pmdas/dynamic/GNUmakefile.install

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ ifneq "$(PCP_INC_DIR)" "/usr/include/pcp"
2222
# for cc add -I<run-time-include-dir> (need /.. at the end so
2323
# #include <pcp/foo.h> works) when $(PCP_INC_DIR) may not be on
2424
# the default cpp include search path.
25-
CFLAGS += -I$(PCP_INC_DIR)/..
25+
# Also add -I$(PCP_INC_DIR) for internal headers like libpcp.h
26+
CFLAGS += -I$(PCP_INC_DIR)/.. -I$(PCP_INC_DIR)
2627
else
2728
CFLAGS += -I../../src
2829
endif

0 commit comments

Comments
 (0)