-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfigure.in
73 lines (62 loc) · 1.97 KB
/
configure.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
dnl Process this file with autoconf to produce a configure script.
AC_INIT(lib/rtl/dibol.h)
D2C_VERSION=0.0.4
AM_CONFIG_HEADER(config.h)
AM_INIT_AUTOMAKE(d2c, $D2C_VERSION)
dnl To get the stable versions of automake, autoconf and libtool under cygwin
AC_PREREQ(2.13)
dnl Checks for programs.
AC_PROG_CC
AC_PROG_CPP
AC_PROG_INSTALL
AC_PROG_MAKE_SET
AC_PROG_YACC
AC_PROG_LEX
AM_PROG_LEX
AC_PROG_LIBTOOL
AC_PROG_LN_S
AC_PROG_RANLIB
AC_PATH_PROG(BISON_PROG, bison)
AC_PATH_PROG(YACC_PROG, yacc)
dnl Checks for libraries.
dnl Checks for glib
AC_CHECK_PROG(GLIB_CONFIG, glib-config, yes, no)
if test "$GLIB_CONFIG" = "no"; then
echo ;
echo "Error: Cannot find glib-config. Do you have glib installed ? You can\ download it" ;
echo "from ftp://ftp.gtk.org/pub/gtk/v1.2" ;
echo ;
exit
else
GLIB_LIBS=`glib-config --libs`
GLIB_CFLAGS=`glib-config --cflags`
GLIB_VERSION=`glib-config --version`
LIBS="$LIBS $GLIB_LIBS"
CFLAGS="$CFLAGS $GLIB_CFLAGS"
fi
dnl Make sure we are using glib 1.2.x or higher
AC_MSG_CHECKING(version of glib...)
glib_maj_rev=`echo $GLIB_VERSION | cut -f1-2 -d.`
if test "$glib_maj_rev" = "1.2" ; then
AC_MSG_RESULT(($GTK_VERSION))
else
echo ;
echo "Error: You need glib 1.2.x or higher to install d2c. You can download it from" ;
echo "ftp://ftp.gtk.org/pub/gtk/v1.2 " ;
echo ;
exit
fi
dnl Checks for header files.
AC_HEADER_STDC
AC_HEADER_STDBOOL
AC_CHECK_HEADERS(fcntl.h limits.h malloc.h sys/time.h syslog.h termio.h unistd.h termios.h stddef.h sys/param.h sys/socket.h)
dnl Checks for typedefs, structures, and compiler characteristics.
AC_TYPE_SIZE_T
AC_HEADER_TIME
dnl Checks for library functions.
AC_FUNC_MEMCMP
AC_FUNC_STRFTIME
AC_FUNC_MALLOC
AC_FUNC_REALLOC
AC_CHECK_FUNCS(mkdir select socket strdup strstr strtol atexit memmove memset realpath strcasecmp strchr)
AC_OUTPUT(Makefile lib/Makefile lib/common/Makefile lib/rtl/Makefile lib/ues/Makefile src/Makefile src/dpp/Makefile src/dc/Makefile src/d2c/Makefile testsuite/Makefile dibol-config, chmod +x dibol-config)