-
Notifications
You must be signed in to change notification settings - Fork 1.3k
/
Copy pathbullet.BUILD
59 lines (50 loc) · 1.42 KB
/
bullet.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
58
59
# -*- python -*-
load("@bazel_tools//tools/build_defs/pkg:pkg.bzl", "pkg_tar")
load("@//tools:install.bzl", "cmake_config", "install", "install_cmake_config")
load("@//tools:python_lint.bzl", "python_lint")
package(default_visibility = ["//visibility:public"])
# Note that this is only a portion of Bullet.
cc_library(
name = "LinearMath",
srcs = glob(["src/LinearMath/**/*.cpp"]),
hdrs = glob(["src/LinearMath/**/*.h"]),
copts = ["-Wno-all"],
defines = ["BT_USE_DOUBLE_PRECISION"],
includes = ["src"],
)
cc_library(
name = "BulletCollision",
srcs = glob(["src/BulletCollision/**/*.cpp"]),
hdrs = glob(["src/BulletCollision/**/*.h"]) + ["src/btBulletCollisionCommon.h"],
copts = ["-Wno-all"],
defines = ["BT_USE_DOUBLE_PRECISION"],
includes = ["src"],
deps = [":LinearMath"],
)
pkg_tar(
name = "license",
extension = "tar.gz",
files = ["LICENSE.txt"],
mode = "0644",
package_dir = "bullet",
)
cmake_config(
package = "Bullet",
script = "@//tools:bullet-create-cps.py",
version_file = "VERSION",
)
install_cmake_config(package = "Bullet")
install(
name = "install",
doc_dest = "share/doc/bullet",
docs = ["AUTHORS.txt"],
guess_hdrs = "PACKAGE",
hdr_dest = "include/bullet",
license_docs = ["LICENSE.txt"],
targets = [
":BulletCollision",
":LinearMath",
],
deps = [":install_cmake_config"],
)
python_lint()