From 62a1724a7fc336ebe20652a7185abd3cd7f1cb19 Mon Sep 17 00:00:00 2001 From: Louie Shprung Date: Sun, 1 Jan 2023 16:19:15 -0800 Subject: Improve configure.ac based on autoscan results --- configure.ac | 28 ++++++++++++++++++++++++---- 1 file changed, 24 insertions(+), 4 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 231f66f..86ed508 100644 --- a/configure.ac +++ b/configure.ac @@ -1,12 +1,32 @@ AC_INIT([simple-snake], [0.1]) +AC_CONFIG_SRCDIR([src/draw.c]) +AC_CONFIG_HEADERS([config.h]) + AM_INIT_AUTOMAKE + +# Checks for programs AC_PROG_CC -AC_CONFIG_FILES([ - Makefile - src/Makefile - ]) + +# Checks for libraries. +AC_CHECK_LIB([m], [log10]) + +# Checks for header files. +AC_CHECK_HEADERS([stdlib.h string.h unistd.h]) + +# Checks for typedefs, structures, and compiler characteristics. +AC_CHECK_HEADER_STDBOOL + +# Checks for library functions. +AC_FUNC_MALLOC +AC_CHECK_FUNCS([mkdir]) + +AC_CONFIG_FILES([Makefile + src/Makefile]) + +# Additional Macro Checks AX_WITH_CURSES if test "x$ax_cv_curses" != xyes; then AC_MSG_ERROR([requires an X/Open-compatible Curses library with color]) fi + AC_OUTPUT -- cgit