| # Copyright 2019 The Fuchsia Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| import("//build/unification/zx_library.gni") |
| |
| zx_library("buffer") { |
| sdk = "source" |
| sdk_headers = [ |
| "storage/buffer/block_buffer_view.h", |
| "storage/buffer/block_buffer.h", |
| "storage/buffer/blocking_ring_buffer.h", |
| "storage/buffer/owned_vmoid.h", |
| "storage/buffer/ring_buffer.h", |
| "storage/buffer/vmo_buffer.h", |
| "storage/buffer/vmoid_registry.h", |
| "storage/buffer/array_buffer.h", |
| ] |
| host = true |
| sources = [ |
| "array_buffer.cc", |
| "block_buffer.cc", |
| ] |
| static = true |
| |
| if (is_fuchsia) { |
| sources += [ |
| "blocking_ring_buffer.cc", |
| "owned_vmoid.cc", |
| "ring_buffer.cc", |
| "vmo_buffer.cc", |
| ] |
| public_deps = [ |
| "//zircon/public/lib/fbl", |
| "//zircon/public/lib/zx", |
| "//zircon/public/lib/zxc", |
| "//zircon/system/ulib/fzl", |
| "//zircon/system/ulib/storage/operation", |
| ] |
| deps = [ |
| "//sdk/lib/fdio", |
| "//zircon/public/lib/fbl", |
| |
| # TODO(fxbug.dev/38240): Clean up any remaining 'fs' dependencies. Only for fs/trace |
| "//sdk/lib/syslog/cpp", |
| "//src/lib/storage/vfs/cpp", |
| "//zircon/public/lib/safemath", |
| "//zircon/public/lib/zx", |
| "//zircon/system/ulib/fzl", |
| "//zircon/system/ulib/storage/operation", |
| ] |
| } else { |
| public_deps = [ "//zircon/system/public" ] |
| } |
| } |
| |
| group("tests") { |
| testonly = true |
| deps = [ "test:tests" ] |
| } |