Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf0df096

Browse files
committed
Rearrange some configure.in comments for better readability.
Commit configure and pg_config.h.in, missed in last configure.inupdate.
1 parentde76246 commitf0df096

File tree

3 files changed

+33
-19
lines changed

3 files changed

+33
-19
lines changed

‎configure

Lines changed: 22 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2713,12 +2713,14 @@ else
27132713
fi
27142714
fi
27152715

2716-
# The Intel compiler on Linux supports most gcc options, but not
2717-
# all of them, so only add these options if we are really using
2718-
# gcc.
2716+
# Some versions of GCC support some additional useful warning flags.
2717+
# Check whether they are supported, and add them to CFLAGS if so.
27192718

27202719
if test "$GCC" = yes; then
27212720

2721+
# ICC pretends to be GCC but it's lying; it doesn't support these options.
2722+
# So we have to check if "GCC" is really ICC.
2723+
27222724
cat >conftest.$ac_ext <<_ACEOF
27232725
/* confdefs.h. */
27242726
_ACEOF
@@ -2766,11 +2768,10 @@ sed 's/^/| /' conftest.$ac_ext >&5
27662768
ICC=no
27672769
fi
27682770
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2771+
27692772
if test "$ICC" = no; then
27702773
CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith -Winline"
27712774

2772-
# Some versions of GCC support some additional useful warning flags.
2773-
# Check whether they are supported, and add them to CFLAGS if so.
27742775
echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5
27752776
echo $ECHO_N "checking if $CC supports -Wdeclaration-after-statement... $ECHO_C" >&6
27762777
pgac_save_CFLAGS=$CFLAGS
@@ -21621,29 +21622,38 @@ esac
2162121622

2162221623

2162321624
# Select semaphore implementation type.
21624-
if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
21625+
if test "$PORTNAME" != "win32"; then
21626+
if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
2162521627

2162621628
cat >>confdefs.h <<\_ACEOF
2162721629
#define USE_NAMED_POSIX_SEMAPHORES 1
2162821630
_ACEOF
2162921631

21630-
SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21631-
else
21632-
if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
21632+
SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21633+
else
21634+
if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
2163321635

2163421636
cat >>confdefs.h <<\_ACEOF
2163521637
#define USE_UNNAMED_POSIX_SEMAPHORES 1
2163621638
_ACEOF
2163721639

21638-
SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21639-
else
21640+
SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21641+
else
2164021642

2164121643
cat >>confdefs.h <<\_ACEOF
2164221644
#define USE_SYSV_SEMAPHORES 1
2164321645
_ACEOF
2164421646

21645-
SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
21647+
SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
21648+
fi
2164621649
fi
21650+
else
21651+
21652+
cat >>confdefs.h <<\_ACEOF
21653+
#define USE_WIN32_SEMAPHORES 1
21654+
_ACEOF
21655+
21656+
SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
2164721657
fi
2164821658

2164921659

‎configure.in

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
dnl Process this file with autoconf to produce a configure script.
2-
dnl $PostgreSQL: pgsql/configure.in,v 1.463 2006/04/2916:34:41 momjian Exp $
2+
dnl $PostgreSQL: pgsql/configure.in,v 1.464 2006/04/2920:47:29 tgl Exp $
33
dnl
44
dnl Developers, please strive to achieve this order:
55
dnl
@@ -248,19 +248,20 @@ else
248248
fi
249249
fi
250250

251-
# The Intel compiler on Linux supports most gcc options, but not
252-
# all of them, so only add these options if we are really using
253-
# gcc.
251+
# Some versions of GCC support some additional useful warning flags.
252+
# Check whether they are supported, and add them to CFLAGS if so.
254253

255254
if test "$GCC" = yes; then
255+
256+
# ICC pretends to be GCC but it's lying; it doesn't support these options.
257+
# So we have to check if "GCC" is really ICC.
256258
AC_TRY_COMPILE([], [@%:@ifndef __INTEL_COMPILER
257259
choke me
258260
@%:@endif], [ICC=[yes]], [ICC=[no]])
261+
259262
if test "$ICC" = no; then
260263
CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith -Winline"
261264

262-
# Some versions of GCC support some additional useful warning flags.
263-
# Check whether they are supported, and add them to CFLAGS if so.
264265
PGAC_PROG_CC_CFLAGS_OPT([-Wdeclaration-after-statement])
265266
PGAC_PROG_CC_CFLAGS_OPT([-Wendif-labels])
266267
else

‎src/include/pg_config.h.in

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@
129129
/* Define to 1 if your compiler understands __FUNCTION__. */
130130
#undef HAVE_FUNCNAME__FUNCTION
131131

132-
/* Define to 1 if you have getaddrinfo(). */
132+
/* Define to 1 if you havethe `getaddrinfo' function. */
133133
#undef HAVE_GETADDRINFO
134134

135135
/* Define to 1 if you have the `gethostbyname_r' function. */
@@ -625,6 +625,9 @@
625625
/* Define to select unnamed POSIX semaphores. */
626626
#undef USE_UNNAMED_POSIX_SEMAPHORES
627627

628+
/* Define to select Win32-style semaphores. */
629+
#undef USE_WIN32_SEMAPHORES
630+
628631
/* Number of bits in a file offset, on hosts where this is settable. */
629632
#undef _FILE_OFFSET_BITS
630633

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp