LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Error building gnome-power-manager 2.30 (https://www.linuxquestions.org/questions/slackware-14/error-building-gnome-power-manager-2-30-a-809098/)

Geriao 05-20-2010 10:50 AM

Error building gnome-power-manager 2.30
 
I use Slackware 13.0 with the 2.6.33.2 kernel, and I use GnomeSlackbuild.
I tried to get help on their discussion group, but I didn't get any.

I'm trying to build gnome-power-manager 2.30, because it uses the new upower interface (so it seems). I have GTK+ 2.18.9.

But when I try and compile it, I get this:

Code:

make  all-recursive
make[1]: Entering directory `/home/thales/downloads/builds/gnome-power-manager/gnome-power-manager-2.30.0'
Making all in src
make[2]: Entering directory `/home/thales/downloads/builds/gnome-power-manager/gnome-power-manager-2.30.0/src'
make  all-am
make[3]: Entering directory `/home/thales/downloads/builds/gnome-power-manager/gnome-power-manager-2.30.0/src'
  CCLD  gnome-power-manager
libtool: link: warning: library `/usr/local/lib/libuuid.la' was moved.
libtool: link: warning: library `/usr/local/lib/libuuid.la' was moved.
libtool: link: warning: library `/usr/local/lib/libuuid.la' was moved.
/usr/lib/gcc/i486-slackware-linux/4.3.3/../../../../i486-slackware-linux/bin/ld: warning: libltdl.so.7, needed by /usr/lib/libcanberra-gtk.so, may conflict with libltdl.so.3
gnome_power_manager-gsd-media-keys-window.o: In function `fade_timeout':
/home/thales/builds/gnome-power-manager/gnome-power-manager-2.30.0/src/gsd-media-keys-window.c:80: undefined reference to `gtk_widget_get_allocation'
gnome_power_manager-gsd-media-keys-window.o: In function `gsd_media_keys_window_real_realize':
/home/thales/builds/gnome-power-manager/gnome-power-manager-2.30.0/src/gsd-media-keys-window.c:974: undefined reference to `gtk_widget_get_allocation'
collect2: ld returned 1 exit status
make[3]: *** [gnome-power-manager] Error 1
make[3]: Leaving directory `/home/thales/downloads/builds/gnome-power-manager/gnome-power-manager-2.30.0/src'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/thales/downloads/builds/gnome-power-manager/gnome-power-manager-2.30.0/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/thales/downloads/builds/gnome-power-manager/gnome-power-manager-2.30.0'
make: *** [all] Error 2

I checked /usr/local/include/gtk-2.0/gtk/gtkwidget.h, and there is a function declaration for gtk_widget_get_allocation, yet it seems the compiler can't see it.

Can anyone help?

Thanks in advance.

gnashley 05-22-2010 03:13 AM

Don't mix /usr/local with /usr. If you upgrade something, build it so that it replaces the old version instead of installing to some other location. Having libs and headers present in more than one location will nearly always cause problems such as you are having.

Geriao 05-23-2010 03:55 PM

Yes, I had something like that while upgrading glib2... But as I checked the source file that is the font of this error, it includes gtk/gtk.h, and gtk.h includes /usr/local/include/gtk-2.0/gtk/gtkwidget.h, which has a declaration for the function that the compiler says is undefined.
How do I amend that?

Also, a bit off topic, when I just used "make" to compile a new version of glib2, it seemed , even without "make install", that further programs that used it were searching for it in, e.g., /tmp/building/glib2 (where my sources were). What command the "make install" of glib does that registers that location as the place where the libraries are?

Thanks in advance!

gnashley 05-24-2010 06:13 AM

'amke install' finalizes the libs, *.la and *.pc files to use the final path which is determined by the prefix. As I said, get rid of everything in /usr/local and start over from the beginning and put everything in prefix=/usr, overwriting the existing versions and you'll have much better success.


All times are GMT -5. The time now is 12:39 AM.