From 16538abf8d1231279133508ba15376145b818518 Mon Sep 17 00:00:00 2001 From: gramanas Date: Tue, 10 May 2022 21:12:33 +0300 Subject: autotools and check testign suite --- configure.ac | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 704b0e2..70c8713 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ # The first parameter is project name # second is version number # third is bug report address -AC_INIT([foodtools], [0.0.1]) +AC_INIT([foodtools],[0.0.1]) # Safety checks in case user overwritten --srcdir AC_CONFIG_SRCDIR([src/food.c]) @@ -16,14 +16,17 @@ AC_CONFIG_AUX_DIR([build-aux]) # ChangeLog, COPYING, AUTHORS, INSTALL, README etc. files. AM_INIT_AUTOMAKE([-Wall -Werror foreign subdir-objects dist-xz]) +AC_PROG_CC + +PKG_CHECK_MODULES([CHECK], [check >= 0.9.6]) + # Set default cflags : ${CFLAGS="-O3 -pedantic"} -# Check for C compiler -AC_PROG_CC -# We can add more checks in this section +AM_PROG_CC_C_O -PKG_CHECK_MODULES([CHECK], [check]) +# Checks for header files. +AC_CHECK_HEADERS([stdlib.h]) AC_CHECK_FUNCS([memset]) AC_CHECK_FUNCS([strcasecmp]) @@ -42,7 +45,10 @@ AC_TYPE_UINT8_T # Tells automake to create a Makefile # See https://www.gnu.org/software/automake/manual/html_node/Requirements.html -AC_CONFIG_FILES([Makefile src/Makefile tests/Makefile]) +AC_CONFIG_FILES([Makefile + src/Makefile + tests/Makefile]) +AC_REQUIRE_AUX_FILE([tap-driver.sh]) # Generate the output AC_OUTPUT -- cgit v1.2.3