Czech translation
[shigofumi.git] / configure.ac
blob0ecc338e7aff46fd6da8e6388478c2ec2f9a8e34
1 #                                               -*- Autoconf -*-
2 # Process this file with autoconf to produce a configure script.
4 AC_PREREQ([2.63])
5 AC_INIT([shigofumi], [0.1], [petr.pisar@atlas.cz])
6 AM_INIT_AUTOMAKE(shigofumi, 0.1)
7 AC_CONFIG_SRCDIR([src/shigofumi.c])
8 AC_CONFIG_MACRO_DIR([m4])
9 AC_CONFIG_HEADERS([src/config.h])
11 # Checks for programs.
12 AC_PROG_CC
13 AC_PROG_CPP
16 # Enable debug
17 AC_ARG_ENABLE(debug, [AS_HELP_STRING([--enable-debug],
18                         [Compile in debugging mode])])
19 AS_IF([test "$enable_debug" = "yes"],
20       CFLAGS="${CFLAGS} -g"
21       dnl AC_SUBST(DEBUG_CFLAGS)
22       AC_DEFINE([ENABLE_DEBUG], [1],
23                 [Define if you want include debugging code])
24       )
26 # Enable gettext
27 AM_GNU_GETTEXT_VERSION([0.17])
28 AM_GNU_GETTEXT([external])
30 # Checks for libraries.
31 # Check for libisds
32 AC_SYS_LARGEFILE
33 PKG_CHECK_MODULES([ISDS], libisds >= 0.2.1)
35 # Check for confuse
36 # TODO: Minimal version
37 PKG_CHECK_MODULES([CONFUSE], libconfuse)
39 # Check for magic
40 # TODO: Minimal version
41 AC_CHECK_LIB([magic], [magic_open])
43 # Check for readline
44 # TODO: Minimal version
45 AC_CHECK_LIB([readline], [readline])
48 # Checks for header files.
49 AC_CHECK_HEADERS([fcntl.h langinfo.h limits.h locale.h stdint.h stdlib.h string.h termios.h unistd.h wchar.h])
51 # Checks for typedefs, structures, and compiler characteristics.
52 AC_TYPE_SIZE_T
53 AC_TYPE_SSIZE_T
54 AC_TYPE_UINT8_T
56 # Checks for library functions.
57 AC_FUNC_MALLOC
58 AC_FUNC_MBRTOWC
59 AC_FUNC_MMAP
60 AC_FUNC_REALLOC
61 AC_FUNC_STRCOLL
62 AC_CHECK_FUNCS([getcwd localtime_r memset munmap nl_langinfo setenv setlocale strdup strerror strtol tzset wcwidth])
64 # Default CFLAGS
65 CFLAGS="${CFLAGS} -std=c99 -Wall"
67 AC_CONFIG_FILES([Makefile po/Makefile.in src/Makefile])
68 AC_OUTPUT