mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-23 20:30:15 +00:00
Check for _NL_TIME_FIRST_WEEKDAY too, since it is an enum value, not a
2005-01-14 Matthias Clasen <mclasen@redhat.com> * configure.in: Check for _NL_TIME_FIRST_WEEKDAY too, since it is an enum value, not a define. Pointed out by Tommi Komulainen. * gtk/gtkcalendar.c (gtk_calendar_init): Adapt.
This commit is contained in:
parent
84fcadeb52
commit
61ededc855
@ -1,7 +1,13 @@
|
||||
2005-01-14 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* configure.in: Check for _NL_TIME_FIRST_WEEKDAY too, since it
|
||||
is an enum value, not a define. Pointed out by Tommi Komulainen.
|
||||
* gtk/gtkcalendar.c (gtk_calendar_init): Adapt.
|
||||
|
||||
2005-01-13 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* configure.in: Check for nl_langinfo()
|
||||
* gtk/gtkcalendar.c: (gtk_calendar_init): Use nl_langinfo() when it's
|
||||
* gtk/gtkcalendar.c (gtk_calendar_init): Use nl_langinfo() when it's
|
||||
available to determine first day of week (#163842, Vincent Untz)
|
||||
|
||||
* gtk/gtkuimanager.c (gtk_ui_manager_get_widget): Add hints about
|
||||
|
@ -1,7 +1,13 @@
|
||||
2005-01-14 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* configure.in: Check for _NL_TIME_FIRST_WEEKDAY too, since it
|
||||
is an enum value, not a define. Pointed out by Tommi Komulainen.
|
||||
* gtk/gtkcalendar.c (gtk_calendar_init): Adapt.
|
||||
|
||||
2005-01-13 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* configure.in: Check for nl_langinfo()
|
||||
* gtk/gtkcalendar.c: (gtk_calendar_init): Use nl_langinfo() when it's
|
||||
* gtk/gtkcalendar.c (gtk_calendar_init): Use nl_langinfo() when it's
|
||||
available to determine first day of week (#163842, Vincent Untz)
|
||||
|
||||
* gtk/gtkuimanager.c (gtk_ui_manager_get_widget): Add hints about
|
||||
|
@ -1,7 +1,13 @@
|
||||
2005-01-14 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* configure.in: Check for _NL_TIME_FIRST_WEEKDAY too, since it
|
||||
is an enum value, not a define. Pointed out by Tommi Komulainen.
|
||||
* gtk/gtkcalendar.c (gtk_calendar_init): Adapt.
|
||||
|
||||
2005-01-13 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* configure.in: Check for nl_langinfo()
|
||||
* gtk/gtkcalendar.c: (gtk_calendar_init): Use nl_langinfo() when it's
|
||||
* gtk/gtkcalendar.c (gtk_calendar_init): Use nl_langinfo() when it's
|
||||
available to determine first day of week (#163842, Vincent Untz)
|
||||
|
||||
* gtk/gtkuimanager.c (gtk_ui_manager_get_widget): Add hints about
|
||||
|
14
configure.in
14
configure.in
@ -396,7 +396,19 @@ if test "x$enable_rebuilds" = "xyes" && \
|
||||
fi
|
||||
AC_SUBST(REBUILD)
|
||||
|
||||
AC_CHECK_FUNCS(lstat mkstemp flockfile nl_langinfo)
|
||||
AC_CHECK_FUNCS(lstat mkstemp flockfile)
|
||||
|
||||
# _NL_TIME_FIRST_WEEKDAY is an enum and not a define
|
||||
AC_MSG_CHECKING([for _NL_TIME_FIRST_WEEKDAY])
|
||||
AC_TRY_LINK([#include <langinfo.h>], [
|
||||
char c;
|
||||
c = *((unsigned char *) nl_langinfo(_NL_TIME_FIRST_WEEKDAY));
|
||||
], gtk_ok=yes, gtk_ok=no)
|
||||
AC_MSG_RESULT($gtk_ok)
|
||||
if test "$gtk_ok" = "yes"; then
|
||||
AC_DEFINE([HAVE__NL_TIME_FIRST_WEEKDAY], [1],
|
||||
[Define if _NL_TIME_FIRST_WEEKDAY is available])
|
||||
fi
|
||||
|
||||
# sigsetjmp is a macro on some platforms, so AC_CHECK_FUNCS is not reliable
|
||||
AC_MSG_CHECKING(for sigsetjmp)
|
||||
|
@ -34,7 +34,7 @@
|
||||
#ifdef HAVE_SYS_TIME_H
|
||||
#include <sys/time.h>
|
||||
#endif
|
||||
#ifdef HAVE_NL_LANGINFO
|
||||
#ifdef HAVE__NL_TIME_FIRST_WEEKDAY
|
||||
#include <langinfo.h>
|
||||
#endif
|
||||
#include <string.h>
|
||||
@ -706,7 +706,7 @@ gtk_calendar_init (GtkCalendar *calendar)
|
||||
else if (strcmp (year_before, "calendar:MY") != 0)
|
||||
g_warning ("Whoever translated calendar:MY did so wrongly.\n");
|
||||
|
||||
#if defined (HAVE_NL_LANGINFO) && defined (_NL_TIME_FIRST_WEEKDAY)
|
||||
#ifdef HAVE__NL_TIME_FIRST_WEEKDAY
|
||||
week_start = nl_langinfo (_NL_TIME_FIRST_WEEKDAY);
|
||||
private_data->week_start = *((unsigned char *) week_start) % 7;
|
||||
#else
|
||||
|
Loading…
Reference in New Issue
Block a user