1# Copyright (c) 2021 Huawei Device Co., Ltd. 2# 3# This program is free software; you can redistribute it and/or modify 4# it under the terms of the GNU General Public License as published by 5# the Free Software Foundation; either version 2 of the License, or 6# (at your option) any later version. 7 8import("//build/ohos.gni") 9import("//build/ohos/ndk/ndk.gni") 10 11config("gptdisk_config") { 12 include_dirs = [ 13 ".", 14 "//third_party/e2fsprogs/lib/", 15 "//third_party/popt/", 16 ] 17 cflags_cc = [ 18 "-Wall", 19 "-D_FILE_OFFSET_BITS=64", 20 "-Wno-unused-parameter", 21 "-Wno-pragma-pack", 22 "-Wno-error=header-hygiene", 23 "-Wno-register", 24 ] 25} 26ohos_executable("sgdisk") { 27 install_enable = true 28 sources = [ 29 "attributes.cc", 30 "basicmbr.cc", 31 "bsd.cc", 32 "crc32.cc", 33 "diskio-unix.cc", 34 "diskio.cc", 35 "gpt.cc", 36 "gptcl.cc", 37 "gptpart.cc", 38 "guid.cc", 39 "mbr.cc", 40 "mbrpart.cc", 41 "parttypes.cc", 42 "sgdisk.cc", 43 "support.cc", 44 ] 45 public_configs = [ ":gptdisk_config" ] 46 deps = [ 47 "//third_party/e2fsprogs/lib/uuid:libext2_uuid", 48 "//third_party/popt:popt_static", 49 ] 50 subsystem_name = "filemanagement" 51 part_name = "storage_service" 52 install_images = [ "system" ] 53} 54