Re: Henry Thompson's patch for 64-bit Cygwin compatibility

[email protected] (Henry S. Thompson) Tue, 24 Mar 2015 14:46:21 +0000
Newsgroups gmane.emacs.xemacs.patches
Message-ID <[email protected]>
Vin Shelton writes:

> Yes.  The way to do this is to use the -U 0 option for ChangeLogs, so
> there is no context.  Then the ChangeLog patches will apply cleanly.

Ah, didn't know about that -- will do next time.

>> Also, although committers need to commit the automatically generated
>> files, I don't think you need to submit the patch (in fact, since
>> practically the whole files are changed, it's probably shorter to
>> submit the original files).

Right.

>> Regarding the patch itself, I don't like the name DEVICE_TYPE_X,
>> because it looks like it either has something to do with the X Window
>> System or perhaps is the C implementation of a lisp function named
>> `device-type*'.  Possibly just "DEVICE_TYPE_" (I think that's the
>> convention Ben used to avoid C++ keywords like "class").

I'm absolutely fine with whatever name you prefer.

> Henry - after applying the patch, I notice the following problems on
> my 64-bit Win7 system.  Note that this is gcc-4.9.2 (Installation file
> included below).

Win7 -- right.

> 1. configure reports:
>   checking build system type... x86_64-unknown-cygwin
>   XEmacs has no builtin knowledge of `x86_64' machines.
>   Using configure-time autodetection only.
>   XEmacs has no builtin knowledge of `cygwin64' operating systems.
>   Using configure-time autodetection only.

Hmm. x86_64-unknown-cygwin is the right output from config.guess/sub.

There are patches in configure and configure.ac which are supposed to
handle that.  I wonder if there's a difference between Win7 and
Win8...

> 2. event-msw.c fails to compile:
>
>   gcc -c -I/usr/include/noX -I/usr/include/noX -Wall -Wno-switch
> -Wundef -Wsign-compare -Wno-char-subscripts -Wpacked -Wpointer-arith
> -Wshadow -Wmissing-declarations -Wmissing-prototypes
> -Wstrict-prototypes -Wdeclaration-after-statement  -Wunused-parameter
> -g    -Demacs -I. -I/c/Cyg_acs/xemacs-21.5/src -DHAVE_CONFIG_H
> event-msw.c
>   event-msw.c:67:3: error: #error Something is wrong -- you are
> neither Windows native (possibly MinGW) nor Cygwin.
>    # error Something is wrong -- you are neither Windows native
> (possibly MinGW) nor Cygwin.

Wow, that's _certainly_ not a good sign.  Let's 

> It looks like the cygwin detection is not working.

Indeed

> XEmacs 21.5-b34 "kale" 3ed83b4b4882+ configured for `x86_64-unknown-cygwin'.
>
> Compilation Environment and Installation Defaults:
>   Source code location:              /c/Cyg_acs/xemacs-21.5
>   Installation prefix:               /usr/local
>   Not using any operating system description file
>   Not using any machine description file

I expect that's the source of the event-msw.c problem.

Out of time here, I'll try to find a Win7 box with which to explore
further.

Thanks for picking this up,

ht
-- 
       Henry S. Thompson, School of Informatics, University of Edinburgh
      10 Crichton Street, Edinburgh EH8 9AB, SCOTLAND -- (44) 131 650-4440
                Fax: (44) 131 650-4587, e-mail: [email protected]
                       URL: http://www.ltg.ed.ac.uk/~ht/
 [mail from me _always_ has a .sig like this -- mail without it is forged spam]