Commit 59e1f0f
Ruby | Add support for a protobuf debug build (#21060)
This PR makes a small change to `extconf.rb` so we can easily build the `protobuf_c` Ruby bindings with all debug symbols included. We used [grpc](https://github.com/grpc/grpc/blob/master/src/ruby/ext/grpc/extconf.rb) as a guide, which will produce a debug build if `rake` is run with `GRPC_CONFIG=dbg`. Unlike `grpc`, the `protobuf_c` build doesn't explicitly strip symbols from the resulting library, but values will be optimized out when stepping through with `gdb`.
This change also reconciles an oversight that `-fvisibility=hidden` was not set when building on non-Darwin/Linux/Freebsd platforms.
Closes #21060
COPYBARA_INTEGRATE_REVIEW=#21060 from Shopify:ruby-debug-build 353b272
PiperOrigin-RevId: 7447189271 parent d3560e7 commit 59e1f0f
2 files changed
+14
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
92 | 100 | | |
93 | 101 | | |
94 | 102 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
21 | 25 | | |
22 | | - | |
| 26 | + | |
23 | 27 | | |
24 | | - | |
| 28 | + | |
25 | 29 | | |
26 | 30 | | |
27 | 31 | | |
| |||
0 commit comments