The value of ${includedir} is going to be something like
/usr/include (GNU/Linux)
/usr/local/include (FreeBSD ports)
/usr/local/Cellar/readline/8.0.0/include (macOS homebrew)
and software using readline is supposed to
#include <readline/readline.h>
However, since Cflags in readline.pc contains
-I${includedir}/readline
the compiler will expect to find the header in
/usr/include/readline/readline/readline.h
which will work on GNU/Linux, where /usr/include is part of the
default include path, but will not on other platforms.
Signed-off-by: Andrea Bolognani <[email protected]>
---
readline.pc.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/readline.pc.in b/readline.pc.in
index a7f2cf3..ff79d71 100644
--- a/readline.pc.in
+++ b/readline.pc.in
@@ -9,4 +9,4 @@ URL: http://tiswww.cwru.edu/php/chet/readline/rltop.html
Version: @LIBVERSION@
Requires.private: @TERMCAP_PKG_CONFIG_LIB@
Libs: -L${libdir} -lreadline
-Cflags: -I${includedir}/readline
+Cflags: -I${includedir}
--
2.20.1
_______________________________________________
Bug-readline mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-readline