# Copyright (c) 2008 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. __doc__ = """ Configuration for building the perf_tests{,.exe} executable. """ Import('env') env = env.Clone() env.ApplySConscript([ '$BASE_DIR/using_base.scons', '$NET_DIR/using_net.scons', '$CHROME_SRC_DIR/build/using_googleurl.scons', '$GTEST_DIR/../using_gtest.scons', '$ICU38_DIR/using_icu38.scons', '$MODP_B64_DIR/using_modp_b64.scons', ]) env.Prepend( CPPDEFINES = [ 'PERF_TEST', ], LIBS = [ 'browser', 'common', 'sqlite', ], ) if env['PLATFORM'] in ('posix', 'darwin'): env.SConscript([ '$LIBEVENT_DIR/using_libevent.scons', ], {'env':env}) input_files = [ 'perftests.cc', 'url_parse_perftest.cc', '$BASE_DIR/perftimer$OBJSUFFIX', '$CHROME_DIR/browser/safe_browsing/database_perftest.cc', '$CHROME_DIR/browser/visitedlink_master$OBJSUFFIX', '$CHROME_DIR/browser/visitedlink_perftest.cc', '$CHROME_DIR/common/json_value_serializer_perftest.cc', ] if env['PLATFORM'] == 'win32': env.Prepend( LIBS = [ 'rpcrt4', 'shlwapi', 'winmm', ] ) if env['PLATFORM'] != 'win32': # TODO(port): Port these files. remove_files = [ 'url_parse_perftest.cc', '$CHROME_DIR/browser/visitedlink_master$OBJSUFFIX', '$CHROME_DIR/browser/visitedlink_perftest.cc', ] for file in remove_files: input_files.remove(file) if env['PLATFORM'] in ('posix', 'win32'): env.ChromeTestProgram('perf_tests', input_files)