Created attachment 332084 [details] clapack-3.2.1_build.log When trying to rebuild clapack-3.2.1-r6 on my laptop, after installing sci-libs/mkl-11.0.0.079, I get two type of errors: 1) At the end, after 100%, when eselect for blas, cblas and lapack is set for mkl64-int64-intel: ------------- ...CMakeFiles/clapack.dir/iladiag.c.o CMakeFiles/clapack.dir/chla_transtype.c.o CMakeFiles/clapack.dir/__/INSTALL/ilaver.c.o CMakeFiles/clapack.dir/__/INSTALL/lsame.c.o -lmkl_intel_ilp64 -lmkl_sequential -lmkl_core -lpthread -lf2c -lm ld: cannot find -lmkl_intel_ilp64 ld: cannot find -lmkl_sequential ld: cannot find -lmkl_core make[2]: *** [SRC/libclapack.so.3.2.1] Error 1 2) This error with mkl64-int64-dynamic ------------- ...CMakeFiles/clapack.dir/iladiag.c.o CMakeFiles/clapack.dir/chla_transtype.c.o CMakeFiles/. clapack.dir/__/INSTALL/ilaver.c.o CMakeFiles/clapack.dir/__/INSTALL/lsame.c.o -lmkl_rt -lpthread -lf2c -lm ld: cannot find -lmkl_rt make[2]: *** [SRC/libclapack.so.3.2.1] Error 1 I attach one of the builds as an example. Other eselect profiles give either one of the above errors. The failure happens with both icc and gcc. However, what surprises me the most is that I have another desktop box where the clapack rebuild successfully compiles. I will be happy to provide as much information as you may request.
looks like broken pc files. I will look into that.
broken but differently: >>> Source compiled. * Testing of dev-python/oct2py-0.3.6 with CPython 2.6... PYTHONPATH=build-2.6/lib nosetests --verbosity=1 ..............................FF........F. ====================================================================== FAIL: Send an ndarray and make sure we get the same array back ---------------------------------------------------------------------- Traceback (most recent call last): File "/var/tmp/portage/dev-python/oct2py-0.3.6/work/oct2py-0.3.6/oct2py/tests/test_oct2py.py", line 446, in test_ndarrays self.assertRaises(Oct2PyError, octave.roundtrip, outgoing) AssertionError: Oct2PyError not raised ====================================================================== FAIL: Send a scalar numpy type and make sure we get the same number back. ---------------------------------------------------------------------- Traceback (most recent call last): File "/var/tmp/portage/dev-python/oct2py-0.3.6/work/oct2py-0.3.6/oct2py/tests/test_oct2py.py", line 416, in test_scalars self.assertRaises(Oct2PyError, octave.roundtrip, outgoing) AssertionError: Oct2PyError not raised ====================================================================== FAIL: Test roundtrip python type conversions ---------------------------------------------------------------------- Traceback (most recent call last): File "/var/tmp/portage/dev-python/oct2py-0.3.6/work/oct2py-0.3.6/oct2py/tests/test_oct2py.py", line 77, in test_python_conversions self.assertEqual(octave_type, oct_type) AssertionError: u'int64' != 'int32' ---------------------------------------------------------------------- Ran 42 tests in 4.285s FAILED (failures=3) * ERROR: dev-python/oct2py-0.3.6 failed (test phase): * Testing failed with CPython 2.6 in python_test_function() function * * Call stack: * ebuild.sh, line 93: Called src_test * environment, line 3925: Called distutils_src_test * environment, line 1347: Called python_execute_nosetests '-P' '$(_distutils_get_PYTHONPATH)' '--' * environment, line 2345: Called python_execute_function 'python_test_function' * environment, line 2280: Called die * The specific snippet of code: * die "${failure_message}"; *
oh wrong bug
I just recalled it works on my desktop box because I manually set the following symlink: lrwxrwxrwx 1 root root 61 dic 5 13:15 /usr/lib/libmkl_rt.so -> /opt/intel/composerxe-2013.0.079/mkl/lib/intel64/libmkl_rt.so After making the same symlink on my laptop clapack compiled on it, too. However, I don't like this workaround very much. I'd rather see clapack compiling by finding libmkl_rt.so through the corresponding eselect choice.
(In reply to comment #4) > I just recalled it works on my desktop box because I manually set the > following symlink: > lrwxrwxrwx 1 root root 61 dic 5 13:15 /usr/lib/libmkl_rt.so -> > /opt/intel/composerxe-2013.0.079/mkl/lib/intel64/libmkl_rt.so > > After making the same symlink on my laptop clapack compiled on it, too. > > However, I don't like this workaround very much. I'd rather see clapack > compiling by finding libmkl_rt.so through the corresponding eselect choice. If you such things, it will be hard for us to support problems in future. This is a bug in sci-libs/mkl and need to befixed, but not worked around like you are doing. Better solution would be to add -L/opt/intel/composerxe-2013.0.079/mkl/lib/intel64/ teemporarily to your LDFALGS.
You're absolutely right. That's why I guessed I didn't like my own workaround. Your answer comes from an educated programming perspective, whilst mine came from absolute desperation :) I will do as you say as a temporary measure. How do I do that? By adding the following line to /etc/make.conf? LDFLAGS="${LDFLAGS} -L/opt/intel/composerxe-2013.0.079/mkl/lib/intel64/"
Just from the command line LDFLAGS="${LDFLAGS} -L/opt/intel/composerxe-2013.0.079/mkl/lib/intel64/" emerge clapack
Could you please show me following output eselect blas list eselect cblas list eselect lapack list pkg-config --libs blas pkg-config --libs cblas pkg-config --libs lapack
(In reply to comment #8) > Could you please show me following output > > eselect blas list Available providers for blas: [1] mkl32-dynamic [2] mkl32-dynamic-openmp [3] mkl32-gfortran [4] mkl32-gfortran-openmp [5] mkl32-intel [6] mkl32-intel-openmp [7] mkl64-dynamic * [8] mkl64-dynamic-openmp [9] mkl64-gfortran [10] mkl64-gfortran-openmp [11] mkl64-int64-dynamic [12] mkl64-int64-dynamic-openmp [13] mkl64-int64-gfortran [14] mkl64-int64-gfortran-openmp [15] mkl64-int64-intel [16] mkl64-int64-intel-openmp [17] mkl64-intel [18] mkl64-intel-openmp > eselect cblas list Available providers for cblas: [1] gsl [2] mkl32-dynamic [3] mkl32-dynamic-openmp [4] mkl32-gcc-openmp [5] mkl32-intel [6] mkl32-intel-openmp [7] mkl64-dynamic * [8] mkl64-dynamic-openmp [9] mkl64-gcc-openmp [10] mkl64-int64-dynamic [11] mkl64-int64-dynamic-openmp [12] mkl64-int64-gcc-openmp [13] mkl64-int64-intel [14] mkl64-int64-intel-openmp [15] mkl64-intel [16] mkl64-intel-openmp > eselect lapack list Available providers for lapack: [1] mkl32-dynamic [2] mkl32-dynamic-openmp [3] mkl32-gfortran [4] mkl32-gfortran-openmp [5] mkl32-intel [6] mkl32-intel-openmp [7] mkl64-dynamic * [8] mkl64-dynamic-openmp [9] mkl64-gfortran [10] mkl64-gfortran-openmp [11] mkl64-int64-dynamic [12] mkl64-int64-dynamic-openmp [13] mkl64-int64-gfortran [14] mkl64-int64-gfortran-openmp [15] mkl64-int64-intel [16] mkl64-int64-intel-openmp [17] mkl64-intel [18] mkl64-intel-openmp > pkg-config --libs blas -L/opt/intel/composerxe-2013.0.079/mkl/lib/intel64 -lmkl_rt -lpthread > pkg-config --libs cblas -L/opt/intel/composerxe-2013.0.079/mkl/lib/intel64 -lmkl_rt -lpthread > pkg-config --libs lapack -L/opt/intel/composerxe-2013.0.079/mkl/lib/intel64 -lmkl_rt -lpthread I had already executed the above pkg-config commands on my boxes.
(In reply to comment #7) > Just from the command line > > LDFLAGS="${LDFLAGS} -L/opt/intel/composerxe-2013.0.079/mkl/lib/intel64/" > emerge clapack Removing the symlink and issuing the above command worked.
+*clapack-3.2.1-r7 (12 Dec 2012) + + 12 Dec 2012; Justin Lecher <jlec@gentoo.org> +clapack-3.2.1-r7.ebuild, + +files/clapack-3.2.1-findblas-r7.patch, metadata.xml: + Add libdir path to linker flags, #446930; don't build testsuite with fPIC +
Thanks very much. It worked like a charm. Oh! And thank you also for updating mkl to the latest version as a bonus. I really appreciate it.