configure.ac 2.08 KB
Newer Older
pouill_n's avatar
pouill_n committed
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
# Configure template for sdf-astgen                     -*-Autoconf-*-
#
# Copyright (C) 2003, 2004  EPITA Research and Development Laboratory.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
# 02111-1307  USA

AC_PREREQ(2.57)

AC_INIT([sdf-astgen], 0.1, [transformers@lrde.epita.fr])

# Auxiliary files
AC_CONFIG_AUX_DIR([config])
AC_CONFIG_FILES(config/Makefile)

AM_INIT_AUTOMAKE([1.8.3 dist-bzip2])

# Make sure $prefix is defined.
test "x$prefix" = xNONE && prefix=$ac_default_prefix

USE_XT_PACKAGES

test -f $STRC/bin/strc ||
  AC_MSG_ERROR([cannot find strc.  Use --with-strategoxt.])

test -f $PGEN/bin/sdf2table ||
  AC_MSG_ERROR([cannot find sdf2table.  Use --with-sdf.])

BUNDLE_INIT

AC_ARG_WITH([lrde-sdftools],
  [  --with-lrde-sdftools=DIR Specify location of LRDE_SDF, [PREFIX]],
  [LRDE_SDF=$withval],
  [LRDE_SDF=$prefix]
)
AC_SUBST([LRDE_SDF])
DEF_BUNDLED_PKG([LRDE_SDF])

AC_CHECK_PROGS([HELP2MAN], [help2man], [NONE])
if test x"$HELP2MAN" = xNONE; then
53
54
  AC_MSG_WARN([cannot find help2man. This isn't mandatory. You will
               only not be able to generate manpages.])  
pouill_n's avatar
pouill_n committed
55
fi
56
AM_CONDITIONAL([HAVE_HELP2MAN], [test x"$HELP2MAN" != xNONE])
pouill_n's avatar
pouill_n committed
57
58
59
60
61
62
63
64
65
66
AC_SUBST([HELP2MAN])

# Look for common programs
AC_LANG_C
AC_PROG_CC
AC_PROG_INSTALL

# Output Files
AC_CONFIG_FILES([Makefile
		 config/version.str
67
68
		 lib/Makefile
		 lib/sdf-pgen/Makefile
pouill_n's avatar
pouill_n committed
69
70
71
72
73
74
75
76
77
		 src/Makefile
		 src/syn/Makefile
		 src/sig/Makefile
		 src/pp/Makefile
		 src/parser/Makefile
		 src/sdf-astgen/Makefile
		])
AC_OUTPUT