summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEd Beroset <beroset@mindspring.com>2004-12-15 23:02:20 +0000
committerEd Beroset <beroset@mindspring.com>2004-12-15 23:02:20 +0000
commita5d2945b7b02d17f52fcebf6b52ec2da2ba995c2 (patch)
tree0f9a2e6948e1a8bfca2b1c76d9da5914c25f0873
parent258fcafe887b94ed0644303c80c0f79f65cdfe58 (diff)
downloadnasm-a5d2945b7b02d17f52fcebf6b52ec2da2ba995c2.tar.gz
nasm-a5d2945b7b02d17f52fcebf6b52ec2da2ba995c2.tar.bz2
nasm-a5d2945b7b02d17f52fcebf6b52ec2da2ba995c2.zip
added checks for vsnprintf and snprintf (ISO C99) and changed gcc
compile flag from -ansi to -std=c99
-rw-r--r--configure.in12
1 files changed, 11 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index d359399..fab5140 100644
--- a/configure.in
+++ b/configure.in
@@ -60,7 +60,7 @@ fi
AC_PROG_INSTALL
if test "$GCC" = "yes"; then
- GCCFLAGS="-Wall -ansi -pedantic"
+ GCCFLAGS="-Wall -std=c99 -pedantic"
else
GCCFLAGS=
fi
@@ -108,6 +108,16 @@ if test $ac_cv_func_strspn = no; then
AC_MSG_ERROR([NASM requires ANSI C (specifically, "strspn")])
fi
+AC_CHECK_FUNCS(snprintf)
+if test $ac_cv_func_snprintf = no; then
+ AC_MSG_ERROR([NASM requires ISO C99 (specifically, "snprintf")])
+fi
+
+AC_CHECK_FUNCS(vsnprintf)
+if test $ac_cv_func_snprintf = no; then
+ AC_MSG_ERROR([NASM requires ISO C99 (specifically, "vsnprintf")])
+fi
+
if test $ac_cv_prog_make_vpathok = no; then
echo Copying generated srcs into build directory to compensate for VPATH breakage
for file in macros.c insnsa.c insnsd.c insnsn.c insnsi.h version.h version.mac; do