apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Garrett Rooney <roo...@electricjellyfish.net>
Subject Re: problem with apr_atomic_init on freebsd
Date Fri, 05 Jul 2002 20:44:20 GMT
On Fri, Jul 05, 2002 at 01:34:18PM -0700, Brian Pane wrote:
> On Fri, 2002-07-05 at 12:23, Garrett Rooney wrote:
> > so for the first time in like forever, i reinstalled my development
> > machine and thus had to download fresh copies of subversion and apr.
> > 
> > it seems that apr's configure script is now disabling threads by
> > default on FreeBSD, which is fine, since i'm not actually using
> > threads, but there appears to be a few kinks with the atomics code.
> I just added the missing definition of apr_atomic_init() for
> FreeBSD, so it should be working now.

unfortunately, that doesn't fix it...  that was the first thing i
tried ;-)  with that change we don't even compile...

here's the error message i get now:

/usr/local/bin/bash /usr/home/rooneg/svn/apr/libtool --silent --mode=compile gcc -g -O2 -Wall
-Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations   -DHAVE_CONFIG_H -D_REENTRANT
-D_THREAD_SAFE   -I../../include -I../../include/arch/unix -I../../include/arch/unix  -c start.c
&& touch start.lo
In file included from start.c:59:
../../include/apr_atomic.h:257: syntax error before `0'
*** Error code 1

Stop in /usr/home/rooneg/svn/apr/misc/unix.
*** Error code 1

Stop in /usr/home/rooneg/svn/apr/misc/unix.
*** Error code 1

Stop in /usr/home/rooneg/svn/apr.
*** Error code 1

Stop in /usr/home/rooneg/svn.

it's dying because we both #define away apr_atomic_init and declare it
(because freebsd defines APR_ATOMIC_NEED_CAS_DEFAULT).

still not sure of the correct fix though.  perhaps inside the #if
defined (APR_ATOMIC_NEED_CAS_DEFAULT) case at the bottom of
apr_atomic.h we need to check if we have threads and if not just 
#define apr_atomic_init to APR_SUCCESS?


garrett rooney                    Remember, any design flaw you're 
rooneg@electricjellyfish.net      sufficiently snide about becomes  
http://electricjellyfish.net/     a feature.       -- Dan Sugalski

View raw message