1 AC_INIT(main/inferno.c)
3 AM_CONFIG_HEADER(conf.h)
4 AM_INIT_AUTOMAKE(d2x, 0.0.9)
18 dnl Count warnings as errors?
20 [ --enable-werror Count compiler warning as errors ],
21 [case "${enableval}" in
22 yes) CFLAGS="-Werror $CFLAGS" ;;
24 *) AC_MSG_ERROR(bad value ${enableval} for --enable-werror) ;;
27 dnl Build with NDEBUG?
29 [ --enable-ndebug Take out extra Asserts, Int3, etc ],
30 [case "${enableval}" in
31 yes) AC_DEFINE(NDEBUG) ;;
33 *) AC_MSG_ERROR(bad value ${withval} for --enable-ndebug) ;;
37 AM_CONDITIONAL(ENV_DJGPP, test "$OSTYPE" = "MSDOS")
38 if test "$OSTYPE" = "MSDOS"; then
40 CFLAGS="-I \$(top_srcdir)/arch/dos/include $CFLAGS"
41 AC_DEFINE(__ENV_DJGPP__)
42 AC_PATH_PROG(NASM, nasmw, no)
46 CFLAGS="-D_REENTRANT -pipe $CFLAGS"
47 AM_CONDITIONAL(ENV_LINUX, test "$OSTYPE" != "MSDOS")
48 AC_DEFINE(__ENV_LINUX__)
51 AC_CHECK_LIB(SDL, SDL_Init, SDL_LIBS="-lSDL", AC_MSG_ERROR(The SDL which is required not found.),-ldl -lpthread)
52 AC_CHECK_HEADERS(netipx/ipx.h)
57 [ --with-opengl Build OpenGL support ],
61 *) AC_MSG_ERROR(bad value ${withval} for --with-opengl) ;;
64 if test x$opengl = xtrue; then
65 AC_CHECK_LIB(GL, main,
67 [AC_MSG_ERROR([GL not found, OpenGL cannot be built])
70 AC_CHECK_LIB(GLU,main,
71 OGL_LIBS="${OGL_LIBS} -lGLU",
72 [AC_MSG_ERROR([GLU not found, OpenGL cannot be built])
77 AM_CONDITIONAL(USE_OPENGL, test x$opengl = xtrue)
81 [ --with-ggi Build GGI support ],
85 *) AC_MSG_ERROR(bad value ${withval} for --with-ggi) ;;
88 if test x$ggi = xtrue; then
89 AC_CHECK_LIB(ggi, ggiInit,
91 [AC_MSG_ERROR([GGI not found, GGI version cannot be built]); ggi=false])
92 AC_CHECK_LIB(gii, giiInit,
93 GGI_LIBS="${GGI_LIBS} -lgii",
94 [AC_MSG_ERROR([GII not found, GGI version cannot be built]); ggi=false])
97 AM_CONDITIONAL(USE_GGI, test x$ggi = xtrue)
101 [ --with-svga Build SVGALib support ],
102 [case "${withval}" in
105 *) AC_MSG_ERROR(bad value ${withval} for --with-svga) ;;
108 if test x$svga = xtrue; then
109 AC_CHECK_LIB(vga, vga_getmousetype,
111 [AC_MSG_ERROR([vga not found, SVGALib cannot be built])
114 AC_CHECK_LIB(vgagl,gl_getcontext,
115 SVGA_LIBS="${SVGA_LIBS} -lvgagl",
116 [AC_MSG_ERROR([vgagl not found, SVGALib cannot be built])
121 AM_CONDITIONAL(USE_SVGALIB, test x$svga = xtrue)
123 if test x$opengl = xtrue; then
127 if test x$svga = xtrue; then
131 if test x$ggi = xtrue; then
140 AC_PATH_PROG(NASM, nasm, no)
141 CFLAGS="-I\$(top_srcdir)/input/linux/include -I\$(top_srcdir)/arch/linux/include $CFLAGS"
145 # Check for NASM and network
148 AC_ARG_WITH(assembler,
149 [ --without-assembler Do not use assembler optimization ],
150 if test x$withval = xno; then
154 [ --without-network Do not build network/serial support ],
155 if test x$withval = xno; then
159 if test "$NASM" = "no"; then
162 if test "$NO_ASM" = 1; then
171 if test "$OSTYPE" = "MSDOS"; then
174 NASMFLAGS="-f elf -d__ENV_LINUX__ -i\$(srcdir)/"
179 if test "$NO_NETWORK" = 0; then
182 AM_CONDITIONAL(USE_ASM, test "$NO_ASM" != 1)
183 AM_CONDITIONAL(USE_NETWORK, test "$NO_NETWORK" != 1)
193 #libdir='$(shell pwd)/${top_srcdir}/main'
200 arch/dos/allg_snd/Makefile
201 arch/dos/allg_snd/sound/Makefile
202 arch/dos/allg_snd/sound/drv/Makefile
203 arch/dos/bak/Makefile
204 arch/dos/comm/Makefile
205 arch/dos/comm/include/Makefile
206 arch/dos/include/Makefile
207 arch/dos/mm_snd/Makefile
208 arch/dos/mm_snd/include/Makefile
209 arch/include/Makefile
211 arch/ogl/include/Makefile
213 arch/linux/include/Makefile
216 arch/win32/d3dframe/Makefile
217 arch/win32/include/Makefile
224 input/linux/include/Makefile
236 unused/novga/Makefile
237 unused/pa_null/Makefile
240 unused/vga/new/Makefile
241 unused/win95/Makefile
244 tools/cvs2cl/Makefile