zzningxp commented on issue #2027: [lib/libmxnet.so] Error installing mxnet for EI Capitan 10.11.4 URL: https://github.com/apache/incubator-mxnet/issues/2027#issuecomment-326478495 I ran into the same issue with Macbook Pro late 2015, 10.12.3 Sierra, gcc-7. I believe that the issue is cause by two versions of OpenCV (2.4.13 and 3.2), because I ran into OpenCV issue several times on my MBP. So, I tried 2.4.13.2 and 3.20 and HEAD-3649ee3, and only 2.4.13 works, with g++/clang++, not g++-7. ``` mxnet daodao$ g++ --version Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1 Apple LLVM version 8.1.0 (clang-802.0.42) Target: x86_64-apple-darwin16.4.0 Thread model: posix InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin ``` The most important thing here is to setup OpenCV version explicitly: ``` # setup opencv ifeq ($(USE_OPENCV), 1) CFLAGS += -DMXNET_USE_OPENCV=1 -I/usr/local/Cellar/opencv/2.4.13.2/include -I/usr/local/include LDFLAGS += $(filter-out -lopencv_ts, -L/usr/local/Cellar/opencv/2.4.13.2/lib -lopencv_shape -lopencv_stitching -lopencv_objdetect -lopencv_superres -lopencv_videostab -lopencv_calib3d -lopencv_features2d -lopencv_highgui -lopencv_videoio -lopencv_imgcodecs -lopencv_video -lopencv_photo -lopencv_ml -lopencv_imgproc -lopencv_flann -lopencv_core) #CFLAGS += -DMXNET_USE_OPENCV=1 $(shell pkg-config --cflags opencv) #LDFLAGS += $(filter-out -lopencv_ts, $(shell pkg-config --libs opencv)) BIN += bin/im2rec else CFLAGS+= -DMXNET_USE_OPENCV=0 endif ``` ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org
With regards, Apache Git Services