Subject: buildlink, gcc3 and png
To: None <tech-pkg@netbsd.org>
From: David Brownlee <abs@absd.org>
List: tech-pkg
Date: 01/15/2004 17:49:41
	graphics/png fails to compile under 1.6.x using gcc3.

/var/obj/pkg/graphics/png/work/.buildlink/bin/libtool  --mode=link
/usr/pkg/gcc-3.3/bin/gcc -o pngtest -O2 -march=pentiumpro
-finline-functions -ffast-math -fomit-frame-pointer -pipe -I/usr/include
pngtest.o  -L/usr/lib -Wl,-R/usr/lib -Wl,-R/usr/pkg/lib libpng.la -lz -lm
/usr/pkg/gcc-3.3/bin/gcc -o .libs/pngtest -O2 -march=pentiumpro
-finline-functions -ffast-math -fomit-frame-pointer -pipe pngtest.o
-Wl,-R/usr/pkg/lib  ./.libs/libpng.so
-L/var/obj/pkg/graphics/png/work/.buildlink/lib -lz -lm -Wl,--rpath
-Wl,/usr/pkg/lib
/usr/bin/ld: cannot find -lgcc_eh
collect2: ld returned 1 exit status

	This can be rectified by linking libgcc_eh.a into
	work/.buildlink/lib/

	On an i386 box this would be
	/usr/pkg/gcc-3.3/lib/gcc-lib/i386--netbsdelf/3.3/libgcc_eh.a

	What would the correct fix be for this?

-- 
			   David Brownlee -- abs@absd.org