build,cpp: Fix include paths in forwarding headers in gpgme++ folder

* lang/cpp/src/Makefile.am (build rule for copied headers): Write
abs_srcdir instead of srcdir in the generated headers.
--

The generated include paths lacked a "../" if srcdir was relative. This
lead to self-including includes for in-source builds. Including the real
headers with their absolute paths fixes this.

GnuPG-bug-id: 7110
This commit is contained in:
Ingo Klöcker 2024-07-10 23:28:27 +02:00
parent f6d020e24f
commit e46748a0d1
No known key found for this signature in database
GPG Key ID: F5A5D1692277A1E9

View File

@ -92,7 +92,7 @@ copied_headers = $(gpgmepp_headers:%=gpgme++/%) $(interface_headers:%=gpgme++/%)
$(copied_headers): Makefile.am
mkdir -p $(builddir)/gpgme++/interfaces
echo -n "#include \"$(srcdir)" > "$@"
echo -n "#include \"$(abs_srcdir)" > "$@"
echo -n "$@" | sed "s/gpgme++//" >> "$@"
echo "\"" >> "$@"