!10 gn文件格式刷新,subsystem_name的值改为filemanagement,路径/e2fsprogs/f2fs-tools-1.14.0改为/f2fs-tools/,config名称e2fsprogs-defaults改为f2fs-defaults 。fsck/BUILD.gn增加symlink_target_name。

Merge pull request !10 from xlfeng/master
This commit is contained in:
openharmony_sig_ci 2022-01-13 02:26:18 +00:00 committed by Gitee
commit ba2974652d
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
4 changed files with 100 additions and 124 deletions

View File

@ -1,66 +1,67 @@
# Copyright (c) 2021 Huawei Device Co., Ltd. # Copyright (c) 2021 Huawei Device Co., Ltd.
# #
# This program is free software; you can redistribute it and/or modify # This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as # it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation. # published by the Free Software Foundation.
import("//build/ohos.gni") import("//build/ohos.gni")
config("e2fsprogs-defaults") { config("f2fs-defaults") {
cflags = [ cflags = [
"-Wno-pointer-sign", "-Wno-pointer-sign",
"-Wno-unused-variable", "-Wno-unused-variable",
"-Wno-string-plus-int", "-Wno-string-plus-int",
"-Wno-error=format", "-Wno-error=format",
"-Wno-unused-function", "-Wno-unused-function",
"-Wno-unused-parameter", "-Wno-unused-parameter",
"-Wno-incompatible-pointer-types", "-Wno-incompatible-pointer-types",
] ]
} }
################################################### ###################################################
##Build fsck ##Build fsck
ohos_executable("fsck.f2fs") { ohos_executable("fsck.f2fs") {
configs = [ ":e2fsprogs-defaults" ] configs = [ ":f2fs-defaults" ]
sources = [ sources = [
"fsck.c", "defrag.c",
"main.c", "dict.c",
"defrag.c", "dir.c",
"dict.c", "dump.c",
"dir.c", "fsck.c",
"dump.c", "main.c",
"mkquota.c", "mkquota.c",
"mount.c", "mount.c",
"node.c", "node.c",
"quotaio.c", "quotaio.c",
"quotaio_tree.c", "quotaio_tree.c",
"quotaio_v2.c", "quotaio_v2.c",
"resize.c", "resize.c",
"segment.c", "segment.c",
"sload.c", "sload.c",
"xattr.c", "xattr.c",
] ]
include_dirs = [ include_dirs = [
".", ".",
"//third_party/e2fsprogs/f2fs-tools-1.14.0", "//third_party/f2fs-tools",
"//third_party/e2fsprogs/f2fs-tools-1.14.0/include", "//third_party/f2fs-tools/include",
"//third_party/e2fsprogs/f2fs-tools-1.14.0/lib", "//third_party/f2fs-tools/lib",
"//third_party/e2fsprogs/contrib/android", "//third_party/e2fsprogs/contrib/android",
] ]
deps = [ deps = [
"//third_party/e2fsprogs/f2fs-tools-1.14.0/lib:libf2fs",
"//third_party/e2fsprogs/contrib/android:libdacconfig", "//third_party/e2fsprogs/contrib/android:libdacconfig",
"//third_party/f2fs-tools/lib:libf2fs",
] ]
defines = [ defines = [ "HAVE_CONFIG_H" ]
"HAVE_CONFIG_H",
symlink_target_name = [
"resize.f2fs",
"sload.f2fs",
] ]
install_enable = true install_enable = true
subsystem_name = "storage_manager" subsystem_name = "filemanagement"
part_name = "storage_standard" part_name = "storage_standard"
install_images = [ install_images = [ "system" ]
"system",
]
} }

View File

