From: "Ara.T.Howard" Date: 2005-03-03T07:53:23+09:00 Subject: Re: [RCR???] locking [WAS] Re: A wish: Simple database On Wed, 2 Mar 2005, Joel VanderWerf wrote: > Ara.T.Howard@noaa.gov wrote: >> if you were interested we could work on a patch and submit to matz? > > Great! I'm already using your fcntl-lock stuff from a couple of years ago as > an option (and the default on some platforms). In fact, that's what was > breaking on Darwin. Have you had any luck there? no - see below. i can get access to a mac to test though... doug? > > Anyway, if sqlite has a good general solution, let's try to adapt it. I'll > take a look this weekend. o.k. cool. if you download the src check out ./src/os.c this file might be generated (i forget) so you may have to run ./configure && make... then grep for sqliteOsReadLock it's got #if OS_UNIX ... #if OS_WIN ... #if OS_MAC and it compiles all over the place. also, the apache portable runtime has a portable file locking interface. check out http://apr.apache.org/ specifically http://apr.apache.org/docs/apr/group__apr__file__lock__types.html and http://apr.apache.org/docs/apr/apr__file__io_8h-source.html (they don't seem to have links in doxygen for the *c files?) anyhow - we could start by creating an extension. if it worked on win/nix/mac we could then submit to core or something. it should be to bad i think... i'll probably bug my friend doug to run the tests on his mac. doug? kind regards. -a -- =============================================================================== | EMAIL :: Ara [dot] T [dot] Howard [at] noaa [dot] gov | PHONE :: 303.497.6469 | When you do something, you should burn yourself completely, like a good | bonfire, leaving no trace of yourself. --Shunryu Suzuki ===============================================================================