• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2021-2021 Huawei Device Co., Ltd.
2# Licensed under the Apache License, Version 2.0 (the "License");
3# you may not use this file except in compliance with the License.
4# You may obtain a copy of the License at
5#
6#     http://www.apache.org/licenses/LICENSE-2.0
7#
8# Unless required by applicable law or agreed to in writing, software
9# distributed under the License is distributed on an "AS IS" BASIS,
10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11# See the License for the specific language governing permissions and
12# limitations under the License.
13#
14
15group("plugin_file_source") {
16  deps = [ ":histreamer_plugin_FileSource" ]
17}
18
19source_set("filesource") {
20  sources = [ "file_source_plugin.cpp" ]
21  public_deps = [
22    "//foundation/multimedia/histreamer/engine/foundation:histreamer_foundation",
23    "//foundation/multimedia/histreamer/engine/plugin:histreamer_plugin_intf",
24    "//foundation/multimedia/histreamer/engine/utils:histreamer_utils",
25  ]
26  cflags = [
27    "-fPIC",
28    "-Wall",
29  ]
30  if (!defined(ohos_lite)) {
31    configs -= [
32      "//build/config/compiler:no_rtti",
33      "//build/config/compiler:no_exceptions",
34    ]
35    cflags += [
36      "-frtti",
37      "-fexceptions",
38    ]
39  }
40  cflags_cc = cflags
41}
42
43if (defined(ohos_lite)) {
44  # lite
45  import("//build/lite/config/component/lite_component.gni")
46  lite_library("histreamer_plugin_FileSource") {
47    if (ohos_kernel_type == "liteos_m") {
48      target_type = "static_library"
49    } else {
50      target_type = "shared_library"
51    }
52    sources = []
53    deps = [ ":filesource" ]
54  }
55} else {
56  # standard
57  import("//build/ohos.gni")
58  ohos_shared_library("histreamer_plugin_FileSource") {
59    deps = [ ":filesource" ]
60    relative_install_dir = "media/histreamer_plugins"
61    subsystem_name = "multimedia"
62    part_name = "multimedia_histreamer"
63  }
64}
65