Broken autoconf mmap test

Eric Blake eblake@redhat.com
Thu Mar 24 19:59:00 GMT 2011


On 03/24/2011 01:13 PM, Larry Hall (Cygwin Developers) wrote:
>> And, is the autoconf test perhaps the only client for this solution
>> since no sensible application will read and write bytes beyond EOF?  If
>> so, it's kind of sad that an autoconf test will result in lots of
>> application not using mmap, even though none of them actually uses the
>> map beyond EOF.
>>
>> So, whatever we do in Cygwin's mmap, it's either rock or hard place,
>> as far as I can see
> 
> I do think it's worthwhile to examine the "why" before making changes here.
> If the main (only?) gain here is to appease autoconf, is there a way we can
> "cheat" at this?  Getting autoconf'd packages to use mmap is a good thing
> but it does sound to me like it needs to be way easier for Cygwin to do
> this right, we need a specific work-around to target autoconf checks, or we
> shouldn't bother (for now).

I'm perfectly fine with a patch to autoconf that weakens the semantics
of the autoconf test (and/or splits it into two tests, with the old name
being weaker and only the new name requiring full POSIX compliance),
along with autoconf documentation about the portability restrictions
where a portable program cannot do the corner case guaranteed by POSIX,
if we can be reasonably sure that this really is a corner case unlikely
to hit real programs.

-- 
Eric Blake   eblake@redhat.com    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 619 bytes
Desc: OpenPGP digital signature
URL: <http://cygwin.com/pipermail/cygwin-developers/attachments/20110324/860227d2/attachment.sig>


More information about the Cygwin-developers mailing list