From 13abd1dbf22898031421625c65070d834e4bd0d9 Mon Sep 17 00:00:00 2001 From: Faith Ekstrand Date: Mon, 30 Jan 2023 20:11:49 -0600 Subject: [PATCH] nouveau: Add stubs for an image layout library called NIL Part-of: --- src/nouveau/meson.build | 1 + src/nouveau/nil/meson.build | 38 ++++++++++++++++++++++++++++++++++++++ src/nouveau/nil/nil.c | 1 + src/nouveau/nil/nil.h | 11 +++++++++++ src/nouveau/vulkan/meson.build | 1 + 5 files changed, 52 insertions(+) create mode 100644 src/nouveau/nil/meson.build create mode 100644 src/nouveau/nil/nil.c create mode 100644 src/nouveau/nil/nil.h diff --git a/src/nouveau/meson.build b/src/nouveau/meson.build index bc0e42f..29a18fc 100644 --- a/src/nouveau/meson.build +++ b/src/nouveau/meson.build @@ -27,5 +27,6 @@ endif subdir('codegen') if with_nouveau_vk + subdir('nil') subdir('vulkan') endif diff --git a/src/nouveau/nil/meson.build b/src/nouveau/nil/meson.build new file mode 100644 index 0000000..d2231a0 --- /dev/null +++ b/src/nouveau/nil/meson.build @@ -0,0 +1,38 @@ +# Copyright © 2022 Collabora Ltd +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to deal +# in the Software without restriction, including without limitation the rights +# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +# copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in +# all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +# SOFTWARE. + +libnil_files = files( + 'nil.c', + 'nil.h', +) + +_libnil = static_library( + 'nil', + libnil_files, + include_directories : [inc_include, inc_src, inc_mapi, inc_mesa, inc_gallium], + dependencies : idep_mesautil, + c_args : [no_override_init_args], + gnu_symbol_visibility : 'hidden', +) + +idep_nil = declare_dependency( + include_directories : include_directories('.'), + link_with : _libnil, +) diff --git a/src/nouveau/nil/nil.c b/src/nouveau/nil/nil.c new file mode 100644 index 0000000..8cf6c8d --- /dev/null +++ b/src/nouveau/nil/nil.c @@ -0,0 +1 @@ +#include "nil.h" diff --git a/src/nouveau/nil/nil.h b/src/nouveau/nil/nil.h new file mode 100644 index 0000000..5f577be --- /dev/null +++ b/src/nouveau/nil/nil.h @@ -0,0 +1,11 @@ +#ifndef NIL_H +#define NIL_H + +#include +#include +#include + +#include "util/macros.h" +#include "util/format/u_format.h" + +#endif /* NIL_H */ diff --git a/src/nouveau/vulkan/meson.build b/src/nouveau/vulkan/meson.build index d3bece3..8adc407 100644 --- a/src/nouveau/vulkan/meson.build +++ b/src/nouveau/vulkan/meson.build @@ -77,6 +77,7 @@ nvk_entrypoints = custom_target( nvk_deps = [ dep_libdrm, + idep_nil, idep_nir, idep_nouveau_ws, idep_nvidia_headers, -- 2.7.4