Mercurial > hg > early-roguelike
annotate rogue4/configure.ac @ 126:b786053d2f37
arogue7: add missing header includes.
author | John "Elwin" Edwards |
---|---|
date | Fri, 08 May 2015 16:45:41 -0400 |
parents | 65f3da34578a |
children | 5238b835d661 |
rev | line source |
---|---|
51 | 1 # -*- Autoconf -*- |
2 # Process this file with autoconf to produce a configure script. | |
3 | |
4 AC_PREREQ(2.56) | |
5 AC_INIT([Rogue],[5.2.2], [yendor@rogueforge.net]) | |
6 AC_CONFIG_SRCDIR([armor.c]) | |
7 AC_CONFIG_HEADERS([config.h]) | |
8 # May not be needed for the documentation | |
9 AC_CONFIG_FILES([Makefile rogue.6 rogue.me]) | |
10 | |
11 # Checks for programs. | |
12 AC_PROG_CC | |
13 # Checks for libraries. | |
14 MP_WITH_CURSES | |
15 # Checks for header files. | |
16 AC_HEADER_STDC | |
122 | 17 AC_CHECK_HEADERS([arpa/inet.h sys/utsname.h pwd.h fcntl.h limits.h nlist.h stdlib.h string.h sys/ioctl.h termios.h unistd.h utmpx.h term.h ncurses/term.h process.h]) |
51 | 18 |
19 # Checks for typedefs, structures, and compiler characteristics. | |
20 AC_TYPE_UID_T | |
21 AC_TYPE_SIZE_T | |
22 AC_STRUCT_TM | |
23 # Checks for library functions. | |
24 AC_FUNC_FORK | |
25 AC_PROG_GCC_TRADITIONAL | |
26 AC_FUNC_LSTAT | |
27 AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK | |
28 AC_TYPE_SIGNAL | |
29 AC_FUNC_STAT | |
30 AC_FUNC_VPRINTF | |
31 AC_CHECK_FUNCS([erasechar killchar alarm getpass memset setenv strchr nlist _spawnl spawnl getpwuid loadav getloadavg strerror setgid setuid getuid getgid]) | |
32 AC_PROG_INSTALL | |
33 | |
34 # Programs to process the documentation | |
35 AC_CHECK_PROG([NROFF], [nroff], [nroff],) | |
36 AC_CHECK_PROG([GROFF], [groff], [groff],) | |
37 AC_CHECK_PROG([COLCRT], [colcrt], [colcrt],) | |
38 AC_CHECK_PROG([TBL], [tbl], [tbl],) | |
39 AC_CHECK_PROG([SED], [sed], [sed],) | |
40 | |
41 AC_ARG_WITH(program-name, AC_HELP_STRING([--with-program-name=NAME],[alternate executable name]),[progname="$withval" ], [progname="rogue4"] ) | |
42 PROGRAM=$progname | |
43 AC_SUBST(PROGRAM) | |
44 | |
45 AC_ARG_ENABLE(setgid, AC_HELP_STRING([--enable-setgid=NAME],[install executable as setgid with group ownership of NAME @<:@default=no@:>@])],[],[]) | |
46 AC_MSG_CHECKING([if using setgid execute bit]) | |
47 if test "x$enable_setgid" = "xno" ; then | |
48 GROUPOWNER= | |
49 elif test "x$enable_setgid" = "xyes" ; then | |
50 GROUPOWNER=games | |
51 elif test "x$enable_setgid" = "x" ; then | |
52 GROUPOWNER= | |
53 else | |
54 GROUPOWNER=$enable_setgid | |
55 fi | |
56 | |
57 if test "x$GROUPOWNER" != "x" ; then | |
58 AC_DEFINE_UNQUOTED([GROUPOWNER],[$GROUPOWNER], [Define to group owner of setgid executable]) | |
59 AC_MSG_RESULT([$GROUPOWNER]) | |
60 else | |
61 AC_MSG_RESULT([no]) | |
62 fi | |
63 | |
64 AC_SUBST(GROUPOWNER) | |
65 | |
66 AC_ARG_ENABLE([scorefile],[AC_HELP_STRING([--enable-scorefile=SCOREFILE], [enable scoreboard with given filename])],[],[]) | |
67 AC_MSG_CHECKING([for scoreboard file]) | |
68 if test "x$enable_scorefile" = "xno" ; then | |
69 SCOREFILE= | |
70 elif test "x$enable_scorefile" = "xyes" ; then | |
71 SCOREFILE=$progname.scr | |
72 elif test "x$enable_scorefile" = "x" ; then | |
73 SCOREFILE=$progname.scr | |
74 else | |
75 SCOREFILE=$enable_scorefile | |
76 fi | |
77 | |
78 if test "x$SCOREFILE" != "x" ; then | |
79 AC_DEFINE_UNQUOTED([SCOREFILE], ["$SCOREFILE"], [Define to file to use for scoreboard]) | |
80 AC_MSG_RESULT([$SCOREFILE]) | |
81 else | |
82 AC_MSG_RESULT([disabled]) | |
83 fi | |
84 | |
85 AC_SUBST(SCOREFILE) | |
86 | |
87 AC_ARG_ENABLE([logfile],[AC_HELP_STRING([--enable-logfile=LOGFILE], [enable logfile with given filename])],[],[]) | |
88 AC_MSG_CHECKING([for log file]) | |
89 if test "x$enable_logfile" = "xno" ; then | |
90 LOGFILE= | |
91 elif test "x$enable_logfile" = "xyes" ; then | |
92 LOGFILE=$progname.log | |
93 elif test "x$enable_logfile" = "x" ; then | |
94 LOGFILE=$progname.log | |
95 else | |
96 LOGFILE=$enable_logfile | |
97 fi | |
98 | |
99 if test "x$LOGFILE" != "x" ; then | |
100 AC_DEFINE_UNQUOTED([LOGFILE], ["$LOGFILE"], [Define to file to use for log]) | |
101 AC_MSG_RESULT([$LOGFILE]) | |
102 else | |
103 AC_MSG_RESULT([disabled]) | |
104 fi | |
105 | |
106 AC_SUBST(LOGFILE) | |
107 | |
108 AC_ARG_ENABLE([lockfile],[AC_HELP_STRING([--enable-lockfile=LOCKFILE], [enable scoreboard lockfile with given filename])],[],[]) | |
109 AC_MSG_CHECKING([for scoreboard lockfile file]) | |
110 if test "x$enable_lockfile" = "xno" ; then | |
a1dc75e38e73
rogue4: ported to autoconf.
elwin |