@ -1,11 +1,11 @@
# Copyright (c) 2021 Huawei Device Co., Ltd. # Copyright (c) 2021 Huawei Device Co., Ltd.
# #
# This program is free software; you can redistribute it and/or modify # This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as # it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation. # published by the Free Software Foundation.
import("//build/ohos.gni") import("//build/ohos.gni")
config("e2fsprogs-defaults") { config("f2fs-defaults") {
cflags = [ cflags = [
"-Wall", "-Wall",
"-Werror", "-Werror",
@ -16,33 +16,31 @@ config("e2fsprogs-defaults") {
] ]
} }
config("libf2fs-headers") { config("libf2fs-headers") {
include_dirs = [ include_dirs = [
".", ".",
"//third_party/e2fsprogs/f2fs-tools-1.14.0", "//third_party/f2fs-tools",
"//third_party/e2fsprogs/f2fs-tools-1.14.0/include", "//third_party/f2fs-tools/include",
] ]
} }
ohos_shared_library("libf2fs") { ohos_shared_library("libf2fs") {
sources = [ sources = [
"libf2fs.c",
"libf2fs_io.c", "libf2fs_io.c",
"libf2fs_zoned.c", "libf2fs_zoned.c",
"libf2fs.c",
"nls_utf8.c", "nls_utf8.c",
] ]
include_dirs = [ "." ] include_dirs = [ "." ]
configs = [ configs = [
":e2fsprogs-defaults", ":f2fs-defaults",
":libf2fs-headers", ":libf2fs-headers",
] ]
defines = [ "HAVE_CONFIG_H" ] defines = [ "HAVE_CONFIG_H" ]
install_enable = true install_enable = true
subsystem_name = "storage_manager" subsystem_name = "filemanagement"
part_name = "storage_standard" part_name = "storage_standard"
install_images = [ install_images = [ "system" ]
"system",
]
} }

View File

@ -1,50 +1,46 @@
# Copyright (c) 2021 Huawei Device Co., Ltd. # Copyright (c) 2021 Huawei Device Co., Ltd.
# #
# This program is free software; you can redistribute it and/or modify # This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as # it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation. # published by the Free Software Foundation.
import("//build/ohos.gni") import("//build/ohos.gni")
config("e2fsprogs-defaults") { config("f2fs-defaults") {
cflags = [ cflags = [
"-Wno-pointer-sign", "-Wno-pointer-sign",
"-Wno-unused-variable", "-Wno-unused-variable",
"-Wno-string-plus-int", "-Wno-string-plus-int",
"-Wno-error=format", "-Wno-error=format",
] ]
} }
################################################### ###################################################
##Build mkfs.f2fs ##Build mkfs.f2fs
ohos_executable("mkfs.f2fs") { ohos_executable("mkfs.f2fs") {
configs = [ ":e2fsprogs-defaults" ] configs = [ ":f2fs-defaults" ]
sources = [ sources = [
"f2fs_format_main.c", "f2fs_format.c",
"f2fs_format_utils.c", "f2fs_format_main.c",
"f2fs_format.c", "f2fs_format_utils.c",
] ]
include_dirs = [ include_dirs = [
".", ".",
"//third_party/e2fsprogs/lib/uuid", "//third_party/e2fsprogs/lib/uuid",
"//third_party/e2fsprogs/f2fs-tools-1.14.0", "//third_party/f2fs-tools",
"//third_party/e2fsprogs/f2fs-tools-1.14.0/include", "//third_party/f2fs-tools/include",
"//third_party/e2fsprogs/f2fs-tools-1.14.0/lib", "//third_party/f2fs-tools/lib",
] ]
deps = [ deps = [
"//third_party/e2fsprogs/lib/uuid:libext2_uuid", "//third_party/e2fsprogs/lib/uuid:libext2_uuid",
"//third_party/e2fsprogs/f2fs-tools-1.14.0/lib:libf2fs", "//third_party/f2fs-tools/lib:libf2fs",
]
defines = [
"HAVE_CONFIG_H",
] ]
defines = [ "HAVE_CONFIG_H" ]
install_enable = true install_enable = true
subsystem_name = "storage_manager" subsystem_name = "filemanagement"
part_name = "storage_standard" part_name = "storage_standard"
install_images = [ install_images = [ "system" ]
"system",
]
} }

View File

@ -1,87 +1,74 @@
# Copyright (c) 2021 Huawei Device Co., Ltd. # Copyright (c) 2021 Huawei Device Co., Ltd.
# #
# This program is free software; you can redistribute it and/or modify # This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as # it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation. # published by the Free Software Foundation.
import("//build/ohos.gni") import("//build/ohos.gni")
config("e2fsprogs-defaults") { config("f2fs-defaults") {
cflags = [ cflags = [
"-std=gnu89", "-std=gnu89",
"-Wno-implicit-function-declaration", "-Wno-implicit-function-declaration",
"-Wno-pointer-sign", "-Wno-pointer-sign",
] ]
} }
################################################### ###################################################
##Build f2fscrypt ##Build f2fscrypt
ohos_executable("f2fscrypt") { ohos_executable("f2fscrypt") {
configs = [ ":e2fsprogs-defaults" ] configs = [ ":f2fs-defaults" ]
sources = [ sources = [
"f2fscrypt.c", "f2fscrypt.c",
"sha512.c", "sha512.c",
] ]
include_dirs = [ include_dirs = [
".", ".",
"//third_party/e2fsprogs/f2fs-tools-1.14.0", "//third_party/f2fs-tools",
"//third_party/e2fsprogs/f2fs-tools-1.14.0/include", "//third_party/f2fs-tools/include",
"//third_party/e2fsprogs/lib/uuid", "//third_party/e2fsprogs/lib/uuid",
] ]
cflags = [ "-Wno-error=format-extra-args" ] cflags = [ "-Wno-error=format-extra-args" ]
deps = [ deps = [ "//third_party/e2fsprogs/lib/uuid:libext2_uuid" ]
"//third_party/e2fsprogs/lib/uuid:libext2_uuid",
]
install_enable = true install_enable = true
subsystem_name = "storage_manager" subsystem_name = "filemanagement"
part_name = "storage_standard" part_name = "storage_standard"
install_images = [ install_images = [ "system" ]
"system",
]
} }
################################################### ###################################################
##Build f2fstat ##Build f2fstat
ohos_executable("f2fstat") { ohos_executable("f2fstat") {
configs = [ ":e2fsprogs-defaults" ] configs = [ ":f2fs-defaults" ]
sources = [ sources = [ "f2fstat.c" ]
"f2fstat.c",
]
include_dirs = [ include_dirs = [ "." ]
".",
]
cflags = [ cflags = [
"-Wno-error=format", "-Wno-error=format",
"-Wno-error=type-limits", "-Wno-error=type-limits",
"-Wno-format-extra-args", "-Wno-format-extra-args",
] ]
deps = [ deps = []
]
install_enable = true install_enable = true
subsystem_name = "storage_manager" subsystem_name = "filemanagement"
part_name = "storage_standard" part_name = "storage_standard"
install_images = [ install_images = [ "system" ]
"system",
]
} }
################################################### ###################################################
##Build fibmap.f2fs ##Build fibmap.f2fs
ohos_executable("fibmap.f2fs") { ohos_executable("fibmap.f2fs") {
configs = [ ":e2fsprogs-defaults" ] configs = [ ":f2fs-defaults" ]
sources = [ sources = [ "fibmap.c" ]
"fibmap.c",
]
include_dirs = [ include_dirs = [
".", ".",
"//third_party/e2fsprogs/f2fs-tools-1.14.0", "//third_party/f2fs-tools",
"//third_party/e2fsprogs/f2fs-tools-1.14.0/include", "//third_party/f2fs-tools/include",
"//third_party/e2fsprogs/f2fs-tools-1.14.0/lib", "//third_party/f2fs-tools/lib",
] ]
cflags = [ cflags = [
@ -90,18 +77,12 @@ ohos_executable("fibmap.f2fs") {
"-Wno-format-extra-args", "-Wno-format-extra-args",
] ]
deps = [ deps = [ "//third_party/f2fs-tools/lib:libf2fs" ]
"//third_party/e2fsprogs/f2fs-tools-1.14.0/lib:libf2fs",
]
defines = [ defines = [ "HAVE_CONFIG_H" ]
"HAVE_CONFIG_H",
]
install_enable = true install_enable = true
subsystem_name = "storage_manager" subsystem_name = "filemanagement"
part_name = "storage_standard" part_name = "storage_standard"
install_images = [ install_images = [ "system" ]
"system",
]
} }