Recompile plperl to set the right RUNPATH
Recompile plperl to set the right RUNPATH

Currently, GPDB5 is built with --enable-rpath (default configure
option). For plperl, it's Makefile specifies an absolute path to the
location of "$(perl -MConfig -e 'print $Config{archlibexp}')/CORE"
(e.g., /usr/lib64/perl5/CORE on RHEL7). This directory is not on the
default search path for the runtime linker. Without the proper RUNPATH
entry, libperl.so cannot be found when postgres tries to load the plperl
extension.

Without setting correct RUNPATH for plperl.so, will see a error like
followin:
ERROR:  could not load library
"/usr/local/greenplum-db-devel/lib/postgresql/plperl.so": libperl.so:
cannot open shared object file: No such file or directory

Authored-by: Shaoqi Bai <7e128f5f13b82562f8df0d475a28b2c22e78dec3@vmware.com>
(cherry picked from commit a3eeadd5a575820ebc9a401c96b252355f183bb1)

lisakowen/gpdb,adam8157/gpdb,lisakowen/gpdb,jmcatamney/gpdb,adam8157/gpdb,greenplum-db/gpdb,adam8157/gpdb,greenplum-db/gpdb,jmcatamney/gpdb,adam8157/gpdb,xinzweb/gpdb,jmcatamney/gpdb,lisakowen/gpdb,greenplum-db/gpdb,adam8157/gpdb,adam8157/gpdb,lisakowen/gpdb,adam8157/gpdb,greenplum-db/gpdb,xinzweb/gpdb,50wu/gpdb,jmcatamney/gpdb,xinzweb/gpdb,xinzweb/gpdb,50wu/gpdb,greenplum-db/gpdb,jmcatamney/gpdb,jmcatamney/gpdb,lisakowen/gpdb,50wu/gpdb,xinzweb/gpdb,jmcatamney/gpdb,lisakowen/gpdb,xinzweb/gpdb,xinzweb/gpdb,adam8157/gpdb,50wu/gpdb,lisakowen/gpdb,50wu/gpdb,50wu/gpdb,50wu/gpdb,greenplum-db/gpdb,lisakowen/gpdb,greenplum-db/gpdb,xinzweb/gpdb,50wu/gpdb,greenplum-db/gpdb,jmcatamney/gpdb