Victor Hsieh | 1fe51c4 | 2020-11-05 11:08:10 -0800 | [diff] [blame] | 1 | rust_defaults { |
| 2 | name: "authfs_defaults", |
| 3 | crate_name: "authfs", |
| 4 | srcs: [ |
Victor Hsieh | 88ac6ca | 2020-11-13 15:20:24 -0800 | [diff] [blame] | 5 | "src/main.rs", |
Victor Hsieh | 1fe51c4 | 2020-11-05 11:08:10 -0800 | [diff] [blame] | 6 | ], |
| 7 | edition: "2018", |
| 8 | rustlibs: [ |
Victor Hsieh | ec18456 | 2020-11-06 13:50:31 -0800 | [diff] [blame] | 9 | "libanyhow", |
Victor Hsieh | d1cb0d7 | 2020-11-06 13:49:55 -0800 | [diff] [blame] | 10 | "libauthfs_crypto_bindgen", |
Victor Hsieh | 88ac6ca | 2020-11-13 15:20:24 -0800 | [diff] [blame] | 11 | "libcfg_if", |
| 12 | "libfuse_rust", |
Victor Hsieh | 1fe51c4 | 2020-11-05 11:08:10 -0800 | [diff] [blame] | 13 | "liblibc", |
Victor Hsieh | 88ac6ca | 2020-11-13 15:20:24 -0800 | [diff] [blame] | 14 | "libstructopt", |
Victor Hsieh | d1cb0d7 | 2020-11-06 13:49:55 -0800 | [diff] [blame] | 15 | "libthiserror", |
Victor Hsieh | 1fe51c4 | 2020-11-05 11:08:10 -0800 | [diff] [blame] | 16 | ], |
ThiƩbaud Weksteen | 858a928 | 2021-01-12 12:02:37 +0100 | [diff] [blame] | 17 | target: { |
| 18 | darwin: { |
| 19 | enabled: false, |
| 20 | }, |
| 21 | }, |
Victor Hsieh | d1cb0d7 | 2020-11-06 13:49:55 -0800 | [diff] [blame] | 22 | shared_libs: ["libcrypto"], |
Victor Hsieh | 9a0ee7e | 2021-01-11 15:00:10 -0800 | [diff] [blame] | 23 | defaults: ["crosvm_defaults"], |
Victor Hsieh | 1fe51c4 | 2020-11-05 11:08:10 -0800 | [diff] [blame] | 24 | } |
| 25 | |
Victor Hsieh | d1cb0d7 | 2020-11-06 13:49:55 -0800 | [diff] [blame] | 26 | // TODO(b/172687320): remove once there is a canonical bindgen. |
| 27 | rust_bindgen { |
| 28 | name: "libauthfs_crypto_bindgen", |
| 29 | wrapper_src: "src/crypto.hpp", |
| 30 | crate_name: "authfs_crypto_bindgen", |
| 31 | source_stem: "bindings", |
| 32 | shared_libs: [ |
| 33 | "libcrypto", |
| 34 | ], |
| 35 | bindgen_flags: ["--size_t-is-usize"], |
| 36 | cflags: ["-D BORINGSSL_NO_CXX"], |
Victor Hsieh | d1cb0d7 | 2020-11-06 13:49:55 -0800 | [diff] [blame] | 37 | } |
| 38 | |
Victor Hsieh | 88ac6ca | 2020-11-13 15:20:24 -0800 | [diff] [blame] | 39 | rust_binary { |
| 40 | name: "authfs", |
Victor Hsieh | 1fe51c4 | 2020-11-05 11:08:10 -0800 | [diff] [blame] | 41 | defaults: ["authfs_defaults"], |
| 42 | } |
| 43 | |
Victor Hsieh | ad46e0b | 2021-01-25 16:07:38 -0800 | [diff] [blame] | 44 | rust_test { |
| 45 | name: "authfs_device_test_src_lib", |
| 46 | defaults: ["authfs_defaults"], |
Victor Hsieh | ab293ee | 2021-01-29 17:28:25 -0800 | [diff] [blame] | 47 | test_suites: ["device-tests"], |
Victor Hsieh | ad46e0b | 2021-01-25 16:07:38 -0800 | [diff] [blame] | 48 | } |