Description of problem: Package shogun fails to build from source in Fedora rawhide (on all archs) and Fedora 26/27 (on aarch64). Error on Rawhide: make[2]: Leaving directory '/builddir/build/BUILD/shogun-6.0.0/x86_64-redhat-linux-gnu' //usr/lib64/liblapacke.so.3: undefined reference to `ssytrs_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `ssytrf_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `dsytrf_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `chetrf_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `chetrs_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `zsytrf_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `zhetrs_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `ssysv_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `csytrf_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `zhetrf_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `dsytrs_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `csytrs_aa_2stage_' //usr/lib64/liblapacke.so.3: undefined reference to `zsytrs_aa_2stage_' collect2: error: ld returned 1 exit status make[2]: *** [examples/undocumented/libshogun/CMakeFiles/transfer_multitaskleastsquaresregression.dir/build.make:107: examples/undocumented/libshogun/transfer_multitaskleastsquaresregression] Error 1 make[1]: *** [CMakeFiles/Makefile2:3773: examples/undocumented/libshogun/CMakeFiles/transfer_multitaskleastsquaresregression.dir/all] Error 2 make[1]: *** Waiting for unfinished jobs.... make[2]: Entering directory '/builddir/build/BUILD/shogun-6.0.0/x86_64-redhat-linux-gnu' Steps to Reproduce: koji build --scratch f28 shogun-6.0.0-5.fc27.src.rpm Additional info: This package is tracked by Koschei. See: http://apps.fedoraproject.org/koschei/package/shogun A difference between working and failing build root is listed on https://apps.fedoraproject.org/koschei/build/3754245
This is clearly an error with lapack, as it misses to link some needed symbols during build. Assigning this to lapack.
I'm not sure that's right. shogun seems to be trying to use atlas's lapack library (/usr/lib64/atlas/libtatlas.so) and the lapacke library (/usr/lib64/liblapacke.so) from the lapack package. The missing symbols (*_aa_2stage*) are all present in the lapack library (/usr/lib64/liblapack.so) from the lapack package: [spot@localhost ~]$ eu-readelf -s /usr/lib64/liblapack.so |grep _aa_2stage 312: 00000000005408e0 845 FUNC GLOBAL DEFAULT 12 zsysv_aa_2stage_ 401: 000000000031e5b0 845 FUNC GLOBAL DEFAULT 12 chesv_aa_2stage_ 648: 00000000000e9040 837 FUNC GLOBAL DEFAULT 12 ssysv_aa_2stage_ 681: 00000000000e9390 8128 FUNC GLOBAL DEFAULT 12 ssytrf_aa_2stage_ 1139: 00000000000eb350 1406 FUNC GLOBAL DEFAULT 12 ssytrs_aa_2stage_ 1156: 0000000000540c30 9306 FUNC GLOBAL DEFAULT 12 zsytrf_aa_2stage_ 1340: 00000000004a74d0 1414 FUNC GLOBAL DEFAULT 12 zhetrs_aa_2stage_ 1525: 00000000004a4ed0 9713 FUNC GLOBAL DEFAULT 12 zhetrf_aa_2stage_ 1576: 00000000003b7190 8820 FUNC GLOBAL DEFAULT 12 csytrf_aa_2stage_ 1582: 0000000000224f50 837 FUNC GLOBAL DEFAULT 12 dsysv_aa_2stage_ 1602: 0000000000543090 1414 FUNC GLOBAL DEFAULT 12 zsytrs_aa_2stage_ 1748: 0000000000227260 1406 FUNC GLOBAL DEFAULT 12 dsytrs_aa_2stage_ 1775: 0000000000320c90 1406 FUNC GLOBAL DEFAULT 12 chetrs_aa_2stage_ 1898: 00000000003b6e40 845 FUNC GLOBAL DEFAULT 12 csysv_aa_2stage_ 1907: 00000000002252a0 8128 FUNC GLOBAL DEFAULT 12 dsytrf_aa_2stage_ 1929: 000000000031e900 9103 FUNC GLOBAL DEFAULT 12 chetrf_aa_2stage_ 2006: 00000000004a4b80 845 FUNC GLOBAL DEFAULT 12 zhesv_aa_2stage_ 2025: 00000000003b9410 1406 FUNC GLOBAL DEFAULT 12 csytrs_aa_2stage_ Now, there is a bug in libcblas.so where I forgot to compile in some files, which will be fixed in the next lapack build. When I build shogun without atlas (and the fixed cblas) (removing BuildRequires: atlas-devel, setting -DUSE_ORIGINAL_LAPACK=ON, and adding a patch to help shogun find the cblas include header files), it builds successfully and passes all of its tests. I'll attach my shogun.spec file and patch so that you can see exactly what I'm talking about. I think if you want to mix lapacke with atlas's lapack, you will need to have atlas implement the *_aa_2stage* functions.
Created attachment 1377053 [details] fix cmake file so that cblas looks for (and uses) includedirs
Created attachment 1377054 [details] shogun spec with cblas patch applied and atlas support disabled
Thank you for the patches! =)
This bug appears to have been reported against 'rawhide' during the Fedora 28 development cycle. Changing version to '28'.
Hi Björn. Will these patches be applied soon? Thanks.
Created attachment 1442775 [details] build.log
Created attachment 1442776 [details] root.log
Created attachment 1442777 [details] state.log
I added a couple of patches (-json-c_deprecated and -pybtex_bug) to fix the build in Rawhide, due to needed to rebuild it against a newer glpk. I will not be doing the same for F28.
I'm trying build update to 6.1.3 [1] but still fails on documentation , anyway I did many work that you can use, please. Thanks [1] https://src.fedoraproject.org/fork/sergiomb/rpms/shogun/commits/master
shogun-6.0.0-14.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2019-433a3e489f
shogun-6.0.0-14.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-433a3e489f
shogun-6.0.0-14.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.