Welcome! Log In Create A New Profile

Advanced

Re: [PATCH] Fix ./configure script for less error-forgiving compilers

Maxim Dounin
November 11, 2010 09:34AM
Hello!

On Mon, Aug 16, 2010 at 06:01:27AM +0200, Piotr Sikora wrote:

> Hi Igor,
> attached patch fixes ./configure script for less error-forgiving
> compilers (like LLVM/clang) when they are used with -Werror option.
>
> auto/types/sizeof:
> - printf() is defined in missing <stdio.h> header,
> - sizeof() returns size_t type, which has different signedness on
> different operating systems (hence %z).

POSIX mandates size_t to be unsigned[1]:

% size_t
% Unsigned integer type of the result of the sizeof operator.

[1] http://www.opengroup.org/onlinepubs/9699919799/basedefs/stddef.h.html

And C does the same:

% 7.17 Common definitions <stddef.h>
....
% size_t
% which is the unsigned integer type of the result of the sizeof
% operator;

I belive this should be changed to "%zu" (instead of "%zd" in your
patch).

Otherwise looks good.

Maxim Dounin

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[PATCH] Fix ./configure script for less error-forgiving compilers Attachments

Piotr Sikora 1998 August 16, 2010 12:02AM

Re: [PATCH] Fix ./configure script for less error-forgiving compilers Attachments

Piotr Sikora 775 August 24, 2010 02:16PM

Re: [PATCH] Fix ./configure script for less error-forgiving compilers

Maxim Dounin 622 November 11, 2010 09:34AM

Re: [PATCH] Fix ./configure script for less error-forgiving compilers Attachments

Piotr Sikora 785 November 11, 2010 04:54PM

Re: [PATCH] Fix ./configure script for less error-forgiving compilers

Piotr Sikora 354 March 05, 2012 04:28PM

Re: [PATCH] Fix ./configure script for less error-forgiving compilers Attachments

Piotr Sikora 435 March 05, 2012 04:40PM

Re: [PATCH] Fix ./configure script for less error-forgiving compilers

Ruslan Ermilov 446 March 06, 2012 03:46AM

Re: [PATCH] Fix ./configure script for less error-forgiving compilers

Piotr Sikora 406 March 06, 2012 09:52AM

Re: [PATCH] Fix ./configure script for less error-forgiving compilers

Maxim Dounin 480 March 15, 2012 02:06PM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 137
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready