1# Copyright (C) 2023 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 14import("//build/ohos.gni") 15 16config("gst_subtitle_parse_plugin_config") { 17 visibility = [ ":*" ] 18 cflags = [ 19 "-fno-rtti", 20 "-fno-exceptions", 21 "-Wall", 22 "-fno-common", 23 "-fstack-protector-strong", 24 "-FPIC", 25 "-FS", 26 "-O2", 27 "-D_FORTIFY_SOURCE=2", 28 "-fvisibility=hidden", 29 "-Wformat=2", 30 "-Wfloat-equal", 31 "-Wdate-time", 32 "-DOHOS_EXT_FUNC", 33 "-Werror", 34 "-Wextra", 35 "-Wimplicit-fallthrough", 36 "-Wsign-compare", 37 "-Wunused-parameter", 38 ] 39 40 include_dirs = [ 41 "../../../../utils/include", 42 "//third_party/gstreamer/gstreamer", 43 "//third_party/gstreamer/gstreamer/gst", 44 "//third_party/gstreamer/gstreamer/libs", 45 "//third_party/gstreamer/gstplugins_base", 46 "//third_party/gstreamer/gstplugins_base/gst-libs", 47 "//third_party/glib/glib", 48 "//third_party/glib", 49 "//third_party/glib/gmodule", 50 ] 51} 52 53ohos_shared_library("gst_subtitle_parse_plugin") { 54 install_enable = true 55 56 sources = [ 57 "gst_subtitle_base_parse.cpp", 58 "gst_subtitle_base_parse_wrap.cpp", 59 "gst_subtitle_common.cpp", 60 "gst_subtitle_plugin.cpp", 61 "gst_subtitle_srt_parse.cpp", 62 ] 63 64 configs = [ 65 ":gst_subtitle_parse_plugin_config", 66 "../../../../dfx:media_service_log_dfx_public_config", 67 ] 68 69 deps = [ 70 "../../../../dfx:media_service_log_dfx", 71 "../../../../utils:media_service_utils", 72 "//third_party/glib:glib", 73 "//third_party/glib:gmodule", 74 "//third_party/glib:gobject", 75 "//third_party/gstreamer/gstreamer:gstbase", 76 "//third_party/gstreamer/gstreamer:gstreamer", 77 ] 78 79 external_deps = [ 80 "c_utils:utils", 81 "hilog:libhilog", 82 ] 83 84 relative_install_dir = "media/plugins" 85 subsystem_name = "multimedia" 86 part_name = "player_framework" 87} 88