From 8296cd0fff593364698e3a8ca3905103eee131ee Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Fri, 1 Oct 2021 03:09:18 +0000 Subject: extconf.rb: get rid of unnecessary checks SIZEOF_*, *2NUM and NUM2* should all be defined by ruby.h and dependencies it pulls in since Ruby 2.0 and possibly earlier. INT_MAX and LLONG_MAX are in limits.h which is POSIX. HAVE_GMTIME_R is already defined by ruby/config.h, so we shouldn't have to check for it, either. Combined, these changes speed up extconf.rb by several seconds. --- ext/unicorn_http/httpdate.c | 1 + 1 file changed, 1 insertion(+) (limited to 'ext/unicorn_http/httpdate.c') diff --git a/ext/unicorn_http/httpdate.c b/ext/unicorn_http/httpdate.c index b59d038..3f512dd 100644 --- a/ext/unicorn_http/httpdate.c +++ b/ext/unicorn_http/httpdate.c @@ -11,6 +11,7 @@ static const char months[] = "Jan\0Feb\0Mar\0Apr\0May\0Jun\0" /* for people on wonky systems only */ #ifndef HAVE_GMTIME_R +# warning using fake gmtime_r static struct tm * my_gmtime_r(time_t *now, struct tm *tm) { struct tm *global = gmtime(now); -- cgit v1.2.3-24-ge0c7