You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by an...@apache.org on 2018/12/13 04:55:43 UTC

[incubator-mxnet] branch master updated: Set install path for libmxnet.so dynamic lib on Mac OS (#13629)

This is an automated email from the ASF dual-hosted git repository.

anirudh2290 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-mxnet.git


The following commit(s) were added to refs/heads/master by this push:
     new 5d2b763  Set install path for libmxnet.so dynamic lib on Mac OS (#13629)
5d2b763 is described below

commit 5d2b763a2c21ddcf0853a0dd768f88e9b24e7a25
Author: Yuxi Hu <da...@gmail.com>
AuthorDate: Wed Dec 12 20:55:24 2018 -0800

    Set install path for libmxnet.so dynamic lib on Mac OS (#13629)
---
 Makefile | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/Makefile b/Makefile
index 822704e..f15968b 100644
--- a/Makefile
+++ b/Makefile
@@ -486,6 +486,11 @@ build/plugin/%.o: plugin/%.cc
 	@mkdir -p $(@D)
 	$(CXX) -std=c++11 -c $(CFLAGS) -MMD -Isrc/operator -c $< -o $@
 
+# Set install path for libmxnet.so on Mac OS
+ifeq ($(UNAME_S), Darwin)
+        LDFLAGS += -Wl,-install_name,@rpath/libmxnet.so
+endif
+
 # NOTE: to statically link libmxnet.a we need the option
 # --Wl,--whole-archive -lmxnet --Wl,--no-whole-archive
 lib/libmxnet.a: $(ALLX_DEP)