-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[workspace] Deprecate the tinyobjloader external (#19880)
Use vendored tinyobjloader_internal instead (using an ODR-safe hidden namespace, instead of -fvisibility=hidden; this avoids erroneously marking C++ standard library classes with hidden visibility). Drop the double_precision patch; we can use `defines = []` now that Drake has a proper implementation_deps graph. Move patch rationale comments to where they make sense (the patch files themselves), instead of the repository file. Remove stray patch metadata.
- Loading branch information
1 parent
e75c6cc
commit c3fee1d
Showing
15 changed files
with
86 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
load("//tools/lint:lint.bzl", "add_lint_tests") | ||
|
||
add_lint_tests() |
27 changes: 27 additions & 0 deletions
27
tools/workspace/tinyobjloader_internal/package.BUILD.bazel
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# -*- bazel -*- | ||
|
||
load( | ||
"@drake//tools/install:install.bzl", | ||
"install", | ||
) | ||
|
||
licenses(["notice"]) # MIT, ISC | ||
|
||
package( | ||
default_visibility = ["//visibility:public"], | ||
) | ||
|
||
cc_library( | ||
name = "tinyobjloader", | ||
srcs = ["tiny_obj_loader.cc"], | ||
hdrs = ["tiny_obj_loader.h"], | ||
defines = ["TINYOBJLOADER_USE_DOUBLE=1"], | ||
copts = ["-fvisibility=hidden"], | ||
includes = ["."], | ||
linkstatic = 1, | ||
) | ||
|
||
install( | ||
name = "install", | ||
docs = ["LICENSE"], | ||
) |
9 changes: 7 additions & 2 deletions
9
...oader/patches/default_texture_color.patch → ...ernal/patches/default_texture_color.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 7 additions & 2 deletions
9
...loader/patches/faster_float_parsing.patch → ...ternal/patches/faster_float_parsing.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
load("@drake//tools/workspace:github.bzl", "github_archive") | ||
|
||
def tinyobjloader_internal_repository( | ||
name, | ||
mirrors = None): | ||
github_archive( | ||
name = name, | ||
repository = "tinyobjloader/tinyobjloader", | ||
commit = "f5569db1ffb3b0222663ba38a7a9b3f6a461c469", | ||
sha256 = "f0a0f5ee4e1c7cc573fba9044c1dbed2f547b3ff058840fc8f83c6b7b79f2391", # noqa | ||
build_file = ":package.BUILD.bazel", | ||
mirrors = mirrors, | ||
patches = [ | ||
":patches/faster_float_parsing.patch", | ||
":patches/default_texture_color.patch", | ||
], | ||
) |