opscode/omnibus-software — pull request #339 by kaustubh-d (2014-11-12 17:12:00+00:00)
Title: Fix issue where ruby mkmf is setting libpath.

**In-Progress**

Programs invoked from within embedded ruby during extension build for example xlc end up looking for dependencies (so's) in wrong path due to LIBPATH being set by mkmf.rb.

Patch mkmf to not set libpath when extensions are built, as we already set the necessary paths using -blibpath and LD_RUN_PATH to be picked up during the actual build process for extensions.

All binaries and shared objects built in the chef embedded ruby build have correct paths embedded with binary headers. example
dump -H -X64 /opt/chef/embedded/lib/libruby.so
...
INDEX PATH BASE MEMBER
0 /opt/chef/embedded/lib:/usr/lib:/lib
...