Skip to content
Snippets Groups Projects
configure.in 860 B
Newer Older
yorhel's avatar
yorhel committed

AC_INIT(ncdu, git, projects@yorhel.nl)
AC_CONFIG_SRCDIR([src/global.h])
yorhel's avatar
yorhel committed
AC_CONFIG_HEADER([config.h])
AM_INIT_AUTOMAKE

# Checks for programs.
AC_PROG_CC
AC_PROG_INSTALL
AC_PROG_RANLIB

# Checks for libraries.
AC_CHECK_LIB(ncurses, initscr)

# Checks for header files.
Yorhel's avatar
Yorhel committed
AC_CHECK_HEADERS(
  [limits.h stdlib.h string.h sys/time.h sys/types.h sys/stat.h dirent.h unistd.h fnmatch.h ncurses.h],[],
  AC_MSG_ERROR([required header file not found]))
yorhel's avatar
yorhel committed

# Checks for typedefs, structures, and compiler characteristics.
AC_TYPE_OFF_T
AC_SYS_LARGEFILE
AC_STRUCT_ST_BLOCKS

# Checks for library functions.
Yorhel's avatar
Yorhel committed
AC_CHECK_FUNCS(
  [getcwd gettimeofday memset fnmatch chdir rmdir unlink lstat getcwd],[],
  AC_MSG_ERROR([required function missing]))
yorhel's avatar
yorhel committed

AC_OUTPUT([Makefile src/Makefile doc/Makefile])

echo ""
echo "Now type \"make\" and \"make install\" to build and install ncdu"