diff options
Diffstat (limited to 'patches/Android.bp.patch')
-rw-r--r-- | patches/Android.bp.patch | 61 |
1 files changed, 40 insertions, 21 deletions
diff --git a/patches/Android.bp.patch b/patches/Android.bp.patch index f6a32f4..48c6dee 100644 --- a/patches/Android.bp.patch +++ b/patches/Android.bp.patch @@ -2,7 +2,7 @@ diff --git a/Android.bp b/Android.bp index aced8a6..578cc68 100644 --- a/Android.bp +++ b/Android.bp -@@ -43,25 +43,38 @@ cc_library_headers { +@@ -43,26 +43,39 @@ cc_library_headers { min_sdk_version: "29", } @@ -13,6 +13,7 @@ index aced8a6..578cc68 100644 stem: "libquiche", host_supported: true, crate_name: "quiche", + cargo_env_compat: true, srcs: ["src/lib.rs"], edition: "2018", features: [ @@ -46,12 +47,13 @@ index aced8a6..578cc68 100644 "libcrypto", "libssl", ], -@@ -69,52 +82,20 @@ rust_ffi_shared { +@@ -69,54 +82,20 @@ rust_ffi_shared { rust_library { name: "libquiche", - host_supported: true, - crate_name: "quiche", +- cargo_env_compat: true, - srcs: ["src/lib.rs"], - edition: "2018", - features: [ @@ -86,6 +88,7 @@ index aced8a6..578cc68 100644 - stem: "libquiche", - host_supported: true, - crate_name: "quiche", +- cargo_env_compat: true, - srcs: ["src/lib.rs"], - edition: "2018", - features: [ @@ -105,17 +108,28 @@ index aced8a6..578cc68 100644 + "libcrypto_static", "libssl", ], + apex_available: [ +@@ -111,17 +90,13 @@ rust_library_rlib { + min_sdk_version: "29", } -@@ -127,7 +108,7 @@ rust_defaults { + +-rust_test { +- name: "quiche_test_src_lib", +- host_supported: true, ++rust_defaults { ++ name: "quiche_test_defaults", + crate_name: "quiche", + cargo_env_compat: true, + srcs: ["src/lib.rs"], + test_suites: ["general-tests"], auto_gen_config: true, +- test_options: { +- unit_test: true, +- }, edition: "2018", features: [ -- "boringssl-vendored", -+ "boringssl", - "default", - ], - rustlibs: [ -@@ -139,10 +120,6 @@ rust_defaults { + "boringssl", +@@ -136,10 +132,6 @@ rust_test { "libring", "liburl", ], @@ -126,25 +140,30 @@ index aced8a6..578cc68 100644 data: [ "examples/cert.crt", "examples/cert.key", -@@ -151,11 +134,21 @@ rust_test_host { - test_options: { - unit_test: true, - }, +@@ -149,3 +118,26 @@ rust_test { + "examples/rootca.crt", + ], + } ++ ++rust_test_host { ++ name: "quiche_host_test_src_lib", ++ defaults: ["quiche_test_defaults"], ++ test_options: { ++ unit_test: true, ++ }, + shared_libs: [ + "libcrypto", + "libssl", + ], - } - - rust_test { - name: "quiche_device_test_src_lib", - defaults: ["quiche_test_defaults"], ++} ++ ++rust_test { ++ name: "quiche_device_test_src_lib", ++ defaults: ["quiche_test_defaults"], + // To run this test in R platform, it's required to statically link + // libcrypto and libssl. + static_libs: [ + "libcrypto_static", + "libssl", + ], - } - - // dependent_library ["feature_list"] ++} |