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 if test "$OSTYPE" = "MSDOS"; then
39 CFLAGS="-I \$(top_srcdir)/arch/dos/include $CFLAGS"
40 AM_CONDITIONAL(ENV_DJGPP, test "$OSTYPE" = "MSDOS")
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
126 if test x$svga = xtrue; then
129 if test x$ggi = xtrue; then
135 AC_PATH_PROG(NASM, nasm, no)
136 CFLAGS="-I \$(top_srcdir)/input/linux/include -I \$(top_srcdir)/arch/linux/include $CFLAGS"
140 # Check for NASM and network
143 AC_ARG_WITH(assembler,
144 [ --without-assembler Do not use assembler optimization ],
145 if test x$withval = xno; then
149 [ --without-network Do not build network/serial support ],
150 if test x$withval = xno; then
154 if test "$NASM" = "no"; then
157 if test "$NO_ASM" = 1; then
166 if test "$OSTYPE" = "MSDOS"; then
169 NASMFLAGS="-f elf -d__ENV_LINUX__ -i\$(srcdir)/"
174 if test "$NO_NETWORK" = 0; then
177 AM_CONDITIONAL(USE_ASM, test "$NO_ASM" != 1)
184 #libdir='$(shell pwd)/${top_srcdir}/main'
191 arch/dos/allg_snd/Makefile
192 arch/dos/allg_snd/sound/Makefile
193 arch/dos/allg_snd/sound/drv/Makefile
194 arch/dos/bak/Makefile
195 arch/dos/comm/Makefile
196 arch/dos/comm/include/Makefile
197 arch/dos/include/Makefile
198 arch/dos/mm_snd/Makefile
199 arch/dos/mm_snd/include/Makefile
200 arch/include/Makefile
202 arch/ogl/include/Makefile
204 arch/linux/include/Makefile
205 arch/linux/svgalib/Makefile
206 arch/linux/svgalib/include/Makefile
209 arch/win32/d3dframe/Makefile
210 arch/win32/include/Makefile
217 input/linux/include/Makefile
229 unused/novga/Makefile
230 unused/pa_null/Makefile
233 unused/vga/new/Makefile
234 unused/win95/Makefile
237 tools/cvs2cl/Makefile