comparison configure.ac @ 48:67e88056ad4f

c core can now be disabled, and has proper defaults.
author Robert McIntyre <rlm@mit.edu>
date Thu, 21 Mar 2013 19:38:57 +0000
parents 3907aac7df1c
children 9c1b4651b731
comparison
equal deleted inserted replaced
47:3907aac7df1c 48:67e88056ad4f
2 2
3 AC_INIT([VBA-ReRecording], [1.7.2], [], [vba-rerecording], 3 AC_INIT([VBA-ReRecording], [1.7.2], [], [vba-rerecording],
4 [http://code.google.com/p/vba-rerecording/]) 4 [http://code.google.com/p/vba-rerecording/])
5 5
6 AC_CONFIG_AUX_DIR([build-aux]) 6 AC_CONFIG_AUX_DIR([build-aux])
7
8 AC_CANONICAL_TARGET
7 9
8 AM_INIT_AUTOMAKE([foreign dist-bzip2]) 10 AM_INIT_AUTOMAKE([foreign dist-bzip2])
9 11
10 AC_CONFIG_SRCDIR([src/gb/GB.cpp]) 12 AC_CONFIG_SRCDIR([src/gb/GB.cpp])
11 13
12 AC_CONFIG_HEADERS([config.h]) 14 AC_CONFIG_HEADERS([config.h])
13 15
14 16
15 #AC_CANONICAL_TARGET 17 AS_CASE([$target],
18 [i?86-*-*], [VBA_USE_C_CORE=no]
19 [*] , [VBA_USE_C_CORE=yes])
16 20
17 dnl AS_CASE([$target], 21 AC_ARG_ENABLE(c-core,
18 dnl [i?86-*-*], [VBA_USE_C_CORE=no; VBA_USE_MMX=yes] 22 AC_HELP_STRING([--enable-c-core],[enable C core (default is no on x86 targets)]),
19 dnl [*] , [VBA_USE_C_CORE=yes; VBA_USE_MMX=no]) 23 [VBA_USE_C_CORE=$enableval])
24
25 AS_CASE([$VBA_USE_C_CORE],
26 [yes], [AM_CXXFLAGS="$AM_CXXFLAGS -DC_CORE"],
27 [no], [])
20 28
21 # Checks for programs. 29 # Checks for programs.
22 AC_PROG_CXX 30 AC_PROG_CXX
23 AC_PROG_CC 31 AC_PROG_CC
24 AC_PROG_AWK 32 AC_PROG_AWK
25 AC_PROG_INSTALL 33 AC_PROG_INSTALL
26 AC_PROG_RANLIB 34 AC_PROG_RANLIB
27 AC_PROG_CPP 35 AC_PROG_CPP
28 AC_PROG_MKDIR_P 36 AC_PROG_MKDIR_P
29 AC_PATH_PROG(NASM, nasm) 37 AC_PATH_PROG(NASM, nasm)
38
30 39
31 # Checks for libraries. 40 # Checks for libraries.
32 AC_CHECK_LIB(z, gzopen, 41 AC_CHECK_LIB(z, gzopen,
33 , AC_MSG_ERROR([*** Cannot compile without zlib.])) 42 , AC_MSG_ERROR([*** Cannot compile without zlib.]))
34 43
86 src/SFMT/Makefile 95 src/SFMT/Makefile
87 src/filters/Makefile 96 src/filters/Makefile
88 src/prof/Makefile 97 src/prof/Makefile
89 src/sdl/Makefile]) 98 src/sdl/Makefile])
90 99
91 ### RLM: investigate this further 100 AC_SUBST([AM_CXXFLAGS])
92 AC_SUBST([AM_CXXFLAGS], [-DC_CORE])
93 #AC_SUBST([AM_CXXFLAGS], [-fno-exceptions])
94 #CXXFLAGS="$CXXFLAGS -DC_CORE"
95
96 echo "**************************"
97 echo $CXXFLAGS
98 101
99 AC_OUTPUT 102 AC_OUTPUT
103
104
105 echo "******** RLM ****************"
106 echo "target= $target"
107 echo "VBA_USE_C_CORE= $VBA_USE_C_CORE"
108 echo "VBA_USE_MMX= $VBA_USE_MMX"
109 echo "AM_CXXFLAGS= $AM_CXXFLAGS"
110 echo "enable_c_core= $enable_c_core"