Subject: Re: bug#27059: Can't compile master branch on Mac OS X

From: David Caldwell <[email-masked]>
Date: Tue, 30 May 2017 11:36:43 -0700

On 5/29/17 9:05 AM, Alan Third wrote:
> On Mon, May 29, 2017 at 01:56:05AM -0700, David Caldwell wrote:
>> Nevertheless, you are right--Putting the explicit cast in makes it compile.
> 
> Pushed fix to master.

Still not quite there :-/

This time the error happens on 10.6 compiling for 32 bit targets
(compiler is i686-apple-darwin10-gcc-4.2.1):

i686-apple-darwin10-gcc-4.2.1 -mmacosx-version-min=10.6  -std=gnu99 -c
-Demacs  -I. -I. -I../lib -I../lib         -I'/usr/include/libxml2'
      -MMD -MF deps/nsfns.d -MP       -g3 -O2   nsfns.m
nsfns.m: In function 'compute_tip_xy':
nsfns.m:2756: error: conversion to non-scalar type requested
nsfns.m:2756: error: conversion to non-scalar type requested
make[1]: *** [nsfns.o] Error 1
make: *** [src] Error 2

This was the best I could come up with for this compiler:

    NSRect r = [screen frame];
    if (CGRectContainsPoint (*(CGRect*)&r, *(CGPoint*)&pt))

(yuck). Interestingly, I tried searching for this and found this thread
from 15 years ago:
https://lists.apple.com/archives/cocoa-dev/2002/Jan/msg00763.html

Maybe it would be better to fall back to the GNUStep else clause in
these cases?

-David