blob: 6499cfea11b89af86ae9ffb1378958c3f2e07b23 [file] [log] [blame]
Maurice Lamf26f1372022-12-02 00:15:07 +00001## Steps for updating this crate
2
31. In order to run cargo2android, for this crate, the BoringSSL rust bindings first needs to be
4 built. Copy `googletest` to `boringssl`, which is needed to build the rust bindings
5
6 ```
7 $ cp -r external/googletest/googletest external/boringssl/src/third_party/
8 ```
92. Build the rust bindings (More information at
10 https://boringssl.googlesource.com/boringssl/+/HEAD/BUILDING.md)
11
12 ```
13 $ cd external/boringssl
14 $ mkdir build && cd build
15 $ cmake .. -DRUST_BINDINGS=x86_64-unknown-linux-gnu
16 $ make
17 ```
183. Run `tools/external_updater/updater.sh update rust/crates/openssl`. Cargo errors causing the
19 command to fail are expected (since the boringSSL crate is outside of the `openssl` directory,
20 redshell is not able to access it).
214. The repository should now be in a `tmp_auto_upgrade` branch, and the Android.bp will contain
22 some error message.
235. Run cargo2android
24
25 ```
26 $ cargo2android.py --config ./cargo2android.json
27 ```
286. Clean up the changes in external/boringssl repository, and double check that the resulting
29 Android.bp builds correctly by running `m libopenssl`.
307. Commit the changes and upload the CL.
318. `external/rust/crates/openssl-macros` should also be updated at the same time.