LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This 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


Reply
  Search this Thread
Old 01-01-2011, 02:11 AM   #1
naaman
Member
 
Registered: Jun 2006
Posts: 84

Rep: Reputation: 16
Build problem hard to solve : zeroradiant and libpng 1.4 (libpng compatibility pb)


Hello !

I'd like to build Zeroradiant (1.6) but I've got a problem to compile it...
Indeed, Zeroradiant only works with libpng 1.2.X (which is not compatible with libpng 1.4.X ...). Then when I start compiling the sources I got this typical error :
Code:
plugins/imagepng/plugin.cpp: In function 'void LoadImage(const char*, unsigned char**, int*, int*)':
plugins/imagepng/plugin.cpp:140: error: 'png_voidp_NULL' was not declared in this scope
plugins/imagepng/plugin.cpp:151: error: 'png_infopp_NULL' was not declared in this scope
plugins/imagepng/plugin.cpp:159: error: 'png_infopp_NULL' was not declared in this scope
plugins/imagepng/plugin.cpp:167: warning: 'png_struct_def::jmpbuf' is deprecated (declared at /usr/include/png.h:1096)
plugins/imagepng/plugin.cpp:167: warning: 'png_struct_def::jmpbuf' is deprecated (declared at /usr/include/png.h:1096)
plugins/imagepng/plugin.cpp:191: error: 'png_set_gray_1_2_4_to_8' was not declared in this scope
plugins/imagepng/plugin.cpp:237: error: 'png_infopp_NULL' was not declared in this scope
scons: *** [build/debug/shobjs/plugins/imagepng/plugin.os] Error 1
scons: building terminated because of errors.
I've got the two libpng installed on my computer however I still continue
to get that error message ...

I had noticed that /usr/lib/libpng.so and /usr/lib64/libpng.so were
linked to /usr/lib/libpng14.so, so I decided to remove the symbolic link and create one from /usr/lib/libpng.so to /usr/lib/libpng12.so.
But that didn't solve my problem.

To build Zeroradiant I've got to use scons, I tried to "configure scons" so that it choose the right libpng but I found nothing (that's why I used the trick above).

Do you know how I could simply solve it ?

Thanks !

PS:

To build Zeroradiant I use theses instructions :
http://www.qeradiant.com/cgi-bin/tra...ki/ZeroRadiant

I'm running a Gentoo GNU/Linux.
 
Old 01-01-2011, 04:03 AM   #2
naaman
Member
 
Registered: Jun 2006
Posts: 84

Original Poster
Rep: Reputation: 16
In order to get rid of this compile problem I decided to edit plugin.cpp :
I changed png_voidp_NULL to (png_voidp)NULL
and png_infopp_NULL to (png_infopp)NULL.
I also changed this function : png_set_gray_1_2_4_to_8 to this one :
png_set_expand_1_2_4_to_8 and it seems to work :-)

It's very very dirty but it's the only way I found :-/
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Problem with libpng soppy Linux - Software 3 11-08-2010 09:12 PM
libpng and libpng-devel driving me crazy latino Linux - Server 6 06-27-2007 06:15 PM
error while loading shared libraries: libpng.so.2: [I reinstalled libPNG!] Shioni Linux - Software 1 09-09-2006 07:21 PM
libpng and libpng-devel missing in mplayer configure mmarkvillanueva Linux - Software 2 11-29-2005 10:40 PM
MPlayer install problems with libpng & libpng-devel Trey2501 Linux - Newbie 18 03-05-2004 11:24 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:21 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration