rhash: Fix broken RPATH info on darwin

The PREFIX variable in the makefiles is directly used to construct the
install name on the library metadata on darwin.  If not passed, the
default /usr/local is used and the resulting librhash.dylib contains
usage informaiton of /usr/local/lib/librhash.0.dylib.  This adds the
PREFIX= variable directly to the make command so the resulting usage
metadata contains the correct valid library path.
This commit is contained in:
Chuck Atkins 2019-01-29 12:13:46 -05:00 committed by Peter Scheibel
parent 67a1e56e4d
commit b7c31cb561

View file

@ -23,12 +23,12 @@ class Rhash(MakefilePackage):
def build(self, spec, prefix):
# Doesn't build shared libraries by default
make()
make('PREFIX={0}'.format(prefix))
if spec.satisfies('platform=darwin'):
make('-C', 'librhash', 'dylib')
make('PREFIX={0}'.format(prefix), '-C', 'librhash', 'dylib')
else:
make('lib-shared')
make('PREFIX={0}'.format(prefix), 'lib-shared')
def check(self):
# Makefile has both `test` and `check` targets: