[Mesa-dev] [Bug 80848] [dri3] Building mesa fails with dri3 enabled

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Sun Aug 3 07:41:25 PDT 2014


https://bugs.freedesktop.org/show_bug.cgi?id=80848

--- Comment #22 from Emil Velikov <emil.l.velikov at gmail.com> ---
(In reply to comment #21)
> (In reply to comment #20)
> > (In reply to comment #19)
> > > (In reply to comment #18)
> > > > I had cross-compilation problems on Ubuntu (building 32bit Mesa on 64bit
> > > > environment) and my problems went away by reverting
> > > > 
> > > > 3ecd9e1a93817180fa5b280e5fe11c903cca38ba
> > > > 
> > > > For some reason otherwise a wrong version (64bit one) of libexpat got
> > > > included to linking. Patch adds $(EXPAT_LIBS) when linking libloader so that
> > > > is why I tried the revert. I'll try to see why this happens.
> > > 
> > > whoopsie forgot to paste my build command line:
> > > 
> > > INTEL_CFLAGS='-I/opt/include -I/opt/include/libdrm' INTEL_LIBS='-L/opt/lib
> > > -ldrm_intel' CFLAGS='-m32' CXXFLAGS='-m32' ./autogen.sh --prefix=/opt
> > > --enable-gles2 --without-gallium-drivers --enable-32-bit
> > > --with-dri-drivers=i965 --with-egl-platforms=x11 --disable-osmesa
> > > --disable-vdpau --disable-dri3 --enable-debug --enable-glx-tls
> > > --enable-texture-float
> > 
> > I find something a bit disturbing here - why would you set
> > INTEL_{CFLAGS,LIBS} rather than relying on pkg-config ?
> 
> because libdrm is the only library I use from under /opt, rest comes from
> the system
> 
> > Your native arch is x86-64 thus the lack of PKG_CONFIG_PATH is the one
> > causing you problems - pkgconfig looks for the variable (none set) then goes
> > into the default dir which has a .pc file pointing to a 64bit library.
> 
> well, it has been working so far without problems though (and this command
> line actually still works fine on my fedora machine, but on ubuntu it does
> not), libtool takes care of pointing to the correct arch directory
> 
Just because it works (sometimes) it doesn't mean it's a good idea :) Please
migrate to using PKG_CONFIG_PATH which should work consistently for every
platform. It also scales nicely if more things are available in the custom
prefix.

Snippet from the pkg-config man page:
"pkg-config retrieves information about packages from special metadata files.
These files are named after the package, and has a .pc extension. On most
systems,  pkg-config looks in /usr/lib/pkgconfig, /usr/share/pkgconfig, 
/usr/local/lib/pkgconfig and /usr/local/share/pkgconfig for these files. It
will additionally look in the colon-separated (on Windows, semicolon-separated)
list of directories specified by the PKG_CONFIG_PATH environment variable."

> > Or to put things in a different light - please can we avoid shooting mesa in
> > the back by providing any other flags but PKG_CONFIG_PATH, CFLAGS and
> > CXXFLAGS. Thank you
> > 
> > P.S. Things should just work even without C{XX,}FLAGS='-m32' unless we have
> > a bug somewhere :)
> 
> Unfortunately we do, giving '-m32' manually is the only way to get working
> 32bit build because we initialize libtool too early (LT_INIT), here's the
> bug:
> 
> https://bugs.freedesktop.org/show_bug.cgi?id=50754
Thanks I'll look into it.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20140803/b54f7c92/attachment.html>


More information about the mesa-dev mailing list