chiark / gitweb /
anag.h: Mark `die' as non-returning and accepting a `printf' format.
[anag] / configure.ac
CommitLineData
0279756e
MW
1dnl -*-autoconf-*-
2dnl
3dnl Configuration script for `anag'
4dnl
5dnl (c) 2016 Mark Wooding
6dnl
7
8dnl----- Licensing notice ---------------------------------------------------
9dnl
10dnl This file is part of Anag: a simple wordgame helper.
11dnl
12dnl Anag is free software; you can redistribute it and/or modify
13dnl it under the terms of the GNU General Public License as published by
14dnl the Free Software Foundation; either version 2 of the License, or
15dnl (at your option) any later version.
16dnl
17dnl Anag is distributed in the hope that it will be useful,
18dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
19dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20dnl GNU General Public License for more details.
21dnl
22dnl You should have received a copy of the GNU General Public License
23dnl along with Anag; if not, write to the Free Software Foundation,
24dnl Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
25
26dnl--------------------------------------------------------------------------
27dnl Initialization.
28
29mdw_AUTO_VERSION
30AC_INIT([anag], AUTO_VERSION, [mdw@distorted.org.uk])
31AC_CONFIG_SRCDIR([anag.c])
32AC_CONFIG_AUX_DIR([config])
33AM_INIT_AUTOMAKE([foreign])
34mdw_SILENT_RULES
35
36AC_PROG_CC
37AX_CFLAGS_WARN_ALL
38
39dnl--------------------------------------------------------------------------
40dnl C programming environment.
41
42AC_CHECK_FUNCS([regcomp])
43
44AC_SEARCH_LIBS([pcre_fullinfo], [pcre],
45 [AC_DEFINE([HAVE_PCRE], [1], [Define if you have libpcre available.])])
46
47dnl--------------------------------------------------------------------------
48dnl Java.
49
50AC_CHECK_PROGS([JAVAC], [javac jikes], [none])
51if test "$JAVAC" = "none"; then AC_MSG_WARN([No Java compiler found]); fi
52AM_CONDITIONAL([HAVE_JAVAC], [test "$JAVAC" != "none"])
53
54dnl--------------------------------------------------------------------------
55dnl Tcl/Tk.
56
57AC_PATH_PROGS([WISH], [wish wish8 wish8.5 wish8.4], [none])
58if test "$WISH" = "none"; then AC_MSG_WARN([No Tcl/Tk interpreter found]); fi
59AM_CONDITIONAL([HAVE_WISH], [test "$WISH" != "none"])
60
61dnl--------------------------------------------------------------------------
62dnl Other configuration.
63
64AC_ARG_WITH(dictionary,
65[ --with-dictionary=DICT set default word list to be DICT],
66[DICTIONARY=$withval],
67[AC_CACHE_CHECK([dictionary], [mdw_cv_dictionary],
68 [for mdw_cv_dictionary in \
69 /usr/share/dict/words \
70 /usr/dict/words; do
71 if test -r "$mdw_cv_dictionary"; then break; fi
72 done])
73 DICTIONARY=$mdw_cv_dictionary])
74
75AC_DEFINE_UNQUOTED([DICTIONARY], ["$DICTIONARY"],
76 [Define this to be your default wordlist location.])
77AC_SUBST([DICTIONARY])
78
79dnl--------------------------------------------------------------------------
80dnl Produce output.
81
82AC_CONFIG_HEADER([config/config.h])
83AC_CONFIG_FILES([Makefile])
84AC_OUTPUT
85
86dnl----- That's all, folks --------------------------------------------------