1 | dnl Process this file with autoconf to produce a configure script. |
1 | dnl Process this file with autoconf to produce a configure script. |
2 | |
2 | |
3 | AC_INIT([crossfire], [2.0+], [crossfire@schmorp.de]) |
3 | AC_INIT([cfserver], [2.0], [crossfire@schmorp.de]) |
4 | AC_CONFIG_AUX_DIR(utils) |
4 | AC_CONFIG_AUX_DIR(utils) |
5 | AC_CONFIG_SRCDIR([server/main.C]) |
5 | AC_CONFIG_SRCDIR([server/cfperl.xs]) |
6 | AM_INIT_AUTOMAKE |
6 | AM_INIT_AUTOMAKE |
7 | AM_CONFIG_HEADER(include/autoconf.h) |
7 | AM_CONFIG_HEADER(include/autoconf.h) |
8 | |
8 | |
9 | AM_MAINTAINER_MODE |
9 | AM_MAINTAINER_MODE |
10 | |
10 | |
… | |
… | |
13 | dnl Checks for programs. |
13 | dnl Checks for programs. |
14 | AC_LANG(C++) |
14 | AC_LANG(C++) |
15 | AC_PROG_CXX |
15 | AC_PROG_CXX |
16 | AC_PROG_LIBTOOL |
16 | AC_PROG_LIBTOOL |
17 | |
17 | |
18 | case "$target" in |
|
|
19 | alpha-dec-osf*) |
|
|
20 | # If we are not using gcc, we want the ansi version of cc. |
|
|
21 | if test -z "$GCC"; then |
|
|
22 | # CFLAGS="$CFLAGS -std1 -warnprotos" # Not yet ready for warnprotos... |
|
|
23 | CFLAGS="$CFLAGS -std1" |
|
|
24 | fi |
|
|
25 | ;; |
|
|
26 | *) |
|
|
27 | ;; |
|
|
28 | esac |
|
|
29 | |
|
|
30 | AC_PROG_CPP |
18 | AC_PROG_CPP |
31 | |
19 | |
|
|
20 | AC_PATH_PROG(CONVERT, convert) |
|
|
21 | |
|
|
22 | if test -z "$CONVERT"; then |
|
|
23 | AC_MSG_ERROR([ImageMagick 'convert' must be in your PATH, see the README]) |
|
|
24 | fi |
|
|
25 | |
32 | AC_PATH_PROG(PERL, perl5.8) |
26 | AC_PATH_PROG(PERL, perl5.8) |
|
|
27 | if test -z "$PERL"; then |
33 | AC_PATH_PROG(PERL, perl5) |
28 | AC_PATH_PROG(PERL, perl5) |
|
|
29 | if test -z "$PERL"; then |
34 | AC_PATH_PROG(PERL, perl) |
30 | AC_PATH_PROG(PERL, perl) |
|
|
31 | fi |
|
|
32 | fi |
35 | |
33 | |
36 | for module_vers in "Coro 3.5" "Coro::Event 2.1" "Event 1.08" \ |
34 | for module_vers in "Crossfire 0.97" "Coro 3.5" "Coro::Event 2.1" "Event 1.08" \ |
37 | "IO::AIO 2.32" "BDB 0.1" "Storable 2.0" "Time::HiRes 1.0" "YAML::Syck 0.71" \ |
35 | "IO::AIO 2.32" "BDB 0.1" "Storable 2.0" "Time::HiRes 1.0" "YAML::Syck 0.71" \ |
38 | "Digest::MD5 2.0" "Compress::LZF 1.7" "Safe::Hole 0.10" "Pod::POM 0.17"; do |
36 | "Digest::MD5 2.0" "Compress::LZF 1.71" "Safe::Hole 0.10" "Pod::POM 0.17"; do |
39 | set -- $module_vers |
37 | set -- $module_vers |
40 | module=$1 |
38 | module=$1 |
41 | minvers=$2 |
39 | minvers=$2 |
42 | AC_MSG_CHECKING(for $module perl module version $minvers or higher) |
40 | AC_MSG_CHECKING(for $module perl module version $minvers or higher) |
43 | if $PERL -M$module -e0 >/dev/null 2>&1; then |
41 | if $PERL -M$module -e0 >/dev/null 2>&1; then |
… | |
… | |
128 | AC_MSG_RESULT(ok) |
126 | AC_MSG_RESULT(ok) |
129 | else |
127 | else |
130 | AC_MSG_ERROR(no) |
128 | AC_MSG_ERROR(no) |
131 | fi |
129 | fi |
132 | |
130 | |
133 | AC_SUBST(x_includes) |
|
|
134 | AC_SUBST(x_libraries) |
|
|
135 | AC_SUBST(no_x) |
|
|
136 | AM_CONDITIONAL(HAVE_X,test "x$no_x" = "x") |
|
|
137 | AC_SUBST(X11LIBS) |
|
|
138 | |
|
|
139 | AC_SUBST(pkgstatedir,$localstatedir/$PACKAGE) |
131 | AC_SUBST(pkgstatedir,$localstatedir/$PACKAGE) |
140 | AC_SUBST(pkgconfdir,$sysconfdir/$PACKAGE) |
132 | AC_SUBST(pkgconfdir,$sysconfdir/$PACKAGE) |
141 | |
133 | |
142 | AC_OUTPUT([Makefile |
134 | AC_OUTPUT([Makefile |
143 | include/Makefile lib/Makefile pod/Makefile random_maps/Makefile socket/Makefile |
135 | include/Makefile lib/Makefile pod/Makefile random_maps/Makefile socket/Makefile |
144 | server/Makefile src/Makefile utils/Makefile ext/Makefile |
136 | server/Makefile utils/Makefile ext/Makefile doc/Makefile |
145 | lib/checkarch.pl lib/collect.pl utils/add_throw.perl |
137 | lib/checkarch.pl lib/collect.pl common/Makefile |
146 | utils/crossloop.tmpl utils/crossloop.pl.tmpl utils/metaserver.pl |
|
|
147 | utils/crossloop.web utils/scores.pl utils/player_dl.pl common/Makefile |
|
|
148 | ]) |
138 | ]) |
149 | |
139 | |