configure.ac 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. # -*- Autoconf -*-
  2. # Process this file with autoconf to produce a configure script.
  3. AC_PREREQ([2.69])
  4. AC_INIT([geresh], [0.6.4])
  5. AC_CONFIG_SRCDIR([geresh.1])
  6. AM_INIT_AUTOMAKE
  7. AC_CONFIG_HEADERS([config.h])
  8. # Checks for programs.
  9. AC_PROG_CXX
  10. AC_PROG_CC
  11. # Checks for libraries.
  12. # Checks for header files.
  13. AC_CHECK_HEADERS([fcntl.h langinfo.h libintl.h locale.h stdlib.h string.h sys/time.h termios.h unistd.h wchar.h])
  14. # Checks for typedefs, structures, and compiler characteristics.
  15. AC_CHECK_HEADER_STDBOOL
  16. AC_C_INLINE
  17. AC_TYPE_MODE_T
  18. AC_TYPE_PID_T
  19. AC_TYPE_SIZE_T
  20. AC_TYPE_SSIZE_T
  21. # FIXME: Do we really need to bother with platforms that don't support
  22. # UTF-8?
  23. AC_DEFINE_UNQUOTED(DEFAULT_FILE_ENCODING, "UTF-8", "Default encoding")
  24. AC_HEADER_DIRENT
  25. dnl FIXME: AC_TYPE_SIGNAL - fails on some systems, so:
  26. AC_DEFINE(RETSIGTYPE, void, [Type returned from a signal])
  27. # FIXME: really needed?
  28. AC_CHECK_FUNCS(use_default_colors start_color curs_set)
  29. AC_CHECK_FUNCS(getopt_long)
  30. # FIXME: check for libiconv?
  31. # Checks for library functions.
  32. AC_FUNC_FORK
  33. AC_CHECK_FUNCS([dup2 memmove putenv select setlocale strchr strdup strerror strstr strtol wcwidth])
  34. PKG_CHECK_MODULES([FRIBIDI], fribidi,
  35. [CPPFLAGS="$CFLAGS $FRIBIDI_CFLAGS"; LDFLAGS="$LDFLAGS $FRIBIDI_LIBS"])
  36. PKG_CHECK_MODULES([NCURSES], ncursesw,
  37. [CPPFLAGS="$CFLAGS $NCURSES_CFLAGS"; LDFLAGS="$LDFLAGS $NCURSES_LIBS"])
  38. AC_DEFINE(HAVE_WIDE_CURSES, 1, [Have ncursesw (ncurses with wide chars)])
  39. AC_CONFIG_FILES([Makefile])
  40. AC_CONFIG_FILES(pgeresh, [chmod +x pgeresh])
  41. AC_OUTPUT