You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by Glenn Schrader <gs...@ll.mit.edu> on 2005/08/05 17:21:05 UTC

[PATCH] apr-util build fails on Solaris 2.8

I'm attempting to build apr-util 1.1.2 on Solaris 2.8 with
--enable-static, --disable-shared, and --with-berkeley-db=<path>.
The configuration script indicates that it can't find a
good Berkeley DB. The problem isn't that its not pointing
to a good libdb since the log file says that the test
for the database is failing to link because fdatasync
is undefined. What I've found is that on linux, fdatasync
appears to be in both libc and librt but on Solaris 2.8
its only in librt. The attached patch modifies
apr-util/build/apu-hits.m4 to add -lrt to the list of
libraries to be linked in for Solaris2.

Thanks much,

Glenn Schrader


Re: [PATCH] apr-util build fails on Solaris 2.8

Posted by Glenn Schrader <gs...@ll.mit.edu>.
Joe Orton wrote:
> On Fri, Aug 05, 2005 at 11:21:05AM -0400, Glenn Schrader wrote:
> 
>>I'm attempting to build apr-util 1.1.2 on Solaris 2.8 with
>>--enable-static, --disable-shared, and --with-berkeley-db=<path>.
>>The configuration script indicates that it can't find a
>>good Berkeley DB. The problem isn't that its not pointing
>>to a good libdb since the log file says that the test
>>for the database is failing to link because fdatasync
>>is undefined. What I've found is that on linux, fdatasync
>>appears to be in both libc and librt but on Solaris 2.8
>>its only in librt. The attached patch modifies
>>apr-util/build/apu-hits.m4 to add -lrt to the list of
>>libraries to be linked in for Solaris2.
> 
> 
> If a static BDB library can depend on -lrt then the correct way to fix 
> this is to enhance the APU_CHECK_BERKELEY_DB macro (build/bdb.m4) to 
> trying linking against -ldb -lrt if linking against -ldb fails.
> 
> joe
> 
> 
OK. That does sound cleaner (be gentle, this is the first patch that
i've submitted here). An updated patch is attached.

-glenn

Re: [PATCH] apr-util build fails on Solaris 2.8

Posted by Joe Orton <jo...@redhat.com>.
On Fri, Aug 05, 2005 at 11:21:05AM -0400, Glenn Schrader wrote:
> I'm attempting to build apr-util 1.1.2 on Solaris 2.8 with
> --enable-static, --disable-shared, and --with-berkeley-db=<path>.
> The configuration script indicates that it can't find a
> good Berkeley DB. The problem isn't that its not pointing
> to a good libdb since the log file says that the test
> for the database is failing to link because fdatasync
> is undefined. What I've found is that on linux, fdatasync
> appears to be in both libc and librt but on Solaris 2.8
> its only in librt. The attached patch modifies
> apr-util/build/apu-hits.m4 to add -lrt to the list of
> libraries to be linked in for Solaris2.

If a static BDB library can depend on -lrt then the correct way to fix 
this is to enhance the APU_CHECK_BERKELEY_DB macro (build/bdb.m4) to 
trying linking against -ldb -lrt if linking against -ldb fails.

joe