The gen-make.py output has
$(MKDIR) $(DESTDIR)$(bdb_libdir) $(pkgconfig_dir)
while Makefile has
pkgconfig_dir = $(datadir)/pkgconfig
The result is that
DESTDIR=$PWD/foo make install
creates the pkgconfig in prefix rather than in DESTDIR. Such an install should
create nothing in prefix.
The gen-make.py output also has lines like:
$(INSTALL_DATA) subversion/libsvn_fs_base/libsvn_fs_base.pc $(DESTDIR)$(
pkgconfig_dir)/libsvn_fs_base.pc
and the install fails because pkgconfig does not exist in $DESTDIR.