Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 3c9f0e1

Browse files
committed
Build fixes for roll (#135)
* Add define for rendering * Fix metal enum for older SDKs, add missing dep
1 parent 43a7508 commit 3c9f0e1

File tree

3 files changed

+17
-0
lines changed

3 files changed

+17
-0
lines changed

impeller/BUILD.gn

+4
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ config("impeller_public_config") {
1313
defines += [ "IMPELLER_SUPPORTS_PLATFORM=1" ]
1414
}
1515

16+
if (impeller_supports_rendering) {
17+
defines += [ "IMPELLER_SUPPORTS_RENDERING=1" ]
18+
}
19+
1620
if (is_win) {
1721
defines += [ "_USE_MATH_DEFINES" ]
1822
}

impeller/entity/BUILD.gn

+1
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ impeller_component("entity_unittests") {
8787

8888
deps = [
8989
":entity",
90+
"../geometry:geometry_unittests",
9091
"../playground",
9192
]
9293
}

impeller/renderer/backend/metal/command_buffer_mtl.mm

+12
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,18 @@
5353
return CommandBufferMTL::Status::kError;
5454
}
5555

56+
// TODO(dnfield): remove this declaration when we no longer need to build on
57+
// machines with lower SDK versions than 11.0.s
58+
#if !defined(MAC_OS_X_VERSION_11_0) || MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_11_0
59+
typedef enum MTLCommandEncoderErrorState : NSInteger {
60+
MTLCommandEncoderErrorStateUnknown = 0,
61+
MTLCommandEncoderErrorStateCompleted = 1,
62+
MTLCommandEncoderErrorStateAffected = 2,
63+
MTLCommandEncoderErrorStatePending = 3,
64+
MTLCommandEncoderErrorStateFaulted = 4,
65+
} API_AVAILABLE(macos(11.0), ios(14.0));
66+
#endif
67+
5668
API_AVAILABLE(ios(14.0), macos(11.0))
5769
NSString* MTLCommandEncoderErrorStateToString(
5870
MTLCommandEncoderErrorState state) {

0 commit comments

Comments
 (0)