From df25b8d61d722842251d58bee32e067b7992c06c Mon Sep 17 00:00:00 2001 From: Alex Kotov Date: Fri, 27 Nov 2020 18:43:58 +0500 Subject: [PATCH] Specify C99 standard in autoconf --- README.md | 2 +- configure.ac | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index f9d3c59..8659c6a 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,7 @@ Configure with cross-compiler in `$PATH` to make without it in `$PATH`: AR="$(which i686-elf-ar)" \ CC="$(which i686-elf-gcc)" \ RANLIB="$(which i686-elf-ranlib)" \ - CFLAGS='-std=gnu99 -ffreestanding -nostdinc -nostdlib -fno-builtin -fno-stack-protector -Wall -Wextra' + CFLAGS='-ffreestanding -nostdinc -nostdlib -fno-builtin -fno-stack-protector -Wall -Wextra' ``` Check if compilation targets i386: `objdump -d src/arch/i386.o`. diff --git a/configure.ac b/configure.ac index 06631b0..d40ce8b 100644 --- a/configure.ac +++ b/configure.ac @@ -20,6 +20,7 @@ AC_LANG([C]) AM_PROG_AR AM_PROG_AS AC_PROG_CC +AC_PROG_CC_C99 AC_PROG_RANLIB AC_OUTPUT