On 12/16/2015 10:28, Raphael Kubo da Costa wrote: > Kris Moore <[email protected]> writes: > >> Hey, I noticed a problem with some Qt apps crashing here on PC-BSD, >> which uses LibreSSL. Specifically I traced the issue to Qt dynamically >> loading libssl.so.37.0.0 from /usr/local/lib and then also loading >> libressl.so from /usr/lib, causing quite a nasty segfault :P >> >> We are using the following patch to fix the issue in PC-BSD: >> >> https://github.com/pcbsd/freebsd-ports/commit/bcdf67898049e49a9cf1c7398c91c416445f8ea6 >> >> Just wanted to pass this along, since you may want to patch this in >> FreeBSD ports as well. If you come up with a better solution, let me know. > Hi, Kris, > > I'm still trying to understand the issue here. Was it so that a program > linking against Qt also linked against LibreSSL (installed in > /usr/local) tried to do some SSL work, which then caused Qt to load > OpenSSL from /usr? If so, doesn't your patch break the opposite case > (a program only links against OpenSSL from /usr, Qt then ends up loading > LibreSSL from /usr/local)? Or is PC-BSD controlling the environment so > that this is unsupported and not supposed to happen?
The issue was this: We build *all* our packages against LibreSSL (but this would occur with OpenSSL from ports as well) In the case of a package like Mumble, it would link against /usr/local/lib/libssl.so.XX, so far so good. Starting the app would work initially, but when it went to do any openssl stuff via Qt, it would then dynamically load the SSL library again, and *default* to the base system version, leading to a SegFault when trying to mix the libraries. So yes, this patch may break in the reverse case now, if you build against base system SSL, but libssl exists in /usr/local/lib. I'm not sure if we should just patch the heck out of Qt to load libs some other way, or set a policy of having all packages use Open/LibreSSL from ports as we do in PC-BSD. -- Kris Moore PC-BSD Software / iXsystems Enterprise Storage & Servers Driven By Open Source _______________________________________________ kde-freebsd mailing list [email protected] https://mail.kde.org/mailman/listinfo/kde-freebsd See also http://freebsd.kde.org/ for latest information
