Commit 6058495f authored by Emmanuele Bassi's avatar Emmanuele Bassi

Use C locale when building gtktypefuncs.c

We're using [a-z] ranges with sed and grep, and POSIX does not specify
their behaviour in non-ASCII locales:

  In the POSIX locale, a range expression represents the set of
  collating elements that fall between two elements in the collation
  sequence, inclusive. In other locales, a range expression has
  unspecified behavior
    -- IEEE Std 1003.1-2017, § 9.3.5 (7)

This can lead to no results, or invalid replacements, which in turn can
lead to broken builds or broken build artifacts.

Fixes: #1662
parent 68a7da71
Pipeline #59218 passed with stage
in 6 minutes and 42 seconds
......@@ -1445,7 +1445,8 @@ gtkprivatetypebuiltins.c: $(gtk_private_type_h_sources) gtkprivatetypebuiltins.
gtktypefuncs.c: stamp-gtktypebuiltins.h stamp-gtkprivatetypebuiltins.h $(top_srcdir)/gtk/*.h $(top_srcdir)/gtk/a11y/*.h $(top_srcdir)/gtk/deprecated/*.h $(top_srcdir)/gdk/*.h Makefile
$(AM_V_GEN) (echo '#undef GTK_COMPILATION' && echo '#include <gtk/gtkx.h>') > xgen-gtfsrc.c && \
$(AM_V_GEN) export LC_ALL=C ; \
(echo '#undef GTK_COMPILATION' && echo '#include <gtk/gtkx.h>') > xgen-gtfsrc.c && \
${CPP} $(DEFS) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) xgen-gtfsrc.c | \
$(GREP) -o '\bg[td]k_[a-zA-Z0-9_]*_get_type\b' | \
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment