From: 李丁 <iamliding@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
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: Wed, 14 Nov 2012 09:14:45 +0800 [thread overview]
Message-ID: <CAFEVBLuerci5HADprOyjj-9w2DQ_793mneCC4O76Jry4p_4BGA@mail.gmail.com> (raw)
In-Reply-To: <83haotv4wf.fsf@gnu.org>
[-- Attachment #1: Type: text/plain, Size: 2038 bytes --]
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.
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.
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.
Maybe VC 11.0 has not been widely used, but these small problems should be
resolved.
2012/11/14 Eli Zaretskii <eliz@gnu.org>
> > Date: Tue, 13 Nov 2012 19:11:34 +0800
> > From: 李丁 <iamliding@gmail.com>
> >
> > I tried to compile emacs 24.2 on Windows 7 with Visual C++ 11.0 Express,
> > and I found that EnumSystemLocales in w32proc.c and w32select.c were
> > compiled as is (not as __stdcall function with postfix decorations),
> which
> > causes the linking failure.
> >
> > I read through the sources and found that config.h defined _WIN32_WINNT
> as
> > 0x0400, which corresponds to Windows NT4. However MSDN says that
> > EnumSystemLocales requires at least Windows 2000 (0x0500). So you should
> > probably either require a higher Windows version or use some other
> > mechanism to accomplish what EnumSystemLocales does.
>
> Would adding a correct prototype for EnumSystemLocales to w32term.h
> (included by both source files you mention) do the trick?
>
> (I don't want to bump up _WIN32_WINNT, because that might produce an
> executable which won't run on Windows 9X, which we still try to
> support.)
>
[-- Attachment #2: Type: text/html, Size: 2899 bytes --]
next prev parent reply other threads:[~2012-11-14 1:14 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 ` 李丁 [this message]
2012-11-14 1:32 ` 李丁
2012-11-14 3:53 ` Eli Zaretskii
2012-11-14 7:22 ` 李丁
2012-11-17 18:57 ` Eli Zaretskii
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAFEVBLuerci5HADprOyjj-9w2DQ_793mneCC4O76Jry4p_4BGA@mail.gmail.com \
--to=iamliding@gmail.com \
--cc=12878@debbugs.gnu.org \
--cc=eliz@gnu.org \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.