From 8d69d045793cbd7b5ebf2d0a05de98c3dd4381ff Mon Sep 17 00:00:00 2001 From: Kevin Lubick Date: Tue, 31 May 2022 15:20:59 -0400 Subject: [PATCH] [bazel] Add fixes for G3 Mostly, this adds placeholder BUILD.bazel files corresponding to files used in public.bzl The exception is src/ports/BUILD.bazel, which adds an explicit link command for dl, needed for dlopen etc. Bug: skia:12541 Change-Id: Id3801a4c718cec37bc2aa3920a8d810f8a80a373 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/545359 Reviewed-by: Ben Wagner --- include/c/BUILD.bazel | 5 +++++ include/gpu/d3d/BUILD.bazel | 5 +++++ include/gpu/gl/egl/BUILD.bazel | 5 +++++ include/gpu/graphite/BUILD.bazel | 5 +++++ include/gpu/graphite/mtl/BUILD.bazel | 5 +++++ include/gpu/mtl/BUILD.bazel | 5 +++++ include/utils/mac/BUILD.bazel | 5 +++++ src/c/BUILD.bazel | 5 +++++ src/fonts/BUILD.bazel | 5 +++++ src/gpu/ganesh/d3d/BUILD.bazel | 5 +++++ src/gpu/ganesh/gl/android/BUILD.bazel | 5 +++++ src/gpu/ganesh/gl/egl/BUILD.bazel | 5 +++++ src/gpu/ganesh/gl/iOS/BUILD.bazel | 5 +++++ src/gpu/ganesh/gl/mac/BUILD.bazel | 5 +++++ src/gpu/ganesh/gl/win/BUILD.bazel | 5 +++++ src/gpu/ganesh/mtl/BUILD.bazel | 5 +++++ src/lazy/BUILD.bazel | 5 +++++ src/pdf/BUILD.bazel | 5 +++++ src/ports/BUILD.bazel | 6 +++++- src/xml/BUILD.bazel | 5 +++++ src/xps/BUILD.bazel | 5 +++++ 21 files changed, 105 insertions(+), 1 deletion(-) create mode 100644 include/c/BUILD.bazel create mode 100644 include/gpu/d3d/BUILD.bazel create mode 100644 include/gpu/gl/egl/BUILD.bazel create mode 100644 include/gpu/graphite/BUILD.bazel create mode 100644 include/gpu/graphite/mtl/BUILD.bazel create mode 100644 include/gpu/mtl/BUILD.bazel create mode 100644 include/utils/mac/BUILD.bazel create mode 100644 src/c/BUILD.bazel create mode 100644 src/fonts/BUILD.bazel create mode 100644 src/gpu/ganesh/d3d/BUILD.bazel create mode 100644 src/gpu/ganesh/gl/android/BUILD.bazel create mode 100644 src/gpu/ganesh/gl/egl/BUILD.bazel create mode 100644 src/gpu/ganesh/gl/iOS/BUILD.bazel create mode 100644 src/gpu/ganesh/gl/mac/BUILD.bazel create mode 100644 src/gpu/ganesh/gl/win/BUILD.bazel create mode 100644 src/gpu/ganesh/mtl/BUILD.bazel create mode 100644 src/lazy/BUILD.bazel create mode 100644 src/pdf/BUILD.bazel create mode 100644 src/xml/BUILD.bazel create mode 100644 src/xps/BUILD.bazel diff --git a/include/c/BUILD.bazel b/include/c/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/include/c/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/include/gpu/d3d/BUILD.bazel b/include/gpu/d3d/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/include/gpu/d3d/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/include/gpu/gl/egl/BUILD.bazel b/include/gpu/gl/egl/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/include/gpu/gl/egl/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/include/gpu/graphite/BUILD.bazel b/include/gpu/graphite/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/include/gpu/graphite/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/include/gpu/graphite/mtl/BUILD.bazel b/include/gpu/graphite/mtl/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/include/gpu/graphite/mtl/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/include/gpu/mtl/BUILD.bazel b/include/gpu/mtl/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/include/gpu/mtl/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/include/utils/mac/BUILD.bazel b/include/utils/mac/BUILD.bazel new file mode 100644 index 0000000000..034f198bcb --- /dev/null +++ b/include/utils/mac/BUILD.bazel @@ -0,0 +1,5 @@ +load("//third_party/skia/HEAD/bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/c/BUILD.bazel b/src/c/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/c/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/fonts/BUILD.bazel b/src/fonts/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/fonts/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/gpu/ganesh/d3d/BUILD.bazel b/src/gpu/ganesh/d3d/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/gpu/ganesh/d3d/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/gpu/ganesh/gl/android/BUILD.bazel b/src/gpu/ganesh/gl/android/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/gpu/ganesh/gl/android/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/gpu/ganesh/gl/egl/BUILD.bazel b/src/gpu/ganesh/gl/egl/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/gpu/ganesh/gl/egl/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/gpu/ganesh/gl/iOS/BUILD.bazel b/src/gpu/ganesh/gl/iOS/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/gpu/ganesh/gl/iOS/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/gpu/ganesh/gl/mac/BUILD.bazel b/src/gpu/ganesh/gl/mac/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/gpu/ganesh/gl/mac/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/gpu/ganesh/gl/win/BUILD.bazel b/src/gpu/ganesh/gl/win/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/gpu/ganesh/gl/win/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/gpu/ganesh/mtl/BUILD.bazel b/src/gpu/ganesh/mtl/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/gpu/ganesh/mtl/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/lazy/BUILD.bazel b/src/lazy/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/lazy/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/pdf/BUILD.bazel b/src/pdf/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/pdf/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/ports/BUILD.bazel b/src/ports/BUILD.bazel index ddbf9fd640..f356ad745e 100644 --- a/src/ports/BUILD.bazel +++ b/src/ports/BUILD.bazel @@ -183,8 +183,12 @@ selects.config_setting_group( cc_library( name = "deps", + linkopts = select({ + "@platforms//os:linux": ["-ldl"], + "//conditions:default": [], + }), visibility = ["//src:__pkg__"], - deps = [] + select({ + deps = select({ ":any_freetype_fontmgr": [ "//third_party:freetype2", ], diff --git a/src/xml/BUILD.bazel b/src/xml/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/xml/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy() diff --git a/src/xps/BUILD.bazel b/src/xps/BUILD.bazel new file mode 100644 index 0000000000..69666adff2 --- /dev/null +++ b/src/xps/BUILD.bazel @@ -0,0 +1,5 @@ +load("//bazel:macros.bzl", "exports_files_legacy") + +licenses(["notice"]) + +exports_files_legacy()