pgsql: Use return instead of exit() in configure - Mailing list pgsql-committers

From Tom Lane
Subject pgsql: Use return instead of exit() in configure
Date
Msg-id E1mwUvq-0003nj-E2@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Use return instead of exit() in configure

Using exit() requires stdlib.h, which is not included.  Use return
instead.  Also add return type for main().

This back-patches commit 1c0cf52b3 into out-of-support branches,
pursuant to a newly-established project policy that we'll try to keep
out-of-support branches buildable on modern platforms for at least
ten major releases back, ensuring people can test pg_dump and psql
compatibility against servers that far back.  With the current
development branch being v15, that works out to keeping 9.2 and up
buildable as of today.

This fix is needed to get through 'configure' when using recent
macOS (and possibly other clang-based toolchains).  It seems to
be sufficient to get through 'check-world', although there are
annoyances such as compiler warnings, which will be dealt with
separately.

Original patch by Peter Eisentraut

Discussion: https://postgr.es/m/d0316012-ece7-7b7e-2d36-9c38cb77cb3b@enterprisedb.com

Branch
------
REL9_2_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/fed9cf2cb9ef4cdc3fe8b09dc2eb19e82fe1cc8b

Modified Files
--------------
config/c-compiler.m4 |  4 +++-
config/c-library.m4  |  4 +++-
configure            | 12 +++++++++---
3 files changed, 15 insertions(+), 5 deletions(-)


pgsql-committers by date:

Previous
From: Tom Lane
Date:
Subject: pgsql: Create a new type category for "internal use" types.
Next
From: Tom Lane
Date:
Subject: pgsql: Add checks for valid multibyte character length in UtfToLocal, L