On 10.07.19 22:07, Gaius Mulley wrote: > Matthias Klose <d...@ubuntu.com> writes: > >> On 09.07.19 23:30, Matthias Klose wrote: >>> On 09.07.19 21:48, Gaius Mulley wrote: >>>> Matthias Klose <d...@ubuntu.com> writes: >>>> >>>>>> - libpth.{a,so} is installed in the system libdir, which >>>>>> conflicts with the installation of the libpth packages >>>>>> on most distros. >>>>> >>>>> found out that a system provided libpth can be used. Otoh if you build >>>>> the >>>>> in-tree libpth, it shouldn't be installed, but built as a convenience >>>>> library, >>>>> like libgo using libffi, or libgphobos using zlib. >>>> >>>> Hi Matthias, >>>> >>>> as far as I know Redhat doesn't support libpth-dev - therefore it was >>>> decided to include libpth in the gm2 tree and autodetect build/install >>>> it as necessary. >>> >>> That's ok, but then please don't install it as a system library. that's >>> what >>> convenience libraries are for (a libpth.a built with -fPIC, which you can >>> link >>> against). >> >> I still think installing libpth is wrong, however currently all multilib >> variants install into $libdir, and not into the system multilib dir, e.g. >> lib64, >> lib32, ... So the last multilib wins, and you end up with the wrong arch in >> your $libdir. > > Hi Matthias, > > ah thanks for the explanation. The multilib build system is still new > to me. So regarding the libpth issue, what happens if the native os > does not provide libpth? From your experience with building multilib > and shared library packages on multiple platforms - what is the best > solution :-)
I don't know about a best solution, but I contributed changes to DRUNTIME_LIBRARIES_ZLIB in libphobos/m4/druntime/libraries.m4 and gcc/doc/install.texi (--with-target-system-zlib). Or you look at libffi/libgo, with libgo always linking the convenience libffi library. Matthias