[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [cp-patches] FYI: FileChannelImpl.c fixes
From: |
Roman Kennke |
Subject: |
Re: [cp-patches] FYI: FileChannelImpl.c fixes |
Date: |
Mon, 23 Jan 2006 18:11:02 +0100 |
Hi Mark,
Am Montag, den 23.01.2006, 17:25 +0100 schrieb Mark Wielaard:
> Hi Roman,
>
> On Mon, 2006-01-23 at 15:21 +0100, Roman Kennke wrote:
> > > This broke File locking. In particular the mauve test
> > > gnu.testlet.java.nio.channels.FileChannel.lock and the eclipse osgi
> > > locking. How did you test this patch and on what platforms?
> > >
> > > I have a hard time seeing how this patch is supposed to work. You
> > > replace the calls with new target layer functionality, but that
> > > functionality seems to depend on having things like
> > > TARGET_NATIVE_FILE_LOCKMODE_READ, which depend on things like
> > > HAVE_F_RDLCK being defined, but I cannot find where you exactly do this.
> >
> > I tested this with the JamaicaVM. Sorry, I didn't run a full test with
> > JamVM/Classpath or similar. The HAVE_F_RDLCK thing very much sounds like
> > an autoconf test. I'll check this with Torsten and come back to it.
>
> Thanks. Please do test against one of the free runtimes that the other
> hackers also use in the future when making such invasive changes, or ask
> someone else to test it for you before committing.
Ok, I'll be more careful next time. Sorry for the inconvenience.
> If investigating this
> takes more than a day could you revert the patch temporarily so we don't
> have a broken tree for too long?
This specific problem can be fixed by adding autoconf checks like these:
AC_CHECK_CONSTANT_INCLUDES(F_SETLK, fcntl.h,AC_DEFINE(HAVE_F_SETLK,
1,[define if the system has F_SETLK constant is in fcntl.h.]))
AC_CHECK_CONSTANT_INCLUDES(F_SETLKW,fcntl.h,AC_DEFINE(HAVE_F_SETLKW,1,[define
if the system has F_SETLKW constant is in fcntl.h.]))
AC_CHECK_CONSTANT_INCLUDES(F_RDLCK, fcntl.h,AC_DEFINE(HAVE_F_RDLCK,
1,[define if the system has F_RDLCK constant is in fcntl.h.]))
AC_CHECK_CONSTANT_INCLUDES(F_WRLCK, fcntl.h,AC_DEFINE(HAVE_F_WRLCK,
1,[define if the system has F_WRLCK constant is in fcntl.h.]))
AC_CHECK_CONSTANT_INCLUDES(F_UNLCK, fcntl.h,AC_DEFINE(HAVE_F_UNLCK,
1,[define if the system has F_UNLCK constant is in fcntl.h.]))
These are copy+pasted from Jamaica, I'll adjust this for Classpath asap
and check this in. Or maybe you'd look after this in the meantime? I
won't have time for this this evening ...
Cheers, Roman
signature.asc
Description: Dies ist ein digital signierter Nachrichtenteil