1# Copyright 2022 The SwiftShader Authors. All Rights Reserved. 2# 3# Licensed under the Apache License, Version 2.0 (the "License"); 4# you may not use this file except in compliance with the License. 5# You may obtain a copy of the License at 6# 7# http://www.apache.org/licenses/LICENSE-2.0 8# 9# Unless required by applicable law or agreed to in writing, software 10# distributed under the License is distributed on an "AS IS" BASIS, 11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12# See the License for the specific language governing permissions and 13# limitations under the License. 14 15set(ROOT_PROJECT_COMPILE_OPTIONS 16 ${SWIFTSHADER_COMPILE_OPTIONS} 17) 18 19set(ROOT_PROJECT_LINK_LIBRARIES 20 ${OS_LIBS} 21 ${SWIFTSHADER_LIBS} 22) 23 24set(PIPELINE_BENCHMARKS_SRC_FILES 25 PipelineBenchmarks.cpp 26) 27 28add_executable(PipelineBenchmarks 29 ${PIPELINE_BENCHMARKS_SRC_FILES} 30) 31 32set_target_properties(PipelineBenchmarks PROPERTIES 33 FOLDER "Tests/Benchmarks" 34 RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}" 35) 36 37target_compile_options(PipelineBenchmarks 38 PRIVATE 39 ${ROOT_PROJECT_COMPILE_OPTIONS} 40) 41 42target_link_options(PipelineBenchmarks 43 PRIVATE 44 ${SWIFTSHADER_LINK_FLAGS} 45) 46 47target_link_libraries(PipelineBenchmarks 48 PRIVATE 49 benchmark::benchmark 50 Reactor 51 vk_pipeline 52 ${ROOT_PROJECT_LINK_LIBRARIES} 53) 54