Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Adapt to lastest changes in dict: Create dicts before use
[simgrid.git] / configure.ac
1 AC_PREREQ(2.57)
2
3 #We need a recent ACI
4 ACI_PREREQ(2003.01.16)
5
6 AC_INIT([GRAS],[0.0.040129],[martin.quinson@ens-lyon.fr])
7 AC_CONFIG_SRCDIR([src/include/gras.h])
8 AC_REVISION($Revision$)
9 AC_CONFIG_SUBDIRS(src/nws_portability)
10
11 AC_CANONICAL_TARGET
12 AC_LANG([C])
13
14 AM_CONFIG_HEADER(src/gras_config.h)
15 AM_INIT_AUTOMAKE
16
17 AM_PROG_LIBTOOL
18 GNOME_GTKDOC_CHECK
19
20 # declare the modules (no optional module)
21
22 dnl
23 dnl Load anything under acmacro/*.m4
24 dnl
25 test -n "$ACLOCAL_FLAGS" && ACLOCAL="$ACLOCAL $ACLOCAL_FLAGS"
26 ACLOCAL="$ACLOCAL -I acmacro"
27
28
29 AC_PROG_CC
30 AC_PROG_F77
31 AC_F77_LIBRARY_LDFLAGS
32 AM_SANITY_CHECK
33 AC_PROG_MAKE_SET
34
35 # Checks for header files.
36 AC_HEADER_STDC
37 AC_CHECK_HEADERS([stddef.h stdlib.h string.h unistd.h])
38
39 # Checks for typedefs, structures, and compiler characteristics.
40 AC_C_CONST
41 AC_C_INLINE
42 AC_TYPE_SIZE_T
43
44 # Checks for library functions.
45 AC_FUNC_MALLOC
46 AC_FUNC_MEMCMP
47 AC_CHECK_FUNCS([memset strchr strerror])
48
49 dnl ####[ Search libs ]#######################################################
50 ACI_PACKAGE_SAVED(XML,[XML library (version XML2)],xml2-config,,,:)
51 ACI_PACKAGE([SimGrid],[the SimGrid simulator],[SG_init],[-lsimgrid],[simgrid.h])
52
53 dnl A C_CHECK_LIB(pthread, pthread_mutex_lock)
54         
55 dnl ####[ maint mode ]#######################################################
56 AM_MAINTAINER_MODE
57 if test x$USE_MAINTAINER_MODE = xyes 
58 then
59    GNOME_COMPILE_WARNINGS(yes)
60 fi
61
62 AC_SUBST(CFLAGS)
63 AC_SUBST(CPPFLAGS)
64 AC_SUBST(LDFLAGS)
65
66 dnl ####[ check for some programms ]###########################################
67 AC_CHECK_PROG(BASH, bash, `which bash`, /bin/sh)
68 WARNING="This file is generated, do not edit"
69 AC_SUBST(WARNING)
70
71 dnl ####[ Makes the output ]###################################################
72 AC_CONFIG_FILES([
73   Makefile
74   src/Makefile
75     src/include/Makefile
76       src/include/modules/Makefile
77     src/base/Makefile
78       src/base/Tests/Makefile
79       src/base/Tests/gs_example
80       src/base/Tests/run_tests
81     src/modules/Makefile
82     src/examples/Makefile 
83       src/examples/ping/Makefile 
84       src/examples/bandwidth/Makefile src/examples/saturate/Makefile
85       src/examples/alnem/Makefile 
86   doc/Makefile
87 ],[( cd src/include ; test -e gras || ln -s . gras )
88      test -e src/base/Tests/gs_example && chmod +x src/base/Tests/gs_example;
89      test -e src/base/Tests/run_tests && chmod +x src/base/Tests/run_tests])
90
91 AC_OUTPUT
92
93 echo "
94
95 Configuration of package \`${PACKAGE}':
96
97         Compiler:       ${CC}
98
99         CFlags:         ${CFLAGS}
100         LDFlags:        ${LDFLAGS}
101 "
102
103 exit 0;