Write out a pkg-config file for lua52.
This is needed for other packages which try to
detect the presence of lua via autoconf scripts
which call pkg-config.  Such packages
include lutok and kyua.

Needed for issue Homebrew/homebrew#32060