Mercurial > vba-linux
changeset 49:9c1b4651b731
enabled optional profiling.
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Thu, 21 Mar 2013 20:35:16 +0000 |
parents | 67e88056ad4f |
children | 690c44762f6f |
files | configure.ac src/Makefile.am src/gba/Makefile.am src/sdl/Makefile.am |
diffstat | 4 files changed, 20 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
1.1 --- a/configure.ac Thu Mar 21 19:38:57 2013 +0000 1.2 +++ b/configure.ac Thu Mar 21 20:35:16 2013 +0000 1.3 @@ -20,12 +20,22 @@ 1.4 1.5 AC_ARG_ENABLE(c-core, 1.6 AC_HELP_STRING([--enable-c-core],[enable C core (default is no on x86 targets)]), 1.7 - [VBA_USE_C_CORE=$enableval]) 1.8 + [VBA_USE_C_CORE=$enableval]) 1.9 1.10 AS_CASE([$VBA_USE_C_CORE], 1.11 [yes], [AM_CXXFLAGS="$AM_CXXFLAGS -DC_CORE"], 1.12 [no], []) 1.13 1.14 +AC_ARG_ENABLE(profiling, 1.15 + AC_HELP_STRING([--enable-profiling],[enable profiling (default is yes)]), 1.16 + , enable_profiling=yes) 1.17 + 1.18 +AS_CASE([$enable_profiling], 1.19 + [yes], [AM_CXXFLAGS="$AM_CXXFLAGS -DPROFILING" 1.20 + VBA_SRC_EXTRA="$VBA_SRC_EXTRA prof" 1.21 + VBA_LIBS="$VBA_LIBS ../prof/libprof.a"], 1.22 + [no], []) 1.23 + 1.24 # Checks for programs. 1.25 AC_PROG_CXX 1.26 AC_PROG_CC 1.27 @@ -36,7 +46,6 @@ 1.28 AC_PROG_MKDIR_P 1.29 AC_PATH_PROG(NASM, nasm) 1.30 1.31 - 1.32 # Checks for libraries. 1.33 AC_CHECK_LIB(z, gzopen, 1.34 , AC_MSG_ERROR([*** Cannot compile without zlib.])) 1.35 @@ -98,6 +107,9 @@ 1.36 src/sdl/Makefile]) 1.37 1.38 AC_SUBST([AM_CXXFLAGS]) 1.39 +AC_SUBST([VBA_SRC_EXTRA]) 1.40 +AC_SUBST([VBA_LIBS]) 1.41 + 1.42 1.43 AC_OUTPUT 1.44 1.45 @@ -105,6 +117,8 @@ 1.46 echo "******** RLM ****************" 1.47 echo "target= $target" 1.48 echo "VBA_USE_C_CORE= $VBA_USE_C_CORE" 1.49 -echo "VBA_USE_MMX= $VBA_USE_MMX" 1.50 echo "AM_CXXFLAGS= $AM_CXXFLAGS" 1.51 echo "enable_c_core= $enable_c_core" 1.52 +echo "enable_profiling= $enable_profiling" 1.53 +echo "VBA_SRC_EXTRA= $VBA_SRC_EXTRA" 1.54 +echo "VBA_LIBS= $VBA_LIBS"
2.1 --- a/src/Makefile.am Thu Mar 21 19:38:57 2013 +0000 2.2 +++ b/src/Makefile.am Thu Mar 21 20:35:16 2013 +0000 2.3 @@ -1,4 +1,4 @@ 2.4 -SUBDIRS = SFMT lua gb gba common filters prof sdl 2.5 +SUBDIRS = SFMT lua gb gba common filters @VBA_SRC_EXTRA@ sdl 2.6 2.7 dist_sysconf_DATA = VisualBoyAdvance.cfg 2.8
3.1 --- a/src/gba/Makefile.am Thu Mar 21 19:38:57 2013 +0000 3.2 +++ b/src/gba/Makefile.am Thu Mar 21 20:35:16 2013 +0000 3.3 @@ -45,4 +45,4 @@ 3.4 -DSDL \ 3.5 -DSYSCONFDIR=\"$(sysconfdir)\" 3.6 3.7 -AM_CXXFLAGS = -fno-exceptions 3.8 +AM_CXXFLAGS = @AM_CXXFLAGS@ -fno-exceptions
4.1 --- a/src/sdl/Makefile.am Thu Mar 21 19:38:57 2013 +0000 4.2 +++ b/src/sdl/Makefile.am Thu Mar 21 20:35:16 2013 +0000 4.3 @@ -32,7 +32,7 @@ 4.4 ../gba/libgba.a \ 4.5 ../filters/lib386.a \ 4.6 ../filters/libfilter.a \ 4.7 - ../prof/libprof.a \ 4.8 + @VBA_LIBS@ \ 4.9 ../lua/libgblua.a 4.10 4.11 # TestEmu_SOURCES = \