From 08e204a6babe4af040e232260a59fe19a02a5ba1 Mon Sep 17 00:00:00 2001 From: Jürgen Knödlseder Date: Sat, 9 Jul 2016 16:19:32 +0200 Subject: [PATCH] Enhance the El Capitan Python module post processing --- pyext/Makefile.am | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/pyext/Makefile.am b/pyext/Makefile.am index 8150e50..b60d079 100755 --- a/pyext/Makefile.am +++ b/pyext/Makefile.am @@ -131,16 +131,23 @@ build: $(BUILT_SOURCES) $(PYTHON) setup.py build if IS_ELCAPITAN -for f in build/ctools/ctools/_*.so; do \ - echo "Post process module "$$f; \ - install_name_tool -change $(libdir)/libctools.1.dylib @rpath/libctools.1.dylib $$f; \ - install_name_tool -change $(libdir)/libgamma.2.dylib @rpath/libgamma.2.dylib $$f; \ - install_name_tool -add_rpath $(libdir) $$f; \ + echo "Build post process Python module "$$f; \ + libgamma=`otool -L $$f | grep -o libgamma.*.dylib`; \ + libctools=`otool -L $$f | grep -o libctools.*.dylib`; \ + install_name_tool -change $(libdir)/$$libctools @rpath/$$libctools $$f; \ + install_name_tool -change $(libdir)/$$libgamma @rpath/$$libgamma $$f; \ install_name_tool -add_rpath $(abs_top_builddir)/src/.libs $$f; \ done endif # Install the ctools Python module install-exec-local: +if IS_ELCAPITAN + -for f in build/ctools/ctools/_*.so; do \ + echo "Install pre process Python module "$$f; \ + install_name_tool -rpath $(abs_top_builddir)/src/.libs $(libdir) $$f; \ + done +endif $(PYTHON) setup.py install --prefix=$(DESTDIR)$(prefix) # Uninstall the ctools Python module -- libgit2 0.21.4