-
Notifications
You must be signed in to change notification settings - Fork 14
/
configure.ac
83 lines (67 loc) · 1.61 KB
/
configure.ac
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
AC_INIT([SDL Sopwith], [2.7.0], [[email protected]], [sdl-sopwith])
AC_CONFIG_AUX_DIR(autotools)
VERSION=$CONFIG_VERSION
PACKAGE_COPYRIGHT="Copyright (C) 1984-2024"
PACKAGE_LICENSE="GNU General Public License, version 2"
AC_SUBST(VERSION)
AC_SUBST(PACKAGE_COPYRIGHT)
AC_SUBST(PACKAGE_LICENSE)
AC_CANONICAL_TARGET
AC_SEARCH_LIBS([sin], [m])
AC_CANONICAL_HOST
AC_CANONICAL_TARGET
AM_INIT_AUTOMAKE([1.8.0 foreign])
AC_PROG_CC
AC_PROG_RANLIB
AC_CHECK_TOOL(STRIP, strip, )
AC_CHECK_TOOL(CONVERT, convert, )
AC_CHECK_HEADERS(stdbool.h)
AC_CHECK_FUNCS(isatty)
if test "$GCC" = "yes"; then
WARNINGS="-Wall -Wdeclaration-after-statement -Wredundant-decls"
CFLAGS="-O2 -g $WARNINGS $CFLAGS"
fi
dnl network libraries; not all systems have the sockets API in their libc:
SOCKET_LIBS=
case "$target" in
*-*-cygwin* | *-*-mingw32*)
SOCKET_LIBS="-lwsock32"
;;
sparc*-*-solaris*)
SOCKET_LIBS="-lsocket -lnsl"
;;
*-*-qnx*)
SOCKET_LIBS="-lsocket"
;;
*haiku*)
SOCKET_LIBS="-lnetwork"
;;
esac
AC_SUBST(SOCKET_LIBS)
case "$host" in
*cygwin* | *mingw* )
AC_CHECK_TOOL(WINDRES, windres, )
;;
*)
WINDRES=
;;
esac
AM_CONDITIONAL(HAVE_WINDRES, test "$WINDRES" != "")
AM_CONDITIONAL(HAVE_CONVERT, test "$CONVERT" != "")
AC_CONFIG_HEADERS([config.h:config.hin])
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
AC_PROG_INSTALL
PKG_CHECK_MODULES(SDL, [sdl2 >= 2.0.7])
AC_CHECK_HEADERS(netinet/in.h winsock.h)
AC_SUBST(ac_aux_dir)
AC_CONFIG_FILES([
Makefile
doc/Makefile
pkg/config.make
pkg/macos/Info.plist
pkg/Makefile
src/Makefile
src/resource.rc
src/sdl/Makefile
])
AC_OUTPUT