Subject: pkg/26693: pkgsrc/graphics/p5-GD doesn't work with non-threaded perl
To: None <>
From: None <>
List: pkgsrc-bugs
Date: 08/17/2004 12:26:12
>Number:         26693
>Category:       pkg
>Synopsis:       threaded graphics/p5-GD core dumps when used with non-threaded lang/perl58
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Aug 17 10:27:00 UTC 2004
>Originator:     Gert Doering
>Release:        NetBSD 2.0G
	private netBSD user
System: NetBSD 2.0G NetBSD 2.0G (SCOTTY) #0: Sat Jul 24 23
:02:34 CEST 2004 gert@scotty:/home/obj/usr/src/sys/arch/sparc64/compile/SCOTTY s
Architecture: sparc64
Machine: sparc64
	the default setup of the GD library links with -lpthread, and
	perl58 does not.  
	When building pkgsrc/graphics/p5-GD, as soon as loading the GD
	module, perl core dumps (due to thread<->non-thread mismatch)
	This happens on i386, sparc, sparc64 architecture.
	install pkgsrc/lang/perl58
	install pkgsrc/graphics/gd  (plus dependencies)
	go to pkgsrc/graphics/p5-GD
	run "make PKGSRC_RUN_TEST?=yes"
	the workaround I used was to build graphics/gd without freetype
	support and without linking with -lpthread (removing the 
        BUILDLINK_DEPENDS statement and the #.include of 
        ".../freetype2/" and ".../" 
        from both gd/Makefile and gd/ - but this looses 
        freetype functionality 

	Another workaround that was discussed in tech-pkg was to always
	link perl58 with "-lpthread".

	One thing that should be done in any case is to check for 
	collisions (threaded GD <-> unthreaded perl) to tell the user
	what's going on instead of just core dumping on him.