forked from Vertexwahn/rules_qt6
-
Notifications
You must be signed in to change notification settings - Fork 0
/
qt_mac_aarch64.BUILD
57 lines (50 loc) · 1.34 KB
/
qt_mac_aarch64.BUILD
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
load("@rules_qt//:qt_libraries.bzl", "QT_LIBRARIES")
[
cc_library(
name = "qt_%s_mac" % name,
hdrs = glob(["include/%s/**" % include_folder]), # allow_empty = True
includes = [
"include",
"include/QtCore",
],
linkopts = ["-F/opt/homebrew/lib"] + [
"-framework %s" % library_name.replace("6", ""), # macOS qt libs do not contain a 6 - e.g. instead of Qt6Core the lib is called QtCore
],
target_compatible_with = ["@platforms//os:osx"],
visibility = ["//visibility:public"],
)
for name, include_folder, library_name, _ in QT_LIBRARIES
]
cc_library(
name = "qt_hdrs",
hdrs = glob(["include/**"]),
includes = [
"include",
],
visibility = ["//visibility:public"],
)
filegroup(
name = "uic",
srcs = ["share/qt/libexec/uic"],
visibility = ["//visibility:public"],
)
filegroup(
name = "moc",
srcs = ["share/qt/libexec/moc"],
visibility = ["//visibility:public"],
)
filegroup(
name = "rcc",
srcs = ["share/qt/libexec/rcc"],
visibility = ["//visibility:public"],
)
filegroup(
name = "plugin_files",
srcs = glob(["share/qt/plugins/**/*"]),
visibility = ["//visibility:public"],
)
filegroup(
name = "qml_files",
srcs = glob(["qml/**/*"]),
visibility = ["//visibility:public"],
)