libhardware_legacy is a VNDK lib and also used by LLNDK(libmediandk)
which means this lib can be double-loaded.
deps:
- libmediandk -> libmedia_jni -> libandroid_runtime -> libhardware_legacy
Bug: 121280180
Test: m -j
Change-Id: I169e6fe520edb4a6961a6452b22b49b9bfbdf823
We use "-Wexit-time-destructors" and "-fno-c++-static-destructors" flags
to make sure that no static variables are destroyed at exit time.
We do this to avoid the race condition between process exit and use of
static vars when calling acquire/release_wake_lock().
Bug: 117575503
Test: libpower_test
Change-Id: I16acfeb2412685e376d8bd1069c86f60f56d215a
This change routes libpower and libhardware_legacy to SystemSuspend service for
wake locks instead of /sys/power/wake_[un]lock.
Bug: 78888165
Bug: 115946999
Test: /sys/kernel/debug/suspend_stats shows that device suspends if left alone
Change-Id: Id4d392e13d06be6d86e3112dedeb6a57bb24c06f
* Remove unused local variable or suppress the warning.
Bug: 66996870
Test: build with WITH_TIDY=1
Change-Id: I4d7b4f2e9e7e6c60d8bfc209f47e6f1d33720165
As a VNDK/VNDK-SP module, Android.bp must have 'vndk' tag as well
as 'vendor_available: true'.
For a VNDK module, the 'vndk' tag has 'enabled: true'.
It will be installed system/lib(64)/vndk as a vendor variant.
For a VNDK-SP module, the 'vndk' tag has
'support_system_process: true' as well as 'enabled: true'.
It will be installed system/lib(64)/vndk-sp as a vendor variant.
Bug: 63866913
Test: build and boot with BOARD_VNDK_VERSION=current
Merged-In: I9b9d9c0a3f33e396e71167c055220b55380eb1b5
Change-Id: I9b9d9c0a3f33e396e71167c055220b55380eb1b5
(cherry picked from commit 5bed6372b8)
By setting vendor_available, the following may become true:
* a prebuilt library from this release may be used at runtime by
in a later releasse (by vendor code compiled against this release).
so this library shouldn't depend on runtime state that may change
in the future.
* this library may be loaded twice into a single process (potentially
an old version and a newer version). The symbols will be isolated
using linker namespaces, but this may break assumptions about 1
library in 1 process (your singletons will run twice).
Background:
This means that these modules may be built and installed twice --
once for the system partition and once for the vendor partition. The
system version will build just like today, and will be used by the
framework components on /system. The vendor version will build
against a reduced set of exports and libraries -- similar to, but
separate from, the NDK. This means that all your dependencies must
also mark vendor_available.
At runtime, /system binaries will load libraries from /system/lib*,
while /vendor binaries will load libraries from /vendor/lib*. There
are some exceptions in both directions -- bionic(libc,etc) and liblog
are always loaded from /system. And SP-HALs (OpenGL, etc) may load
/vendor code into /system processes, but the dependencies of those
libraries will load from /vendor until it reaches a library that's
always on /system. In the SP-HAL case, if both framework and vendor
libraries depend on a library of the same name, both versions will be
loaded, but they will be isolated from each other.
It's possible to compile differently -- reducing your source files,
exporting different include directories, etc. For details see:
https://android-review.googlesource.com/368372
None of this is enabled unless the device opts into the system/vendor
split with BOARD_VNDK_VERSION := current.
Bug: 36426473
Bug: 36079834
Bug: 37343006
Test: Android-aosp_arm.mk is the same before/after
Test: build.ninja is the same before/after
Test: build-aosp_arm.ninja is the same before/after
Test: attempt to compile with BOARD_VNDK_VERSION := current
Merged-In: I3f1e4986c5920b4a64768636cb0bc37fa602c7a7
Change-Id: I3f1e4986c5920b4a64768636cb0bc37fa602c7a7
Test: builds with BOARD_VNDK_VERSION := current
Test: (sanity) Boots and works on internal marlin.
Bug: 33241851
Bug: 29915755
Change-Id: Ic355174a67860afa13377bc9d8f0a140f59ec34e
This doesn't need utils/Log.h, only log/log.h (and liblog)
Bug: 33241851
Test: m -j libpower
Merged-In: I21b08203fad51902d4a0f6172b4321b8b701ec47
Change-Id: I21b08203fad51902d4a0f6172b4321b8b701ec47