[racket-dev] racket 5.1 build failure on debian/kfreebsd

From: David Bremner (bremner at debian.org)
Date: Sun Apr 24 09:04:02 EDT 2011

On Thu, 21 Apr 2011 23:06:23 -0300, David Bremner <bremner at debian.org> wrote:
> On Thu, 21 Apr 2011 19:32:18 -0600, Matthew Flatt <mflatt at cs.utah.edu> wrote:
> > Besides some code-organization problems, my guess is that "sconfig.h"
> > doesn't figure out that you're on a FreeBSD variant. Do you know what
> > pre-processor definition should be detected, if it's not __FreeBSD__?
> > 
> At a guess, I'd say __FreeBSD_kernel__  

The attached patch does indeed allow compilation to finish. 
There is a problem linking to pthreads 

| gcc -o racketcgc main.o  libracket.a libmzgc.a  -ldl -lm  
| libracket.a(port.o): In function `start_green_thread_timer':
| /home/bremner/racket/src/racket/src/port.c:8937: undefined reference to `pthread_create'
| libracket.a(port.o): In function `kill_green_thread_timer':
| /home/bremner/racket/src/racket/src/port.c:8956: undefined reference to `pthread_join'

I can work around this by "configure --enable-pthread", but I suspect
the right fix is to add a stanza for GNU/kFreeBSD to src/configure.
I'm a little baffled how this file is maintained, though. Is there a
corresponding configure.ac somewhere?

All the best


P.S. with --enable pthread racket3m bus errors out, but one problem at a

-------------- next part --------------
A non-text attachment was scrubbed...
Name: fbsd.patch
Type: text/x-diff
Size: 623 bytes
Desc: detect debian/kbsd
URL: <http://lists.racket-lang.org/dev/archive/attachments/20110424/9dceb162/attachment.bin>

Posted on the dev mailing list.