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 2.5KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  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_C_INLINE
  27. AC_C_CONST
  28. AC_PROG_CC
  29. AM_PROG_CC_C_O
  30. AC_PROG_MAKE_SET
  31. AC_PROG_RANLIB
  32. AC_CHECK_PROGS([DOXYGEN], [doxygen])
  33. if test -z "$DOXYGEN";
  34. then AC_MSG_WARN([Doxygen not found - continuing without Doxygen support])
  35. fi
  36. AC_CHECK_PROGS([DOXYGEN], [doxygen])
  37. if test -z "$DOXYGEN";
  38. then AC_MSG_WARN([Doxygen not found - continuing without Doxygen support])
  39. fi
  40. AC_CHECK_PROGS([GIT], [git])
  41. if test -z "$DOXYGEN";
  42. then AC_MSG_WARN([git not found - continuing without Doxygen support])
  43. fi
  44. # Checks for libraries.
  45. AC_SEARCH_LIBS([dlopen], [dl dld], [], [
  46. AC_MSG_ERROR([unable to find the dlopen() function])
  47. ])
  48. PKG_CHECK_MODULES([CHECK], [check >= 0.9.4])
  49. AS_IF([test x$debug = xtrue], [CK_FORK=no],[])
  50. # Checks for header files.
  51. AC_CHECK_HEADERS([stdlib.h string.h])
  52. # Checks for typedefs, structures, and compiler characteristics.
  53. AC_TYPE_SIZE_T
  54. AS_IF([test x$debug = xtrue], [
  55. AX_CHECK_CFLAGS([-Wall])
  56. AX_CHECK_CFLAGS([-g])
  57. AX_CHECK_CFLAGS([-ggdb])
  58. AX_CHECK_CFLAGS([-O0])
  59. ],
  60. [
  61. AX_CHECK_CFLAGS([-O2])
  62. AX_CHECK_CFLAGS([-std=c99 -pedantic])
  63. AX_CHECK_CFLAGS([-ansi])
  64. AX_CHECK_CFLAGS([-Wall -Werror])
  65. AX_CHECK_CFLAGS([-fgnu89-inline])
  66. ])
  67. AX_CHECK_CFLAGS([-D_XOPEN_SOURCE -D_GNU_SOURCE])
  68. #Condition done in Makefile.am
  69. #AS_IF([test x$huge_file = xtrue], [
  70. #AX_CHECK_CFLAGS([-DTTAIL_HUGE_FILE])
  71. #],[])
  72. # Checks for library functions.
  73. AC_FUNC_MALLOC
  74. AC_FUNC_REALLOC
  75. AC_CONFIG_FILES([Makefile
  76. src/Makefile
  77. tests/Makefile])
  78. AM_CONDITIONAL([HAVE_DOXYGEN],
  79. [test -n "$DOXYGEN"])AM_COND_IF([HAVE_DOXYGEN], [AC_CONFIG_FILES([docs/Doxyfile
  80. docs/Makefile])])
  81. AC_OUTPUT