timed tail for logfiles. Display loglines given a minimum date and/or a maximum date.
c
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

configure.ac 1.9KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. # -*- Autoconf -*-
  2. # Process this file with autoconf to produce a configure script.
  3. AC_PREREQ([2.69])
  4. AC_INIT([ttail], [0.0.1], [yann.weber@member.fsf.org])
  5. AM_INIT_AUTOMAKE
  6. #configure options
  7. AC_ARG_ENABLE([huge-file],[ --enable-huge-file to enable huge file support],
  8. [case "${enableval}" in
  9. yes) huge_file=true ;;
  10. no) huge_file=false ;;
  11. *) AC_MSG_ERROR([bad value ${enableval} for --enable-huge-file]) ;;
  12. esac],[huge_file=false])
  13. AM_CONDITIONAL([HUGEFILE], [test x$huge_file = xtrue])
  14. AC_ARG_ENABLE([debug],[ --enable-debug turn on debugging],
  15. [case "${enableval}" in
  16. yes) debug=true ;;
  17. no) debug=false ;;
  18. *) AC_MSG_ERROR([bad value ${enableval} for --enable-debug]) ;;
  19. esac],[debug=false])
  20. AM_CONDITIONAL([DEBUG], [test x$debug = xtrue])
  21. AC_CONFIG_HEADERS([src/include/config.h])
  22. AC_CONFIG_SRCDIR([src/main.c])
  23. AC_CONFIG_MACRO_DIR([m4])
  24. # Checks for programs.
  25. AC_GNU_SOURCE
  26. AC_PROG_CC
  27. AM_PROG_CC_C_O
  28. AC_PROG_MAKE_SET
  29. AC_PROG_RANLIB
  30. # Checks for libraries.
  31. AC_SEARCH_LIBS([dlopen], [dl dld], [], [
  32. AC_MSG_ERROR([unable to find the dlopen() function])
  33. ])
  34. PKG_CHECK_MODULES([CHECK], [check >= 0.9.4])
  35. AS_IF([test x$debug = xtrue], [CK_FORK=no],[])
  36. # Checks for header files.
  37. AC_CHECK_HEADERS([stdlib.h string.h])
  38. # Checks for typedefs, structures, and compiler characteristics.
  39. AC_TYPE_SIZE_T
  40. AS_IF([test x$debug = xtrue], [
  41. AX_CHECK_CFLAGS([-Wall])
  42. AX_CHECK_CFLAGS([-g])
  43. AX_CHECK_CFLAGS([-ggdb])
  44. AX_CHECK_CFLAGS([-O0])
  45. ],
  46. [
  47. AX_CHECK_CFLAGS([-O2])
  48. AX_CHECK_CFLAGS([-std=c99 -pedantic])
  49. AX_CHECK_CFLAGS([-ansi])
  50. AX_CHECK_CFLAGS([-Wall -Werror])
  51. AX_CHECK_CFLAGS([-fgnu89-inline])
  52. ])
  53. AX_CHECK_CFLAGS([-D_XOPEN_SOURCE -D_GNU_SOURCE])
  54. #Condition done in Makefile.am
  55. #AS_IF([test x$huge_file = xtrue], [
  56. #AX_CHECK_CFLAGS([-DTTAIL_HUGE_FILE])
  57. #],[])
  58. # Checks for library functions.
  59. AC_FUNC_MALLOC
  60. AC_FUNC_REALLOC
  61. AC_CONFIG_FILES([Makefile
  62. src/Makefile
  63. tests/Makefile])
  64. AC_OUTPUT