• R/O
  • HTTP
  • SSH
  • HTTPS

hengband: Commit

変愚蛮怒のメインリポジトリです


Commit MetaInfo

Revision5878ea0923c83ca10332ab7e67d56e9b72ea58ab (tree)
Time2002-01-18 00:37:00
Authormogami <mogami@0568...>
Commitermogami

Log Message

vasprint()関数の存在を ./configure を使って知るように修正。

Change Summary

Incremental Difference

--- a/configure.in
+++ b/configure.in
@@ -73,6 +73,6 @@ AC_FUNC_MEMCMP
7373 AC_TYPE_SIGNAL
7474 AC_FUNC_STRFTIME
7575 AC_FUNC_VPRINTF
76-AC_CHECK_FUNCS(gethostname mkdir select socket strdup strstr strtol)
76+AC_CHECK_FUNCS(gethostname mkdir select socket strdup strstr strtol vasprintf vsnprintf)
7777
7878 AC_OUTPUT(Makefile src/Makefile lib/Makefile lib/apex/Makefile lib/bone/Makefile lib/data/Makefile lib/edit/Makefile lib/file/Makefile lib/help/Makefile lib/info/Makefile lib/pref/Makefile lib/save/Makefile lib/script/Makefile lib/user/Makefile lib/xtra/Makefile lib/xtra/font/Makefile lib/xtra/graf/Makefile lib/xtra/music/Makefile lib/xtra/sound/Makefile)
--- a/src/report.c
+++ b/src/report.c
@@ -47,11 +47,10 @@ typedef struct {
4747
4848 #define BUFSIZE (65536)
4949
50-#if defined(WINDOWS) || defined(SUNOS4) || defined(MACINTOSH) || defined(SGI)
50+#ifndef HAVE_VASPRINTF
5151 #define vasprintf Vasprintf
52-#endif
5352
54-#ifdef SUNOS4
53+#if defined(HAVE_VSNPRINTF)
5554 static int Vasprintf(char **buf, const char *fmt, va_list ap)
5655 {
5756 int ret;
@@ -62,9 +61,7 @@ static int Vasprintf(char **buf, const char *fmt, va_list ap)
6261
6362 return ret;
6463 }
65-#endif
66-
67-#if defined(WINDOWS) || defined(MACINTOSH) || defined(SGI)
64+#else
6865 static int Vasprintf(char **buf, const char *fmt, va_list ap)
6966 {
7067 int ret;
@@ -76,6 +73,8 @@ static int Vasprintf(char **buf, const char *fmt, va_list ap)
7673 }
7774 #endif
7875
76+#endif /* ifndef HAVE_VASPRINTF */
77+
7978 static BUF* buf_new(void)
8079 {
8180 BUF *p;
Show on old repository browser