On Mon, Dec 05, 2005 at 01:34:43PM -0800, Bruce Korb wrote: > On Thursday 01 December 2005 08:11 am, Bruce Korb wrote: > > The call to scm_makstr() is faulting (every time for me): > > Hi all, > > I have now been able to recreate the failure on this call fairly > often, but I have not found a cause. Nevertheless, this call is > only useful if you use SCM_CHARS() and that has been so strongly > "deprecated" that the current development releases (1.7.x) of > Guile emit warnings when it is used. Rather than fight it, I have > removed all usage of either of these for all variations of AutoGen. > (Each version of Guile causes me to rewrite some portion of > AutoGen. 1.7 is the worst yet, causing me several days of work.) > > Upshot: I now (finally) have a 1.7.x-ready version of AutoGen. > Problem: still seg faults on Alpha Linux 2.2. The issue: mmap > > Details: > > When I mmap a file, I have to test for it being a multiple of the > page size. My "license.test" forces this for both the template > and for the license text. Both of these files get mmapped, so > I use this test to verify proper functioning of mmap, too. > > My mapping descriptor structure shows this: > > (gdb) print *pMI > $2 = {txt_data = 0x2000001c000, txt_size = 8192, txt_full_size = 16384, > txt_fd = 7, txt_zero_fd = -1, txt_errno = 0, txt_prot = 0, txt_flags = 0, > txt_alloc = 0} > > Immediately before this call: > > pNuls = mmap( > (void*)(((char*)pMI->txt_data) + pMI->txt_size), > pgsz, > PROT_READ|PROT_WRITE, > MAP_ANONYMOUS|MAP_FIXED|MAP_SHARED, 0, 0 ); > > The address passed is: > > (gdb) print 0x2000001c000+8192 > $5 = 0x2000001e000 > > According to my reading of the doc for mmap, this should work. It does > work on other platforms. It also seg faults instead of returning ((void*)-1). > Now, what? :-(
If you don't want to require that users use a kernel that doesn't misbehave like this, shouldn't you add an autoconf test that checks for this behavior and falls back to some other method? -- Matt
signature.asc
Description: Digital signature