Building Julia 0.6.0 with MKL on OSX 10.12.5


I am new to this so please forgive my naive approach.

I have been trying to build Julia using the intel MKL in addition to the intel c++ and fortran compilers on OS X 10.12.5. However, I have been running into a bunch of errors, which I suspect is a result of me digging myself into a deeper hole rather than solving the underlying problem(s).

Since I am new, I did a sanity check and built Julia from the most recent stable source, which appears to have worked fine (I can launch julia and use it to confirm that 1+1 indeed equals 2).

To then build with the intel math library and compilers, in the command line I entered:
source /opt/intel/mkl/bin/ intel64 ilp64

Then I made a Make.user file containing the following:


When I enter the make command I immediately get the error:
julia/ *** USE_LIBCPP only supported with clang. Try setting USE_LIBCPP=0. Stop.

However, adding in USE_LIBCPP=0 into the Make.user file does not resolve this error.

In an attempt to get around this problem, I added in the line
override USE_LIBCPP=0
into my Make.user file.

While this indeed gets the building to start moving, I see a very large number of warning messages while building CXX objects where the following warning numbers appear to be repeated over an over again:

warning #1292: unknown attribute "returns_nonnull"
warning #2026: Effective C++ Item 14 Make sure base classes FoldingSetImpl have virtual destructors

and eventually it terminates on the following error:

configure: error: compiler does not halt on function prototype mismatch.
make[1]: *** [scratch/curl-7.53.1/build-configured] Error 1
make: *** [julia-deps] Error 2

If anyone can provide some advice on how to get around this problem, I would greatly appreciate it!

Do you really need to built with the intel compilers? You can use MKL anyway.

1 Like

I was under the impression that the intel compilers would improve performance, is that not true?

Assuming that these compilers are not needed, I changed the Make.user file to just the following


However I now get the following error

Undefined symbols for architecture x86_64:
"__intel_fast_memcpy", referenced from:
_amd_2 in libamd.a(amd_i_2.o)
_amd_l2 in libamd.a(amd_l_2.o)
"__intel_fast_memset", referenced from:
_amd_aat in libamd.a(amd_i_aat.o)
_amd_postorder in libamd.a(amd_i_postorder.o)
_amd_l_aat in libamd.a(amd_l_aat.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [/Applications/julia/usr/manifest/suitesparse] Error 1
make: *** [julia-deps] Error 2

If you are working in the same directory where you started, it is probably necessary to run make distclean-suitesparse (and quite likely make distcleanall) to clean the existing (partial?) builds started with ICC.

1 Like

Code generation is doen by LLVM so runtime performance AFAIU, run time performance should not depend on what you use to compile LLVM / Julia with.

1 Like

Indeed that was the problem there! I now have a new bug:

LoadError(“sysimg.jl”, 362, LoadError(“sparse/sparse.jl”, 41, LoadError(“sparse/umfpack.jl”, 61, ErrorException(“error compiling anonymous: could not load library “libsuitesparse_wrapper”\ndlopen(libsuitesparse_wrapper.dylib, 1): Library not loaded: @rpath/libmkl_rt.dylib\n Referenced from: /Applications/julia/usr/lib/libcholmod.dylib\n Reason: image not found”))))
*** This error is usually fixed by running make clean. If the error persists, try make cleanall. ***
make[1]: *** [/Applications/julia/usr/lib/julia/sys.o] Error 1
make: *** [julia-sysimg-release] Error 2

I have run both make clean and make cleanall but the error message persists. I thought that perhaps there was something still lingering from my previous build attempts, so I deleted everything and started with a fresh directory. However, I still get this error.

Just an update. I tried building with the intel compilers on Ubuntu 16.04.2 LTS and also ran into some problems there, although the errors were unrelated to what I saw in OSX. However, unlike in OSX, I was able to build and install with a Make.user file that just contained USE_INTEL_MKL = 1

I am wondering then, are the directions listed in the readme file for building with the intel compilers and MKL no longer valid due to changes in 0.6? Or have I just had a run of bad luck?

Building with Intel compilers is not something we have the infrastructure to test automatically, so it tends to be easy to break by accident.

1 Like

Is it going to change according to this - ANN: The JuliaPro distribution by Julia Computing?

I know chances are slim and most chances it was about the Pro Version which costs money.
But better be optimistic :-).