From xemacs-m  Fri May 30 05:23:50 1997
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by xemacs.org (8.8.5/8.8.5) with SMTP id FAA17541
	for <xemacs-beta@xemacs.org>; Fri, 30 May 1997 05:23:49 -0500 (CDT)
Received: from Eng.Sun.COM ([129.146.1.25]) by mercury.Sun.COM (SMI-8.6/mail.byaddr) with SMTP id DAA05598; Fri, 30 May 1997 03:40:31 -0700
Received: from kindra.eng.sun.com by Eng.Sun.COM (SMI-8.6/SMI-5.3)
	id DAA01171; Fri, 30 May 1997 03:22:41 -0700
Received: from xemacs.eng.sun.com by kindra.eng.sun.com (SMI-8.6/SMI-SVR4)
	id DAA24349; Fri, 30 May 1997 03:22:39 -0700
Received: by xemacs.eng.sun.com (SMI-8.6/SMI-SVR4)
	id DAA04707; Fri, 30 May 1997 03:22:48 -0700
Date: Fri, 30 May 1997 03:22:48 -0700
Message-Id: <199705301022.DAA04707@xemacs.eng.sun.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
From: Martin Buchholz <mrb@Eng.Sun.COM>
To: Olivier Galibert <Olivier.Galibert@mines.u-nancy.fr>
Cc: Xemacs-beta ML <xemacs-beta@xemacs.org>
Subject: configure problems on irix 6.2
In-Reply-To: <19970530114052.50290@iria.mines.u-nancy.fr>
References: <19970530114052.50290@iria.mines.u-nancy.fr>
X-Mailer: VM 6.31 under 20.3 XEmacs Lucid (beta2)
Reply-To: Martin Buchholz <mrb@Eng.Sun.COM>

>>>>> "Olivier" == Olivier Galibert <Olivier.Galibert@mines.u-nancy.fr> writes:

Olivier> Interesting irix behavior :
Olivier> galibert@iria:~/tmp #246 >cat tt.c
Olivier> int main(void)
Olivier> {
Olivier>   return 0;
Olivier> }
Olivier> galibert@iria:~/tmp #247 >cc -n32 tt.c -o tt -lpng
Olivier> ld32: WARNING 84: /usr/lib32/libpng.so is not used for resolving any symbol.
Olivier> galibert@iria:~/tmp #248 >./tt
Olivier> 20760:./tt: rld: Error: unresolvable symbol in /usr/lib32/libpng.so: inflateReset
Olivier> 20760:./tt: rld: Error: unresolvable symbol in /usr/lib32/libpng.so: inflate
Olivier> 20760:./tt: rld: Error: unresolvable symbol in /usr/lib32/libpng.so: deflate
Olivier> 20760:./tt: rld: Error: unresolvable symbol in /usr/lib32/libpng.so: pow
Olivier> 20760:./tt: rld: Fatal Error: this executable has unresolvable symbols

This explains a lot.

Olivier> Which means the configure test for png/png with gz/png with z does not work
Olivier> properly because the code only tries to link the test code and not to run it.
Olivier> Here it finds that -lpng is enough which is wrong since -lz is also needed.

Olivier> The only workaround I see is to look specifically for the zlib. Is this lib
Olivier> used by anything else than png in xemacs ?

Some suggestions:
- is libpng.so built incorrectly? (i.e. is there some way to
  "pre-resolve" the zlib symbols?)
- is there a linker flag that says to check all the dependencies of
  all the other libs on the command line?

Martin

