From: "Vincent Belaïche" <vincent.b.1@hotmail.fr>
To: "Dani Moncayo" <dmoncayo@gmail.com>, "Óscar Fuentes" <ofv@wanadoo.es>
Cc: emacs-devel <emacs-devel@gnu.org>
Subject: RE: Latest EMACS on BZR trunk does not compile with MinGW
Date: Thu, 5 Jun 2014 11:03:57 +0200 [thread overview]
Message-ID: <DUB109-W11D98867754BE29BE7301D842D0@phx.gbl> (raw)
In-Reply-To: <CAH8Pv0j2U+NMuF-YArabdL6jWZk9wQwLoav54BF3y=DNETkBEw@mail.gmail.com>
Er, I feel a bit awkward that I have caused such a long discussion.
After adding a
source /etc/profile
line at the top of my ~/.bash_profile, everything went ok.
I think that MSYS users should simply keep the definition from the /etc/profile, I simply did not realize when I created my ~/.bash_profile that the /etc/profile would no longer be sourced.
Anyway, shouldn't it be delegated to autotools to do that job of detecting the environement and whether the user is a naughty boy/girl that did not sourced his/her /etc/profile...
In the EMACS source code you would then just use some
#ifdef HAVE_WIN32_LEAN_AND_MEAN
...
#endif
Where HAVE_WIN32_LEAN_AND_MEAN would be from the config.h file generated by autotools.
That would be wiser as other programs than EMACS could have the same case, so it is not worth re-inventing the wheel every time.
So the way forward should be to ask autotools people whether any such thing as HAVE_WIN32_LEAN_AND_MEAN already exists, and if not make some contribution, eg based on the pwd -W suggestion made, or on making some C test program + try and compile it, as autotools often do.
VBR,
Vincent.
----------------------------------------
> Date: Thu, 5 Jun 2014 09:03:03 +0200
> Subject: Re: Latest EMACS on BZR trunk does not compile with MinGW
> From: dmoncayo@gmail.com
> To: ofv@wanadoo.es
> CC: emacs-devel@gnu.org
>
>>>> How 'bout testing a functionality on which we rely during the build,
>>>> rather than looking for some indirect evidence?
>>>
>>> Chicken-and-egg problem: that test is there so that we could source
>>> nt/mingw-cfg.site file, which does what you want.
>>
>> Why not test if the preprocessor defines __MINGW32__?
>
> Another alternative, just for the record: AFAIK, only the MSYS bash
> supports a "-W" switch for its "pwd" command.
>
> So, we could do something like:
>
> if pwd -W 1>/dev/null 2>&1
> then
> echo This is MSYS
> else
> echo This is not MSYS
> fi
>
> --
> Dani Moncayo
>
next prev parent reply other threads:[~2014-06-05 9:03 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-03 20:00 Latest EMACS on BZR trunk does not compile with MinGW Vincent Belaïche
2014-06-03 20:22 ` Paul Eggert
2014-06-03 20:56 ` Óscar Fuentes
2014-06-03 21:15 ` Eli Zaretskii
2014-06-03 21:21 ` Vincent Belaïche
2014-06-04 6:47 ` Eli Zaretskii
2014-06-04 13:17 ` Vincent Belaïche
2014-06-04 13:31 ` Eli Zaretskii
2014-06-04 15:28 ` Vincent Belaïche
2014-06-04 15:44 ` Eli Zaretskii
2014-06-04 15:54 ` Dani Moncayo
2014-06-04 16:05 ` Eli Zaretskii
2014-06-04 21:50 ` Dani Moncayo
2014-06-05 0:42 ` Stefan Monnier
2014-06-05 2:51 ` Eli Zaretskii
2014-06-05 3:40 ` Óscar Fuentes
2014-06-05 7:03 ` Dani Moncayo
2014-06-05 9:03 ` Vincent Belaïche [this message]
2014-06-05 15:09 ` Eli Zaretskii
2014-06-05 14:51 ` Eli Zaretskii
2014-06-05 16:19 ` Óscar Fuentes
2014-06-05 17:52 ` Eli Zaretskii
2014-06-05 13:31 ` Stefan Monnier
2014-06-05 15:15 ` Eli Zaretskii
2014-06-05 16:50 ` Stefan Monnier
2014-06-05 18:07 ` Eli Zaretskii
2014-06-05 19:35 ` Paul Eggert
2014-06-05 19:54 ` Eli Zaretskii
2014-06-10 19:25 ` Dani Moncayo
2014-06-10 20:21 ` Eli Zaretskii
2014-06-05 20:54 ` Stefan Monnier
2014-06-05 2:47 ` Eli Zaretskii
2014-06-04 12:22 ` Using Qunsupported__w32_dialog Dmitry Antipov
2014-06-04 13:09 ` Eli Zaretskii
2014-06-04 13:37 ` Dmitry Antipov
2014-06-04 13:47 ` Eli Zaretskii
2014-06-04 14:06 ` Eli Zaretskii
2014-06-03 21:14 ` Latest EMACS on BZR trunk does not compile with MinGW Eli Zaretskii
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=DUB109-W11D98867754BE29BE7301D842D0@phx.gbl \
--to=vincent.b.1@hotmail.fr \
--cc=dmoncayo@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=ofv@wanadoo.es \
/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).