Date: Mon, 07 May 2018 00:26:11 +0000 From: bugzilla-noreply@freebsd.org To: fortran@FreeBSD.org Subject: [Bug 228007] math/lapack: switch to flang Message-ID: <bug-228007-37611-IudiWrULwH@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-228007-37611@https.bugs.freebsd.org/bugzilla/> References: <bug-228007-37611@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D228007 --- Comment #6 from sgk@troutmask.apl.washington.edu --- (In reply to robert.ayrapetyan from comment #5) > The gfortran's issue I'm talking about is related to: > > ImportError: /lib/libgcc_s.so.1: version GCC_4.6.0 required by > /usr/local> \\/lib/gcc48/libgfortran.so.3 not found from gfortran.so libr= ary That isn't a gfortran issue. This is an issue with FreeBSD's ldd, ldconfig, and the highjacking of a filename. -% gfortran7 -o z h.f90 % ldd z z: libgfortran.so.4 =3D> /usr/local/lib/gcc7/libgfortran.so.4 (0x20064= 5000) libm.so.5 =3D> /lib/libm.so.5 (0x200a17000) libgcc_s.so.1 =3D> /lib/libgcc_s.so.1 (0x200a4b000) libquadmath.so.0 =3D> /usr/local/lib/gcc7/libquadmath.so.0 (0x200a6= 3000) libc.so.7 =3D> /lib/libc.so.7 (0x200ca3000) % ldconfig -r | grep libgcc 6:-lgcc_s.1 =3D> /lib/libgcc_s.so.1 218:-lgccpp-threaded.1 =3D> /usr/local/lib/libgccpp-threaded.so.1 679:-lgccpp.1 =3D> /usr/local/lib/libgccpp.so.1 715:-lgcc_s.1 =3D> /usr/local/lib/gcc7/libgcc_s.so.1 The problem is trivially solved by a number of means. (1) If clang is the system compiler, then rename libgcc_s.so.1 to libclang_s.so.1. It's rather odd that clang uses gcc in the name of an important runtime library. (2) Bump the the major number on FreeBSD's libgcc_s.so.1 from 1 to 2 to indicate that FreeBSD's libgcc_s has nothing to do with GCC. You then have libgcc_s.so.2 and ldd should be able to=20 differentiate between 1 and 2. (3) Use -rpath. (4) Use -Wl to explicitly find the right libgcc_s. This is not a problem with gfortran and naively changing the default to flang is questionable. 1) There is no release version of flang. 2) flang developers do not participate in discussions with users (see crickets on flang-dev list). 3) AFAICT, flang developers do not accept patches from outside of Nvidia. --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-228007-37611-IudiWrULwH>