From 1fe91a79985a01d65d3a51d3f44e11b02c4aa60c Mon Sep 17 00:00:00 2001 From: "Priyanka Advani (xWF)" Date: Wed, 26 Feb 2025 11:37:40 -0800 Subject: Revert "cc: Add cc_rustlibs_for_make to bundle rust_ffi_static" Revert submission 3469976-ICU4X-in-bionic Reason for revert: Droidmonitor created revert due to b/399425763. Will be verifying through ABTD before submission. Reverted changes: /q/submissionid:3469976-ICU4X-in-bionic Change-Id: Id8e9b68c2e44bbdd363d303a794041dc370f29fc --- rust/library_test.go | 39 --------------------------------------- 1 file changed, 39 deletions(-) (limited to 'rust') diff --git a/rust/library_test.go b/rust/library_test.go index 6cc4f2517..6db95253f 100644 --- a/rust/library_test.go +++ b/rust/library_test.go @@ -426,45 +426,6 @@ func TestRustFFIExportedIncludes(t *testing.T) { android.AssertStringDoesContain(t, "cFlags for lib module", libfooStatic.Args["cFlags"], " -Irust_includes ") } -// Make sure cc_rustlibs_for_make has the expected behavior, and that -// cc_library_static does as well. -// This is here instead of cc/library_test.go because the test needs to -// define a rust_ffi module which can't be done in soong-cc to avoid the -// circular dependency. -func TestCCRustlibsForMake(t *testing.T) { - t.Parallel() - result := testRust(t, ` - rust_ffi_static { - name: "libbar", - srcs: ["foo.rs"], - crate_name: "bar", - export_include_dirs: ["rust_includes"], - host_supported: true, - } - - cc_rustlibs_for_make { - name: "libmakerustlibs", - whole_static_libs: ["libbar"], - } - - cc_library_static { - name: "libccstatic", - whole_static_libs: ["libbar"], - } - `) - - libmakerustlibs := result.ModuleForTests(t, "libmakerustlibs", "android_arm64_armv8-a_static").MaybeRule("rustc") - libccstatic := result.ModuleForTests(t, "libccstatic", "android_arm64_armv8-a_static").MaybeRule("rustc") - - if libmakerustlibs.Output == nil { - t.Errorf("cc_rustlibs_for_make is not generating a Rust staticlib when it should") - } - - if libccstatic.Output != nil { - t.Errorf("cc_library_static is generating a Rust staticlib when it should not") - } -} - func TestRustVersionScript(t *testing.T) { ctx := testRust(t, ` rust_library { -- cgit v1.2.3-59-g8ed1b