Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I got tired of every graphical application on my computer needing a different version of libpng, so I went ahead and downloaded and compiled the newest (1.6.17) and wiped out the others. Now, I'm in the process of recompiling everything that uses libpng. I started with gdk-pixbuf, and then I did cairo, then pango, and finally I did gtk-2.0.
I'm at the point of recompiling The GIMP. Before I did the libpng upgrade, it compiled fine. Now, I get the following errors during ./configure.
Code:
configure:17628: gcc -o conftest -g -O2 -Wall -Wdeclaration-after-statement -Wmissing-prototypes -Werror=missing-prototypes -W
strict-prototypes -Wmissing-declarations -Winit-self -Wpointer-arith -Wold-style-definition -Wmissing-format-attribute -Wforma
t-security -fno-common -fdiagnostics-show-option conftest.c >&5
In file included from /usr/local/include/gtk-2.0/gdk/gdkapplaunchcontext.h:31:0,
from /usr/local/include/gtk-2.0/gdk/gdk.h:32,
from /usr/local/include/gtk-2.0/gtk/gtk.h:32,
from conftest.c:47:
/usr/local/include/gtk-2.0/gdk/gdkscreen.h:56:3: error: expected specifier-qualifier-list before 'cairo'
/usr/local/include/gtk-2.0/gdk/gdkscreen.h:120:15: warning: type defaults to 'int' in declaration of 'cairo' [-Wimplicit-int]
/usr/local/include/gtk-2.0/gdk/gdkscreen.h:120:20: error: expected ';', ',' or ')' before '/' token
/usr/local/include/gtk-2.0/gdk/gdkscreen.h:121:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
In file included from /usr/local/include/gtk-2.0/gdk/gdk.h:33:0,
from /usr/local/include/gtk-2.0/gtk/gtk.h:32,
from conftest.c:47:
/usr/local/include/gtk-2.0/gdk/gdkcairo.h:33:6: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
/usr/local/include/gtk-2.0/gdk/gdkcairo.h:34:19: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
/usr/local/include/gtk-2.0/gdk/gdkcairo.h:37:19: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
/usr/local/include/gtk-2.0/gdk/gdkcairo.h:39:19: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
/usr/local/include/gtk-2.0/gdk/gdkcairo.h:43:19: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
/usr/local/include/gtk-2.0/gdk/gdkcairo.h:47:19: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
/usr/local/include/gtk-2.0/gdk/gdkcairo.h:52:19: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
/usr/local/include/gtk-2.0/gdk/gdkcairo.h:54:19: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
In file included from /usr/local/include/gtk-2.0/gdk/gdk.h:39:0,
from /usr/local/include/gtk-2.0/gtk/gtk.h:32,
from conftest.c:47:
/usr/local/include/gtk-2.0/gdk/gdkdrawable.h:201:3: error: expected specifier-qualifier-list before 'cairo'
In file included from /usr/local/include/gtk-2.0/gdk/gdktestutils.h:28:0,
from /usr/local/include/gtk-2.0/gdk/gdk.h:56,
from /usr/local/include/gtk-2.0/gtk/gtk.h:32,
from conftest.c:47:
/usr/local/include/gtk-2.0/gdk/gdkwindow.h:545:6: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
/usr/local/include/gtk-2.0/gdk/gdkwindow.h:629:6: error: expected '=', ',', ';', 'asm' or '__attribute__' before '/' token
In file included from /usr/local/include/gtk-2.0/gtk/gtk.h:234:0,
from conftest.c:47:
/usr/local/include/gtk-2.0/gtk/gtkitemfactory.h:47:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
conftest.c:51:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]
conftest.c: In function 'main':
conftest.c:51:1: warning: old-style function definition [-Wold-style-definition]
configure:17628: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "GIMP"
| #define PACKAGE_TARNAME "gimp"
| #define PACKAGE_VERSION "2.8.2"
| #define PACKAGE_STRING "GIMP 2.8.2"
...
Now, since I just recompiled and reinstalled gdk-pixbuf and gtk-2.0 without any errors, I'm not sure why it's complaining about gdk code. I've looked this up on DuckDuckGo, but all I find are real programming solutions, and I'm not about to go into the source code and start reprogramming a program that compiled just fine on this machine only a few days ago.
BTW, this is Slackware 14.0 with source code for GIMP 2.8.2, which is the one SW 14 comes with.
The code that is failing, conftest, is a short program used to test your configure parameters. My guess is you need to supply some arguments to ./configure.
on my computer needing a different version of libpng,
this WILL!!! require YOU!!! to hack the source code of EVERY older program that uses libpng12 and 13 and 14
to upgrade the code to that of libpng16
-there is a REASON you have a libpng 14 and 16 ( and maybe 13 /12)
you DO have at lease two libpng.pc files ? /usr/lib64/pkgconf/libpng16.pc
right ?
one for 16 and one for 14
then a simlink to the SYSTEM default that IS ALSO the default header used ?
( you have libpng14 and 16 headers ALSO )
also "GIMP 2.8.2" is OLD !!!
the current is 2.8.14
When I moved on to recompile Qt4 it gave me similar - but slightly different - errors. I compared them directly and noticed that they were all referring somehow to cairo. So, I recompiled cairo, but this time I used the actual SlackBuild source code from my installation CD instead of the newer version that I had downloaded from the cairo web site.
I recompiled pango, then I recompiled gtk+, and now The GIMP configures just fine.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.