unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: 李丁 <iamliding@gmail.com>
Cc: 12878@debbugs.gnu.org
Subject: bug#12878: 24.2; Compiling failed on Windows 7 with VC 11 Express: _WIN32_WINNT version too low
Date: Sat, 17 Nov 2012 20:57:26 +0200	[thread overview]
Message-ID: <834nko2h2h.fsf@gnu.org> (raw)
In-Reply-To: <CAFEVBLuerci5HADprOyjj-9w2DQ_793mneCC4O76Jry4p_4BGA@mail.gmail.com>

> Date: Wed, 14 Nov 2012 09:14:45 +0800
> From: 李丁 <iamliding@gmail.com>
> Cc: 12878@debbugs.gnu.org
> 
> Sure, adding a correct prototype is just like including the correct
> header file if Windows 9X really supports this function. But you
> should be careful checking compiler versions, in case that
> redefinition error occur.

I added the prototype of EnumSystemLocales to one of the w32 headers.
Please try the latest emacs-24 branch (revision 110902 or later) and
see if you still have problems building it.

> Actually, I encountered several redefinition problems during compilation.
> For example in w32term.c:
> 
>     #ifndef GLYPHSET
>     /* Pre Windows 2000, this was not available, but define it here so
>        that Emacs compiled on such a platform will run on newer versions.
>  */
>     ...
>     #endif
> 
> VC 11.0 does not define GLYPHSET either (or not included), but it does have
> the definitions,
> and above code leads to redefinition error.

This is no longer in the development sources of the emacs-24 branch.
This code fragment is now guarded by "#if _WIN32_WINNT < 0x0500",
which I think should work for you, as long as you don't define
_WIN32_WINNT to a value higher than 0x0400.

> And this in w32term.c too:
> 
>     /* Reportedly, MSVC does not have this in its headers.  */
>     #ifdef _MSC_VER
>     DECLARE_HANDLE(HMONITOR);
>     #endif
> 
> VC 11.0 does have HMONITOR, and another redefinition error.

This is now guarded by "#if defined (_MSC_VER) && _WIN32_WINNT < 0x0500"
so again, I don't think that it should give you trouble with
_WIN32_WINNT set at 0x0400.

Please try the latest emacs-24 branch, and if it works for you, I will
close the bug.






  parent reply	other threads:[~2012-11-17 18:57 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-13 11:11 bug#12878: 24.2; Compiling failed on Windows 7 with VC 11 Express: _WIN32_WINNT version too low 李丁
2012-11-13 16:33 ` Eli Zaretskii
2012-11-14  1:14   ` 李丁
2012-11-14  1:32     ` 李丁
2012-11-14  3:53     ` Eli Zaretskii
2012-11-14  7:22       ` 李丁
2012-11-17 18:57     ` Eli Zaretskii [this message]
2012-11-19  5:59       ` 李丁
2012-11-19 17:42         ` Eli Zaretskii
     [not found]           ` <CAFEVBLvU+4+Q6_N4VqH+S9ujK4fkreDqiGPxnxVt=Msm62ZKXw@mail.gmail.com>
2012-11-20 17:09             ` Eli Zaretskii
2012-12-08 12:28             ` Eli Zaretskii
2017-06-22  1:15 ` npostavs

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=834nko2h2h.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=12878@debbugs.gnu.org \
    --cc=iamliding@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).