(release): Copy GTK-DOC manual.
[libtasn1.git] / configure.in
blobf7f54421b59aac92996e0cb31b47b15325134b5c
1 dnl Process this file with autoconf to produce a configure script.
2 AC_PREREQ(2.50)
3 AC_INIT(libtasn1, 0.2.12, bug-gnutls@gnu.org)
4 AM_INIT_AUTOMAKE([1.9 gnits])
5 AM_CONFIG_HEADER(config.h)
7 # Library code modified:                              REVISION++
8 # Interfaces changed/added/removed:   CURRENT++       REVISION=0
9 # Interfaces added:                             AGE++
10 # Interfaces removed:                           AGE=0
11 AC_SUBST(LT_CURRENT, 2)
12 AC_SUBST(LT_REVISION, 12)
13 AC_SUBST(LT_AGE, 0)
15 AC_PROG_CC
16 AC_PROG_YACC
17 AC_PROG_LN_S
19 dnl Checks for programs.
20 AC_PROG_INSTALL
21 AM_MISSING_PROG(PERL,perl,$missing_dir)
23 AC_MSG_RESULT([***
24 *** Detecting compiler options...
26 AC_C_CONST
27 AC_C_INLINE
29 AC_MSG_CHECKING([whether C99 macros are supported])
30 AC_TRY_COMPILE(,[ 
31 #define test_mac(...) 
32 int z,y,x;
33 test_mac(x,y,z);
34 return 0;
35 ], 
36 dnl ***** OK
37 AC_DEFINE(C99_MACROS, 1, [C99 macros are supported])
38 AC_MSG_RESULT(yes),
39 dnl ***** NOT FOUND
40 AC_MSG_RESULT(no)
41 AC_MSG_WARN([C99 macros are not supported by your compiler. This may
42 affect compiling.])
45 if test $ac_cv_c_compiler_gnu != no; then
47         CFLAGS="${CFLAGS} -Wall -Wpointer-arith -Wstrict-prototypes"
49         AC_MSG_CHECKING([whether we have GNU assembler])
50         
51         GAS=`as --version < /dev/null|grep GNU`
52         if test "$GAS"; then
53           CFLAGS="${CFLAGS} -pipe"
54           AC_MSG_RESULT(yes)
55         else
56           AC_MSG_RESULT(no)
57         fi
61 AC_MSG_RESULT([***
62 *** Detecting C library capabilities...
65 AC_HEADER_STDC
66 AC_CHECK_HEADERS(getopt.h unistd.h strings.h inttypes.h stdint.h)
67 AC_CHECK_FUNCS(bzero memset memmove bcopy,,)
68 AC_CHECK_FUNCS(getopt_long)
69 AC_FUNC_ALLOCA
71 AC_MSG_RESULT([***
72 *** Detecting system's parameters...
75 AC_C_BIGENDIAN
77 AC_CHECK_SIZEOF(unsigned long long, 8)
78 AC_CHECK_SIZEOF(unsigned long int, 4)
79 AC_CHECK_SIZEOF(unsigned int, 4)
80 AC_CHECK_SIZEOF(unsigned short int, 2)
81 AC_CHECK_SIZEOF(unsigned char, 1)
83 AC_MSG_RESULT([***
84 *** Detecting options for shared libraries...
86 AM_PROG_LIBTOOL
88 LIBTASN1_LIBS="-L${libdir} -ltasn1 $LIBS"
89 LIBTASN1_CFLAGS="-I${includedir}"
91 AC_SUBST(LIBTASN1_LIBS)
92 AC_SUBST(LIBTASN1_CFLAGS)
94 AC_CONFIG_COMMANDS([lib/libtasn1.h],[[
95  chmod +x lib/libtasn1-config
96 ]],[[]])
98 # Check for gtk-doc.
99 GTK_DOC_CHECK(1.2)
101 AC_CONFIG_FILES([Makefile src/Makefile tests/Makefile lib/Makefile \
102         lib/libtasn1-config doc/Makefile doc/reference/Makefile])
103 AC_OUTPUT