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

Commit220941d

Browse files
committed
Add in srandom() check to configure
Add appropriate HAVE_{RANDOM,SRANDOM} values to config.hAdd approrpiate #ifdef's to sparc_solaris port files for Solaris v2.6
1 parent2a3e282 commit220941d

File tree

5 files changed

+18
-4
lines changed

5 files changed

+18
-4
lines changed

‎src/backend/port/sparc_solaris/port-protos.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
*
77
* Copyright (c) 1994, Regents of the University of California
88
*
9-
* $Id: port-protos.h,v 1.6 1997/09/08 02:27:06 momjian Exp $
9+
* $Id: port-protos.h,v 1.7 1997/09/18 16:09:14 scrappy Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
@@ -36,8 +36,12 @@
3636
#definepg_dlerrordlerror
3737

3838
/* port.c */
39+
#ifndefHAVE_RANDOM
3940
externlongrandom(void);
41+
#endif
42+
#ifndefHAVE_SRANDOM
4043
externvoidsrandom(intseed);
44+
#endif
4145

4246
/* inet_aton.c in backend/port directory */
4347
externintinet_aton(constchar*cp,structin_addr*addr);

‎src/backend/port/sparc_solaris/port.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/port/sparc_solaris/Attic/port.c,v 1.6 1997/09/08 02:27:07 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/port/sparc_solaris/Attic/port.c,v 1.7 1997/09/18 16:09:15 scrappy Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -22,17 +22,21 @@
2222
#include"rusagestub.h"
2323
#endif/* HAVE_GETRUSAGE */
2424

25+
#ifndefHAVE_RANDOM
2526
long
2627
random()
2728
{
2829
return (lrand48());
2930
}
31+
#endif
3032

33+
#ifndefHAVE_RANDOM
3134
void
3235
srandom(intseed)
3336
{
3437
srand48((longint)seed);
3538
}
39+
#endif
3640

3741
#ifndefHAVE_GETRUSAGE
3842
int

‎src/configure

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3466,7 +3466,7 @@ else
34663466
fi
34673467
done
34683468

3469-
forac_funcin sigprocmask waitpid setsid random fcvt
3469+
forac_funcin sigprocmask waitpid setsid randomsrandomfcvt
34703470
do
34713471
echo$ac_n"checking for$ac_func""...$ac_c"1>&6
34723472
echo"configure:3473: checking for$ac_func">&5

‎src/configure.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -416,7 +416,7 @@ AC_FUNC_MEMCMP
416416
AC_TYPE_SIGNAL
417417
AC_FUNC_VPRINTF
418418
AC_CHECK_FUNCS(isinf tzset getrusage vfork memmove sigsetjmp kill sysconf)
419-
AC_CHECK_FUNCS(sigprocmask waitpid setsid random fcvt)
419+
AC_CHECK_FUNCS(sigprocmask waitpid setsid randomsrandomfcvt)
420420
AC_CHECK_FUNC(inet_aton, AC_DEFINE(HAVE_INET_ATON), INET_ATON='inet_aton.o')
421421
AC_CHECK_FUNC(strerror, AC_DEFINE(HAVE_STRERROR), [STRERROR='strerror.o' STRERROR2='../../backend/port/strerror.o'])
422422
AC_CHECK_FUNC(strdup, AC_DEFINE(HAVE_STRDUP), STRDUP='../../utils/strdup.o')

‎src/include/config.h.in

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,12 @@
104104
/* Set to 1 if you have strdup() */
105105
#undef HAVE_STRDUP
106106

107+
/* Set to 1 if you have random() */
108+
#undef HAVE_RANDOM
109+
110+
/* Set to 1 if you have srandom() */
111+
#undef HAVE_SRANDOM
112+
107113
/* Set to 1 if you have libreadline.a */
108114
#undef HAVE_LIBREADLINE
109115

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp