[Mesa-dev] [PATCH] configure: Trust LLVM >= 4.0 llvm-config --libs for shared libraries

Jan Vesely jan.vesely at rutgers.edu
Thu Aug 10 17:13:50 UTC 2017


On Thu, 2017-08-10 at 17:45 +0100, Emil Velikov wrote:
> On 9 August 2017 at 02:00, Michel Dänzer <michel at daenzer.net> wrote:
> > On 09/08/17 03:24 AM, Emil Velikov wrote:
> > > On 8 August 2017 at 08:23, Michel Dänzer <michel at daenzer.net> wrote:
> > > > From: Michel Dänzer <michel.daenzer at amd.com>
> > > > 
> > > > No need to manually look for the library files anymore with current
> > > > LLVM. This sidesteps the manual method failing when LLVM was built with
> > > > -DLLVM_APPEND_VC_REV=ON.
> > > > 
> > > 
> > > IIRC you recently spotted that the Suse packaging was building LLVM
> > > with separate shared libraries.
> > 
> > Apparently that's getting fixed though.
> > 
> > 
> > > This is something which gets flagged with this (admittedly) quirky test.
> > 
> > What do you mean by that?
> > 
> > I just double-checked that Mesa with this patch still builds fine
> > against LLVM built with BUILD_SHARED_LIBS=ON, just like without it.
> > 
> 
> Right, I miss-remembered what the else block does.
> Thanks for the correction.
> 
> Topic for another thread:
> There's been a handful of issues reported with BUILD_SHARED_LIBS=ON.
> Should we consider that unsupported setup and error out?

please no.
BUILD_SHARED_LIBS=ON is a must for development setup
debug build of clang + llvm takes 1.4GB, each. Having a ~2.8GB library,
is a really bad idea for testing, not to mention linking time that goes
well into minutes for even a minor change in LLVM.

Jan

> 
> > 
> > > I think we'd want to keep the best of both - just not sure how to
> > > exactly do that.
> > > --libs/--libfiles was completely busted with LLVM 3.9 and is back to
> > > normal with 4.0.
> > > 
> > > Could we use that somehow?
> > 
> > This patch relies on llvm-config --libs with LLVM >= 4.0. If you mean
> > something else, please be more specific.
> > 
> 
> That's the thing - in some versions --libs is busted while for others
> --libs/--libfiles.
> There isn't a thing we could reliably check across the board, so I was
> hoping you know of something.
> 
> That said, patch does exactly what it says on the
> Reviewed-by: Emil Velikov <emil.velikov at collabora.com>
> 
> -Emil
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20170810/cac09b83/attachment.sig>


More information about the mesa-dev mailing list