2008-09-29 07:35:28 -07:00
|
|
|
dnl Copyright (C) 2008 Vincent Torri <vtorri at univ-evry dot fr>
|
|
|
|
dnl That code is public domain and can be freely used or copied.
|
|
|
|
|
|
|
|
dnl Macro that check if benchmark support is wanted.
|
|
|
|
|
|
|
|
dnl Usage: EFL_CHECK_BENCHMARK([ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
|
|
|
|
dnl Defines the automake conditionnal EFL_ENABLE_BENCHMARK
|
|
|
|
|
|
|
|
AC_DEFUN([EFL_CHECK_BENCHMARK],
|
|
|
|
[
|
|
|
|
|
|
|
|
dnl configure option
|
|
|
|
|
|
|
|
AC_ARG_ENABLE([benchmark],
|
2009-06-26 23:42:14 -07:00
|
|
|
[AC_HELP_STRING([--enable-benchmark], [enable benchmarking @<:@default=disabled@:>@])],
|
2008-09-29 07:35:28 -07:00
|
|
|
[
|
|
|
|
if test "x${enableval}" = "xyes" ; then
|
2008-10-03 08:28:13 -07:00
|
|
|
_efl_enable_benchmark="yes"
|
2008-09-29 07:35:28 -07:00
|
|
|
else
|
2008-10-03 08:28:13 -07:00
|
|
|
_efl_enable_benchmark="no"
|
2008-09-29 07:35:28 -07:00
|
|
|
fi
|
|
|
|
],
|
2009-06-26 23:42:14 -07:00
|
|
|
[_efl_enable_benchmark="no"])
|
|
|
|
|
2008-09-29 07:35:28 -07:00
|
|
|
AC_MSG_CHECKING([whether benchmark are built])
|
2008-10-03 08:28:13 -07:00
|
|
|
AC_MSG_RESULT([${_efl_enable_benchmark}])
|
2008-09-29 07:35:28 -07:00
|
|
|
|
2008-10-03 08:28:13 -07:00
|
|
|
AM_CONDITIONAL(EFL_ENABLE_BENCHMARK, test "x${_efl_enable_benchmark}" = "xyes")
|
2008-09-29 07:35:28 -07:00
|
|
|
|
2008-10-03 08:28:13 -07:00
|
|
|
if test "x${_efl_enable_benchmark}" = "xyes" ; then
|
2009-06-26 23:42:14 -07:00
|
|
|
m4_default([$1], [:])
|
2008-09-29 07:35:28 -07:00
|
|
|
else
|
2009-06-26 23:42:14 -07:00
|
|
|
m4_default([$2], [:])
|
2008-09-29 07:35:28 -07:00
|
|
|
fi
|
2008-10-03 08:28:13 -07:00
|
|
|
])
|
2009-06-26 23:42:14 -07:00
|
|
|
|
|
|
|
dnl End of efl_benchmark.m4
|