Skip to content

Commit

Permalink
Get GN build working
Browse files Browse the repository at this point in the history
- Static library
- Add overrides, not necessary yet but it will be when other parts of
  this repo wants to find Vulkan-Headers
- Remove unused dependency on Vulkan-Headers from the settings library
- Remove unreachable return flagged by clang
  • Loading branch information
mikes-lunarg authored and christophe-lunarg committed Aug 9, 2023
1 parent 5dd42f6 commit 647235d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 25 deletions.
30 changes: 7 additions & 23 deletions BUILD.gn
Original file line number Diff line number Diff line change
@@ -1,36 +1,20 @@
# Copyright 2023-2023 The ANGLE Project Authors.
# Copyright 2023-2023 LunarG, Inc.
#
# SPDX-License-Identifier: Apache-2.0

source_set("vulkan_utility_libraries") {
include_dirs = [
"include",
]
import("//build_overrides/vulkan_utility_libraries.gni")

static_library("vulkan_layer_settings") {
include_dirs = [ "include" ]
sources = [
"include/vulkan/layer/vk_layer_settings.h",
"include/vulkan/layer/vk_layer_settings.hpp",
"include/vulkan/layer/vk_layer_settings_ext.h",
"src/layer/layer_settings_manager.cpp",
"src/layer/layer_settings_manager.hpp",
"src/layer/layer_settings_util.cpp",
"src/layer/layer_settings_util.hpp",
"src/layer/vk_layer_settings.cpp",
"src/layer/vk_layer_settings_helper.cpp",
"include/vulkan/layer/vk_layer_settings_ext.h",
"include/vulkan/layer/vk_layer_settings.h",
"include/vulkan/layer/vk_layer_settings.hpp",
]
public_configs = [ ":vulkan_headers_config" ]
public_deps = [ "$vulkan_headers_dir:vulkan_headers" ]
}

if (is_fuchsia) {
library_type = "loadable_module"
} else {
library_type = "shared_library"
}

target(library_type, "vulkan_layer_settings") {
defines = []
ldflags = []
deps = [ ":vulkan_utility_libraries" ]
}

2 changes: 0 additions & 2 deletions src/layer/vk_layer_settings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -558,8 +558,6 @@ VkResult vlGetLayerSettingValues(VlLayerSettingSet layerSettingSet, const char *
return result;
}
}

return VK_ERROR_UNKNOWN;
}

const VkLayerSettingsCreateInfoEXT *vlFindLayerSettingsCreateInfo(const VkInstanceCreateInfo *pCreateInfo) {
Expand Down

0 comments on commit 647235d

Please sign in to comment.