Makefile: Use pkg-config if available to set LIBPCREDIR
In platforms such as the Apple Silicon, pcre2.h
may not be available
in the default compiler path. We use pkg-config
if it is available
to determine the path where libpcre2-8
lives.
Relates to #4028 (closed)
Edited by Stan Hu