git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] compat/regex: fix compilation on Windows

From
Junio C Hamano <gitster@pobox.com>
Date
May 12, 2017, 21:26 UTC
Message-ID
<xmqqy3u14vim.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<alpine.DEB.2.21.1.1705121219150.146734@virtualbox>
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
Show 15 quoted lines
> I'd place a bet on this part of compat/mingw.h for GCC builds:
>
> 	#ifdef __MINGW64_VERSION_MAJOR
> 	#include <stdint.h>
> 	#include <wchar.h>
> 	typedef _sigset_t sigset_t;
> 	#endif
>
> and on this part of git-compat-util.h for MSVC builds:
>
> 	#ifndef NO_INTTYPES_H
> 	#include <inttypes.h>
> 	#else
> 	#include <stdint.h>
> 	#endif

Yeah, but I had an impression that git-compat-util.h was not in use to build compat/regex/regex.o (regex.c #include's regcomp.c which is a rather unusual arragement), and that was why I am wondering.

Show 11 quoted lines
> For the record, it seems that our current version of compat/regex/regex.c
> has this:
>
> 	/* On some systems, limits.h sets RE_DUP_MAX to a lower value than
> 	   GNU regex allows.  Include it before <regex.h>, which correctly
> 	   #undefs RE_DUP_MAX and sets it to the right value.  */
> 	#include <limits.h>
> 	#include <stdint.h>
>
> while the one in `pu` lacks the last line. That may be the reason why
> things compiled neatly before, and stopped working for you now.

Yes, that explains how the old one worked and the new one didn't without dropping "#ifdef HAVE_STDINT_H".

Thanks.
Previous: Ramsay JonesNext: Ævar Arnfjörð Bjarmason
Message 6 of 10 in “compat/regex: fix compilation on Windows”
  1. compat/regex: fix compilation on WindowsJohannes Schindelin, May 11, 2017
  2. Ævar Arnfjörð BjarmasonMay 11, 2017
  3. Junio C HamanoMay 12, 2017
  4. Johannes SchindelinMay 12, 2017
  5. Ramsay JonesMay 12, 2017
  6. Junio C HamanoMay 12, 2017
  7. Ævar Arnfjörð BjarmasonMay 12, 2017
  8. Johannes SchindelinMay 13, 2017
  9. Ævar Arnfjörð BjarmasonMay 13, 2017
  10. Junio C HamanoMay 15, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.