Enable libandroid_log_sys for host

libandroid_log_sys is used when target_os is set to android. Previously
the os type was used only when building for the device target. But with
the introduction of the Linux/ARM host support, the os type is used for
the cross-compiling host target as well. This is because the rust
compiler doesn't yet support 'aarch64-linux' (without the -android
suffix) for the Linux/ARM64 host target. It does support
aarch-unknown-linux-gnu, but we can't use it due to the glibc
dependency which we won't add for the host target; we use bionic.
Until we add aarch64-linux to the supported target list, we
have to use aarch64-linux-android for the cross-compiling host target.

libandroid_log_sys is enabled for host to satisfy the dependencies
from other rust binaries (e.g. crosvm) tht are built for the host
target.

Note that the module is still disabled for linux_glibc target because
the build system doesn't add liblog as a dependency for the target.

Bug: 159685774
Test: HOST_CROSS_OS=linux_bionic HOST_CROSS_ARCH=arm64 m crosvm
Change-Id: I70437a6ba1d14cdd02c1950d45b232db41a47368
1 file changed
tree: 24d901185a1747f33b107ba81703b38d70e49fd8
  1. src/
  2. .cargo_vcs_info.json
  3. .gitignore
  4. Android.bp
  5. Cargo.toml
  6. Cargo.toml.orig
  7. LICENSE-APACHE
  8. LICENSE-MIT
  9. METADATA
  10. MODULE_LICENSE_APACHE2
  11. OWNERS
  12. README.md
README.md

Bindings to Android log Library

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.