Re: [PATCH/RFC] mingw: rename WIN32 cpp macro to NATIVE_WINDOWS
- From
Mark Levedahl <mlevedahl@gmail.com>
- Date
- Jan 26, 2013, 14:11 UTC
- Message-ID
- <5103E418.7090104@gmail.com>
- In-Reply-To
- <20130126010359.GH3341@elie.Belkin>
On 01/25/2013 08:03 PM, Jonathan Nieder wrote:
Show 15 quoted lines
> diff --git a/abspath.c b/abspath.c
> index 40cdc462..c7d5458e 100644
> --- a/abspath.c
> +++ b/abspath.c
> @@ -216,7 +216,7 @@ const char *absolute_path(const char *path)
> const char *prefix_filename(const char *pfx, int pfx_len, const char *arg)
> {
> static char path[PATH_MAX];
> -#ifndef WIN32
> +#ifndef WINDOWS_NATIVE
> if (!pfx_len || is_absolute_path(arg))
> return arg;
> memcpy(path, pfx, pfx_len);
> diff --git a/compat/terminal.c b/compat/terminal.c
> index 9b5e3d1b..136e4a74 100644Maybe WINDOWS_NATIVE should be defined in config.mak.uname?
Otherwise, I tested the patch and it does build / run on Cygwin, but I cannot run a test suite until next week. I am concerned about subtle changes due to the various WIN32 tests that were not guarded by __CYGWIN__ before, haven't stared at the code enough to see if there could be an issue.
Mark