summaryrefslogtreecommitdiff
path: root/math/R
diff options
context:
space:
mode:
authorjperkin <jperkin>2016-02-29 20:05:00 +0000
committerjperkin <jperkin>2016-02-29 20:05:00 +0000
commit7a4cdecc2f9df9bcdc64c75fe9ff2b2aef2b23ab (patch)
treef78289b9f4a7464df4ecc07f4fff787091d88ba3 /math/R
parent64fe40dfe21ae98ced0c02facbee3a0e6aee7a10 (diff)
downloadpkgsrc-7a4cdecc2f9df9bcdc64c75fe9ff2b2aef2b23ab.tar.gz
Apply Darwin install_name fix to R extensions.
Diffstat (limited to 'math/R')
-rw-r--r--math/R/Makefile.extension15
1 files changed, 14 insertions, 1 deletions
diff --git a/math/R/Makefile.extension b/math/R/Makefile.extension
index e195b07d7fb..c7ee161b3c7 100644
--- a/math/R/Makefile.extension
+++ b/math/R/Makefile.extension
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.extension,v 1.19 2014/10/09 14:06:41 wiz Exp $
+# $NetBSD: Makefile.extension,v 1.20 2016/02/29 20:05:00 jperkin Exp $
#
# This Makefile fragment is included by packages for R library packages.
#
@@ -26,6 +26,19 @@ do-install:
${PKGSRC_SETENV} ${INSTALL_ENV} ${MAKE_ENV} ${LOCALBASE}/bin/R \
CMD INSTALL ${R_PKG_INSTALL_ARGS} ${WRKDIR}/${R_PKGNAME}
+.include "../../mk/bsd.fast.prefs.mk"
+
+.if ${OPSYS} == "Darwin"
+.PHONY: fix-darwin-install-name
+post-install: fix-darwin-install-name
+fix-darwin-install-name:
+ ${FIND} ${DESTDIR}${PREFIX} -name "*.so" | while read lib; do \
+ libname=`basename $${lib}`; \
+ libdir=`dirname $${lib} | sed -e 's,${DESTDIR},,'`; \
+ install_name_tool -id $${libdir}/$${libname} $${lib}; \
+ done
+.endif
+
R_LIB= lib/R/library
R_INST_DIRS?= ${R_PKGNAME}
R_HOMEPAGE_BASE= http://cran.r-project.org/web/packages