LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   Error compiling compiz plugins with Alien Bob's multilib packages installed (http://www.linuxquestions.org/questions/slackware-14/error-compiling-compiz-plugins-with-alien-bobs-multilib-packages-installed-885793/)

Daedra 06-11-2011 03:57 PM

Error compiling compiz plugins with Alien Bob's multilib packages installed
 
I maintain the compiz packages over at SBo and I recently submitted packages for 13.37. I tested the packages before I submitted them and they compiled fine. I was contacted by the devs a few days ago about the plugins-main,plugins-extra, and emerald packages failing to compile. I immediately tested this and confirmed that it does indeed fail but only if multilib is installed. I figured out it is the glib2-compat32 package that is causing the problem. For some reason the build keeps picking up the libraries in /usr/lib instead of /usr/lib64 even with the LDFLAGS="-L/usr/lib64" set in the build. If I remove the glib2-compat32 package it will build fine, and oddly enough if I compile without the --prefix=/usr flag set it will finish successfully. I decided to test this on 13.1 and had no problems, this leads me to believe that it could possibly be the glib2-compat32 and not compiz, but I doubt it since Alien Bob's stuff is usually bullet proof.

BTW, here is the output wrong about that.
ude/libxml2 -I/usr/include/startup-notification-1.0 -I/usr/include/compiz -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng14 -I/usr/include/pango-1.0 -DDATADIR='"/usr/share/compiz"' -DLIBDIR='"/usr/lib64"' -DLOCALEDIR="\"/usr/share/locale\"" -DIMAGEDIR='"/usr/share/compiz"' -O2 -fPIC -Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -fno-strict-aliasing -MT resizeinfo.lo -MD -MP -MF .deps/resizeinfo.Tpo -c -o resizeinfo.lo resizeinfo.c
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../../include -I/usr/include/libxml2 -I/usr/include/startup-notification-1.0 -I/usr/include/compiz -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng14 -I/usr/include/pango-1.0 -DDATADIR=\"/usr/share/compiz\" -DLIBDIR=\"/usr/lib64\" -DLOCALEDIR=\"/usr/share/locale\" -DIMAGEDIR=\"/usr/share/compiz\" -O2 -fPIC -Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -fno-strict-aliasing -MT resizeinfo.lo -MD -MP -MF .deps/resizeinfo.Tpo -c resizeinfo.c -fPIC -DPIC -o .libs/resizeinfo.o
In file included from /usr/include/glib-2.0/glib/gasyncqueue.h:34:0,
from /usr/include/glib-2.0/glib.h:34,
from /usr/include/pango-1.0/pango/pango-coverage.h:25,
from /usr/include/pango-1.0/pango/pango-font.h:25,
from /usr/include/pango-1.0/pango/pango-attributes.h:25,
from /usr/include/pango-1.0/pango/pango.h:25,
from resizeinfo.c:33:
/usr/include/glib-2.0/glib/gthread.h: In function ‘g_once_init_enter’:
/usr/include/glib-2.0/glib/gthread.h:347:3: error: size of unnamed array is negative
make[4]: *** [resizeinfo.lo] Error 1
make[4]: Leaving directory `/tmp/SBo/compiz-plugins-main-0.8.8/src/resizeinfo'
make[3]: *** [all] Error 2
make[3]: Leaving directory `/tmp/SBo/compiz-plugins-main-0.8.8/src/resizeinfo'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/tmp/SBo/compiz-plugins-main-0.8.8/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/tmp/SBo/compiz-plugins-main-0.8.8'
make: *** [all] Error 2
root@Slackware64:/rm/compiz/compiz-plugins-main#

disturbed1 06-12-2011 02:23 AM

Should be able to pass /usr/lib$LIBSUFFIXDIR/glib-2.0/include either in configure or as linker flags.

disturbed1 06-12-2011 04:07 AM

Looks like the problem is with configure. It's hard coded to search /usr/lib/pkgconfig before any other directory. This causes pango and cairo to look in the wrong directories. Every where else, it honors $LIBDIR, but not here.

On or around line 12991.
Even if you pass or export PKG_CONFIG_PATH, this is used as the last search path. Slackware does have the correct search paths set by default (/usr/local/lib64/pkgconfig:/usr/lib64/pkgconfig).

I'd file an upstream bug report with compiz.

I did a dirty sed hack on configure which allowed plugins-main to finish compiling.

Daedra 06-12-2011 09:16 AM

Cool man, Just out of curiosity could you post the sed hack you did? I tried it myself but I am screwing it up somehow. Your fix did work cause I made a quick patch, but I not too familiar with sed and I am messing it up somehow?

Thanks


P.S. Nevermind I got it, sed hack is working now. Big thanks again man.

zeroberto 07-25-2011 05:31 AM

Can somebody explain that sed thing, please? I get this very often:
/usr/include/glib-2.0/glib/gthread.h: In function ‘g_once_init_enter’:
/usr/include/glib-2.0/glib/gthread.h:347:3: error: size of unnamed array is negative

Removing the glib2-compat32 helps, but I'm annoyed to do that every time.
Thanks.

ponce 07-25-2011 05:54 AM

Daedra already submitted this to slackbuilds.org, latest script should work fine.


All times are GMT -5. The time now is 02:56 PM.