Mercurial > hg > early-roguelike
annotate srogue/configure.ac @ 210:c4f2e1bda8b0
arogue5: fix a typo that broke compilation with GCC 5.
"msg" had been used instead of "msgw". I'm not sure why neither GCC 4
nor MSVC caught this.
author | John "Elwin" Edwards |
---|---|
date | Sun, 17 Jan 2016 18:59:50 -0500 |
parents | 5238b835d661 |
children | 0e99eade579c |
rev | line source |
---|---|
101 | 1 # -*- Autoconf -*- |
2 # Process this file with autoconf to produce a configure script. | |
3 | |
4 AC_PREREQ(2.56) | |
5 AC_INIT([SRogue],[9.0], [yendor@rogueforge.net]) | |
6 AC_CONFIG_HEADERS([config.h]) | |
7 AC_CONFIG_FILES([Makefile]) | |
8 | |
9 # Checks for programs. | |
10 AC_PROG_CC | |
11 # Checks for libraries. | |
12 MP_WITH_CURSES | |
13 # Checks for header files. | |
14 AC_HEADER_STDC | |
118 | 15 AC_CHECK_HEADERS([arpa/inet.h pwd.h errno.h fcntl.h limits.h nlist.h stdlib.h string.h sys/ioctl.h termios.h unistd.h term.h ncurses/term.h process.h]) |
101 | 16 |
17 # Checks for typedefs, structures, and compiler characteristics. | |
119 | 18 AC_TYPE_UID_T |
101 | 19 AC_TYPE_SIZE_T |
20 AC_STRUCT_TM | |
21 # Checks for library functions. | |
22 AC_FUNC_FORK | |
23 AC_PROG_GCC_TRADITIONAL | |
24 AC_TYPE_SIGNAL | |
25 AC_FUNC_STAT | |
26 AC_FUNC_VPRINTF | |
121
e6c8652473fe
srogue: more compatibility improvements.
John "Elwin" Edwards
parents:
119
diff
changeset
|
27 AC_CHECK_FUNCS([erasechar killchar alarm getpass memset setenv strchr nlist _spawnl spawnl getpwuid loadav getloadavg strerror setgid setuid getuid getgid lrand48 random srand48 srandom]) |
101 | 28 AC_PROG_INSTALL |
29 | |
30 AC_ARG_WITH(program-name, AC_HELP_STRING([--with-program-name=NAME],[alternate executable name]),[progname="$withval" ], [progname="srogue"] ) | |
31 PROGRAM=$progname | |
32 AC_SUBST(PROGRAM) | |
33 | |
34 AC_ARG_ENABLE(setgid, AC_HELP_STRING([--enable-setgid=NAME],[install executable as setgid with group ownership of NAME @<:@default=no@:>@])],[],[]) | |
35 AC_MSG_CHECKING([if using setgid execute bit]) | |
36 if test "x$enable_setgid" = "xno" ; then | |
37 GROUPOWNER= | |
38 elif test "x$enable_setgid" = "xyes" ; then | |
39 GROUPOWNER=games | |
40 elif test "x$enable_setgid" = "x" ; then | |
41 GROUPOWNER= | |
42 else | |
43 GROUPOWNER=$enable_setgid | |
44 fi | |
45 | |
46 if test "x$GROUPOWNER" != "x" ; then | |
47 AC_DEFINE_UNQUOTED([GROUPOWNER],[$GROUPOWNER], [Define to group owner of setgid executable]) | |
48 AC_MSG_RESULT([$GROUPOWNER]) | |
49 else | |
50 AC_MSG_RESULT([no]) | |
51 fi | |
52 | |
53 AC_SUBST(GROUPOWNER) | |
54 | |
55 AC_ARG_ENABLE([scorefile],[AC_HELP_STRING([--enable-scorefile=SCOREFILE], [enable scoreboard with given filename])],[],[]) | |
56 AC_MSG_CHECKING([for scoreboard file]) | |
57 if test "x$enable_scorefile" = "xno" ; then | |
58 SCOREFILE= | |
59 elif test "x$enable_scorefile" = "xyes" ; then | |
60 SCOREFILE=$progname.scr | |
61 elif test "x$enable_scorefile" = "x" ; then | |
62 SCOREFILE=$progname.scr | |
63 else | |
64 SCOREFILE=$enable_scorefile | |
65 fi | |
66 | |
67 if test "x$SCOREFILE" != "x" ; then | |
68 AC_DEFINE_UNQUOTED([SCOREFILE], ["$SCOREFILE"], [Define to file to use for scoreboard]) | |
69 AC_MSG_RESULT([$SCOREFILE]) | |
70 else | |
71 AC_MSG_RESULT([disabled]) | |
72 fi | |
73 | |
74 AC_SUBST(SCOREFILE) | |
75 | |
76 AC_ARG_ENABLE([logfile],[AC_HELP_STRING([--enable-logfile=LOGFILE], [enable logfile with given filename])],[],[]) | |
77 AC_MSG_CHECKING([for log file]) | |
78 if test "x$enable_logfile" = "xno" ; then | |
79 LOGFILE= | |
80 elif test "x$enable_logfile" = "xyes" ; then | |
81 LOGFILE=$progname.log | |
82 elif test "x$enable_logfile" = "x" ; then | |
83 LOGFILE=$progname.log | |
84 else | |
85 LOGFILE=$enable_logfile | |
86 fi | |
87 | |
88 if test "x$LOGFILE" != "x" ; then | |
89 AC_DEFINE_UNQUOTED([LOGFILE], ["$LOGFILE"], [Define to file to use for log]) | |
90 AC_MSG_RESULT([$LOGFILE]) | |
91 else | |
92 AC_MSG_RESULT([disabled]) | |
93 fi | |
94 | |