GNU bug report logs - #720
Patch to fix CVS Emacs compilation error on Windows XP SP2.

Previous Next

Packages: w32, emacs;

Reported by: Francis Litterio <flitterio <at> gmail.com>

Date: Thu, 14 Aug 2008 17:10:04 UTC

Severity: normal

Tags: patch

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #64 received at 720 <at> emacsbugs.donarmstrong.com (full text, mbox):

From: Francis Litterio <flitterio <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>, 720 <at> debbugs.gnu.org
Subject: Re: bug#720: Patch to fix CVS Emacs compilation error on Windows XP SP2.
Date: Fri, 15 Aug 2008 09:22:31 -0400
Eli Zaretskii wrote:

>> From: Francis Litterio
>> 
>> 	w32.c(3820) : error C2520: conversion from unsigned __int64 to double not implemented, use signed __int64
>
> "Not implemented"?  I'm not sure we want to support such a deficient
> compiler.

I would happily use a newer compiler.  The file emacs/nt/INSTALL says
this:

   To compile Emacs, you will need either Microsoft Visual C++ 2.0, or
   later up to 7.0, and nmake

I didn't realize that I could use a version of VC++ newer than 6.0.  I
would be happy to abandon 6.0 for building Emacs on Windows.  Is VC++
7.0 the compiler that comes with Visual Studio 2003?

What compiler do the Emacs developers use to build on Windows?

> How about this:
>
>   DWORD tot_hi = memstex.ullTotalPhys >> 32;
>   DWORD tot_md = (memstex.ullTotalPhys & 0x00000000ffffffffLL) >> 10;
>   DWORD tot_lo = memstex.ullTotalPhys % 1024LL;
>   totphys = tot_hi * 4194304.0 + tot_md + tot_lo / 1024.0;
>
> Does this work?

Nope:

  w32.c(3823) : error C2059: syntax error : 'bad suffix on number'
  w32.c(3823) : error C2146: syntax error : missing ')' before identifier 'L'
  w32.c(3823) : error C2059: syntax error : ')'
  w32.c(3824) : error C2059: syntax error : 'bad suffix on number'
  w32.c(3824) : error C2146: syntax error : missing ';' before identifier 'L'
  w32.c(3824) : error C2065: 'L' : undeclared identifier

Here's the relevant code with line numbers:

  3819	  if (global_memory_status_ex (&memstex))
  3820	#if 1
  3821	  {
  3822	    DWORD tot_hi = memstex.ullTotalPhys >> 32;
  3823	    DWORD tot_md = (memstex.ullTotalPhys & 0x00000000ffffffffLL) >> 10;
  3824	    DWORD tot_lo = memstex.ullTotalPhys % 1024LL;
  3825	    totphys = tot_hi * 4194304.0 + tot_md + tot_lo / 1024.0;
  3826	  }
  3827	#else
  3828	    totphys = (signed __int64)memstex.ullTotalPhys / 1024.0;
  3829	#endif

--
Fran




This bug report was last modified 16 years and 343 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.