| 1 |
# ~~~ |
| 2 |
# Copyright (c) 2021-2022 Valve Corporation |
| 3 |
# Copyright (c) 2021-2022 LunarG, Inc. |
| 4 |
# |
| 5 |
# Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 |
# you may not use this file except in compliance with the License. |
| 7 |
# You may obtain a copy of the License at |
| 8 |
# |
| 9 |
# http://www.apache.org/licenses/LICENSE-2.0 |
| 10 |
# |
| 11 |
# Unless required by applicable law or agreed to in writing, software |
| 12 |
# distributed under the License is distributed on an "AS IS" BASIS, |
| 13 |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 |
# See the License for the specific language governing permissions and |
| 15 |
# limitations under the License. |
| 16 |
# ~~~ |
| 17 |
|
| 18 |
set(TEST_LAYER_BASE_EXPORTS TEST_LAYER_EXPORT_ENUMERATE_FUNCTIONS=1) |
| 19 |
set(TEST_LAYER_VERSION_0_EXPORTS ${TEST_LAYER_BASE_EXPORTS} TEST_LAYER_EXPORT_LAYER_VK_GIPA=1 TEST_LAYER_EXPORT_LAYER_VK_GDPA=1) |
| 20 |
set(TEST_LAYER_VERSION_0_NAMED_GPA_EXPORTS ${TEST_LAYER_BASE_EXPORTS} TEST_LAYER_EXPORT_LAYER_NAMED_GIPA=1 TEST_LAYER_EXPORT_LAYER_NAMED_GDPA=1) |
| 21 |
set(TEST_LAYER_VERSION_1_EXPORTS ${TEST_LAYER_VERSION_0_EXPORTS} TEST_LAYER_EXPORT_OVERRIDE_GIPA=1 TEST_LAYER_EXPORT_OVERRIDE_GDPA=1) |
| 22 |
set(TEST_LAYER_VERSION_2_EXPORTS ${TEST_LAYER_VERSION_1_EXPORTS} TEST_LAYER_EXPORT_GET_PHYSICAL_DEVICE_PROC_ADDR=1 |
| 23 |
LAYER_EXPORT_NEGOTIATE_LOADER_LAYER_INTERFACE_VERSION=1) |
| 24 |
|
| 25 |
AddSharedLibrary(test_layer_export_base DEF_FILE test_layer_base SOURCES test_layer.cpp DEFINITIONS ${TEST_LAYER_BASE_EXPORTS}) |
| 26 |
AddSharedLibrary(test_layer_export_version_0 DEF_FILE test_layer_0 SOURCES test_layer.cpp DEFINITIONS ${TEST_LAYER_VERSION_0_EXPORTS}) |
| 27 |
AddSharedLibrary(test_layer_export_version_0_named_gpa DEF_FILE test_layer_0_named_gpa SOURCES test_layer.cpp DEFINITIONS ${TEST_LAYER_VERSION_0_NAMED_GPA_EXPORTS}) |
| 28 |
AddSharedLibrary(test_layer_export_version_1 DEF_FILE test_layer_1 SOURCES test_layer.cpp DEFINITIONS ${TEST_LAYER_VERSION_1_EXPORTS}) |
| 29 |
AddSharedLibrary(test_layer_export_version_2 DEF_FILE test_layer_2 SOURCES test_layer.cpp DEFINITIONS ${TEST_LAYER_VERSION_2_EXPORTS}) |
| 30 |
|
| 31 |
# Wrap Objects layer which wraps dispatchable handles to test that the loader will properly |
| 32 |
# work in the case where handles in the terminator don't match handles in the trampoline portion. |
| 33 |
set(WRAP_LAYER_VERSION_1_EXPORTS |
| 34 |
TEST_LAYER_EXPORT_DIRECT_DISP=1 |
| 35 |
TEST_LAYER_EXPORT_MAINT_1=1 |
| 36 |
) |
| 37 |
set(WRAP_LAYER_VERSION_2_EXPORTS |
| 38 |
TEST_LAYER_EXPORT_DISP_SURF_COUNT=1 |
| 39 |
TEST_LAYER_EXPORT_PRESENT_IMAGE=1 |
| 40 |
) |
| 41 |
set(WRAP_LAYER_VERSION_3_EXPORTS |
| 42 |
TEST_LAYER_EXPORT_DIRECT_DISP=1 |
| 43 |
TEST_LAYER_EXPORT_DISP_SURF_COUNT=1 |
| 44 |
TEST_LAYER_EXPORT_MAINT_1=1 |
| 45 |
TEST_LAYER_EXPORT_PRESENT_IMAGE=1 |
| 46 |
) |
| 47 |
|
| 48 |
AddSharedLibrary(test_layer_wrap_objects DEF_FILE wrap_objects SOURCES wrap_objects.cpp DEFINITIONS "") |
| 49 |
AddSharedLibrary(test_layer_wrap_objects_1 DEF_FILE wrap_objects_1 SOURCES wrap_objects.cpp DEFINITIONS ${WRAP_LAYER_VERSION_1_EXPORTS}) |
| 50 |
AddSharedLibrary(test_layer_wrap_objects_2 DEF_FILE wrap_objects_2 SOURCES wrap_objects.cpp DEFINITIONS ${WRAP_LAYER_VERSION_2_EXPORTS}) |
| 51 |
AddSharedLibrary(test_layer_wrap_objects_3 DEF_FILE wrap_objects_3 SOURCES wrap_objects.cpp DEFINITIONS ${WRAP_LAYER_VERSION_3_EXPORTS}) |