mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
bazel: Add initial config for binary distribution (see #3757)
Add support for building the CEF binary distribution using Bazel and the default platform toolchain. Tested to work for Windows x64, MacOS ARM64 and x64 (cross-compile from ARM64), and Linux x64. Windows x86 (cross-compile from x64) is known to be broken, see https://github.com/bazelbuild/bazel/issues/22164. Includes minor changes to tests directory structure to meet Bazel build requirements.
This commit is contained in:
68
bazel/linux/variables.bzl
Executable file
68
bazel/linux/variables.bzl
Executable file
@ -0,0 +1,68 @@
|
||||
# Copyright (c) 2024 The Chromium Embedded Framework Authors. All rights
|
||||
# reserved. Use of this source code is governed by a BSD-style license that
|
||||
# can be found in the LICENSE file.
|
||||
|
||||
#
|
||||
# Distribution SOs.
|
||||
#
|
||||
|
||||
SOS = [
|
||||
"libcef.so",
|
||||
"libEGL.so",
|
||||
"libGLESv2.so",
|
||||
"libvk_swiftshader.so",
|
||||
"libvulkan.so.1",
|
||||
]
|
||||
|
||||
#
|
||||
# Common 'linkopts' for cc_binary targets.
|
||||
#
|
||||
|
||||
# Standard link libraries.
|
||||
STANDARD_LIBS = [
|
||||
"X11",
|
||||
]
|
||||
|
||||
COMMON_LINKOPTS_DEBUG = [
|
||||
]
|
||||
|
||||
COMMON_LINKOPTS_RELEASE = [
|
||||
]
|
||||
|
||||
COMMON_LINKOPTS = [
|
||||
"-l{}".format(lib) for lib in STANDARD_LIBS
|
||||
] + select({
|
||||
"//:linux_dbg": COMMON_LINKOPTS_DEBUG,
|
||||
"//conditions:default": COMMON_LINKOPTS_RELEASE,
|
||||
})
|
||||
|
||||
#
|
||||
# Common 'copts' for cc_libary and cc_binary targets.
|
||||
#
|
||||
|
||||
COMMON_COPTS = [
|
||||
]
|
||||
|
||||
COMMON_COPTS_DEBUG = [
|
||||
]
|
||||
|
||||
COMMON_COPTS_RELEASE = [
|
||||
]
|
||||
|
||||
#
|
||||
# Common 'defines' for cc_libary targets.
|
||||
#
|
||||
|
||||
COMMON_DEFINES = [
|
||||
# Used by apps to test if the sandbox is enabled
|
||||
"CEF_USE_SANDBOX",
|
||||
]
|
||||
|
||||
COMMON_DEFINES_DEBUG = [
|
||||
]
|
||||
|
||||
COMMON_DEFINES_RELEASE = [
|
||||
# Not a debug build
|
||||
"NDEBUG",
|
||||
]
|
||||
|
Reference in New Issue
Block a user