google / google/GoogleDataTransport

Bazel/Blaze BUILD

Open
#56 4 comments 1 reaction 0 assignees View on GitHub
Dominant language
Objective-C
Stars
59
Forks
48
PR merge metrics
No merged PRs in 30d

Description

Hey Googlers!

Any chance you'd be down to release the Blaze/Bazel (Blazel!) BUILD files for this code? Would be handy to those of use building with Bazel.

Two of the external dependencies have done so already (nanopb and PromisesObjC), and I'd asked GoogleUtilities if they'd do the same in https://github.com/google/GoogleUtilities/issues/72

If useful, here's one I spun up for my own quick use.

```Starlark
# Created from https://github.com/google/GoogleDataTransport/blob/1a65c30db4fc841e06586441682c2dda036d9db3/GoogleDataTransport.podspec

objc_library(
name = "GoogleDataTransport",
hdrs = glob(["GoogleDataTransport/GDTCORLibrary/Public/GoogleDataTransport/*.h"]),
visibility = ["//visibility:public"],

srcs = glob(["GoogleDataTransport/GDTCORLibrary/**/*", "GoogleDataTransport/GDTCCTLibrary/**/*"]),
deps = [
"@GooglePromises//:FBLPromises",
"@GoogleUtilities//:Environment",
"@GoogleUtilities//:Logger",
"@nanopb//:nanopb",
],
sdk_frameworks = [
"CoreTelephony",
"SystemConfiguration",
],
sdk_dylibs = ["libz"],
)
```

Thanks for your consideration!
Chris
(ex-Googler)

P.S. To load nanopb, you'll need a patch file to enable malloc. To save time, here's one that works for the latest commit (2210cd92a6237a9ff82b58cfbe0c58da25ce1e11) that supports the compiled protos you're embedding
```
--- pb.h
+++ pb.h
@@ -13,2 +13,2 @@
/* Enable support for dynamically allocated fields */
-/* #define PB_ENABLE_MALLOC 1 */
+#define PB_ENABLE_MALLOC 1

--- BUILD
+++ BUILD
@@ -7,2 +7,3 @@
cc_library(
name = "nanopb",
+ include_prefix = "nanopb",
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.