| # 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. |
| zx_library("minfs") { |
| sdk = "source" |
| sdk_headers = [ |
| "minfs/fsck.h", |
| "minfs/bcache.h", |
| "minfs/superblock.h", |
| "minfs/inspector.h", |
| "minfs/writeback.h", |
| "minfs/transaction_limits.h", |
| "minfs/allocator_reservation.h", |
| "minfs/format.h", |
| "minfs/mutex.h", |
| "minfs/minfs.h", |
| "minfs/host.h", |
| "minfs/metrics.h", |
| "minfs/pending_work.h", |
| "minfs/command_handler.h", |
| "minfs/minfs_inspector.h", |
| ] |
| host = true |
| static = true |
| sources = [ |
| "allocator/allocator_common.cc", |
| "allocator/allocator_reservation.cc", |
| "allocator/metadata.cc", |
| "allocator/storage_common.cc", |
| "directory.cc", |
| "file.cc", |
| "fsck.cc", |
| "metrics.cc", |
| "minfs.cc", |
| "transaction_limits.cc", |
| "vnode.cc", |
| "writeback.cc", |
| ] |
| if (!is_fuchsia) { |
| sources += [ |
| "allocator/allocator_host.cc", |
| "allocator/inode_manager_host.cc", |
| "allocator/storage_host.cc", |
| "bcache_host.cc", |
| "host.cc", |
| "superblock_host.cc", |
| ] |
| } |
| public_deps = [ |
| "$zx/system/ulib/bitmap:headers", |
| |
| #"$zx/system/ulib/disk_inspector:headers", |
| "$zx/system/ulib/fbl:headers", |
| "$zx/system/ulib/fs:headers", |
| "$zx/system/ulib/fs/journal:headers", |
| "$zx/system/ulib/fs/transaction:headers", |
| |
| # <minfs/bcache.h> has #include <fvm/client.h>. |
| "$zx/system/ulib/fvm:headers", |
| "$zx/system/ulib/storage/operation:headers", |
| ] |
| deps = [ |
| "$zx/system/ulib/bitmap", |
| "$zx/system/ulib/disk_inspector", |
| "$zx/system/ulib/fbl", |
| "$zx/system/ulib/fit", |
| "$zx/system/ulib/fs", |
| "$zx/system/ulib/fs/transaction", |
| "$zx/system/ulib/storage/buffer", |
| "$zx/system/ulib/storage/operation", |
| "$zx/system/ulib/zircon-internal", |
| "$zx/third_party/ulib/cksum", |
| "$zx/third_party/ulib/safemath", |
| ] |
| if (is_fuchsia) { |
| public_deps += [ |
| "$zx/system/fidl/fuchsia-hardware-block:c", |
| "$zx/system/fidl/fuchsia-hardware-block-volume:c", |
| "$zx/system/fidl/fuchsia-minfs:llcpp.headers", |
| "$zx/system/ulib/block-client", |
| "$zx/system/ulib/fzl:headers", |
| "$zx/system/ulib/storage-metrics:headers", |
| "$zx/system/ulib/zx:headers", |
| ] |
| deps += [ |
| "$zx/system/fidl/fuchsia-device:c", |
| "$zx/system/fidl/fuchsia-device:llcpp", |
| "$zx/system/fidl/fuchsia-io:llcpp", |
| "$zx/system/fidl/fuchsia-minfs:llcpp", |
| "$zx/system/ulib/async", |
| "$zx/system/ulib/async:async-cpp", |
| "$zx/system/ulib/async:async-default", |
| "$zx/system/ulib/async-loop", |
| "$zx/system/ulib/async-loop:async-loop-cpp", |
| "$zx/system/ulib/async-loop:async-loop-default.static", |
| "$zx/system/ulib/fdio", |
| "$zx/system/ulib/fdio-caller", |
| "$zx/system/ulib/fidl", |
| "$zx/system/ulib/fidl-utils", |
| "$zx/system/ulib/fs/journal", |
| "$zx/system/ulib/fvm", |
| "$zx/system/ulib/fzl", |
| "$zx/system/ulib/storage-metrics", |
| "$zx/system/ulib/storage/operation", |
| "$zx/system/ulib/sync", |
| "$zx/system/ulib/trace", |
| "$zx/system/ulib/trace-engine", |
| "$zx/system/ulib/zircon", |
| "$zx/system/ulib/zx", |
| ] |
| sources += [ |
| "allocator/allocator.cc", |
| "allocator/inode_manager.cc", |
| "allocator/storage.cc", |
| "bcache.cc", |
| "inspector.cc", |
| "inspector/command_handler.cc", |
| "inspector/disk_struct.cc", |
| "inspector/loader.cc", |
| "inspector/minfs_inspector.cc", |
| "inspector/parser.cc", |
| "inspector_inode.cc", |
| "inspector_inode_table.cc", |
| "inspector_superblock.cc", |
| "superblock.cc", |
| "vnode_allocation.cc", |
| ] |
| } |
| include_dirs = [ "." ] |
| } |