Commit graph

32 commits

Author SHA1 Message Date
R0rt1z2
118bd4294f
compat: Add libutils shim
* This is required because some old libraries still rely on the
  strncpy16() function.

Change-Id: I77da329d1296d946f43ffe6708444b1d25607342
2023-07-19 21:32:21 +02:00
R0rt1z2
895a614971 compat: Provide shim with IPermissionController stubs
* All the IPermissionController related functions are guarded by
  `if !defined(__ANDROID_VNDK__)` [1], meaning they're not fully
  accessible to vendors.

* Since we know these are mainly used to check whether an app or
  process has a required permission, simply provide an stub that
  returns true no matter what the permission / caller are.

- [1]: https://github.com/LineageOS/android_frameworks_native/blob/lineage-20.0/libs/binder/IServiceManager.cpp#L170

Change-Id: I898bf8eb577faecb8bc0f007498b835816dddb93
2023-07-18 18:10:41 +00:00
Sebastiano Barezzi
5c54e69ef0
compat: Add libtinyxml2 shim
Change-Id: I2bc7963086f7f5df453e135819ed8b28c4d6a0d5
2023-07-18 12:10:42 +02:00
R0rt1z2
844cbbb2d3
compat: Add some HIDL interfaces types shims
* toString is a static function, do some magic to export it to the
  vtable

Change-Id: Iae53ef6e9c02c526218ae8b8de981130473b9f67
2023-07-17 21:53:55 +02:00
Sebastiano Barezzi
ca34347089
compat: Keep only one copy of clang-format style
* When --style=file is specified, clang-format will look for a
  .clang-format on file's parent dirs automatically

Change-Id: If94fe4915cd434b3f5901b8830cbdb90976ae4b7
2023-07-17 20:51:56 +02:00
R0rt1z2
efa7303881
libui: Add android::GraphicBufferMapper::lock shims
Change-Id: I9f4da2bb1260d53ec4bb6604a89e78c495ad539a
2023-07-17 20:51:56 +02:00
Sebastiano Barezzi
6be2ac19ee
libui: Move every symbol under extern C block
Change-Id: I19370532134f3ff84759177a1d6adcbd9da10a8d
2023-07-17 20:51:56 +02:00
Sebastiano Barezzi
2318cd6f47
libui: Fix android::GraphicBuffer::lock return value
Change-Id: I2c439c74d594959f1612c672ac685388a5386d4d
2023-07-17 20:51:56 +02:00
Ivan Vecera
d67ae54f8e compat: Fix ABI issues
Several constructor shims are implemented incorrectly because
they completely ignore the fact that constructors have 'this-call'
calling convention and should pass 'this ptr' as the first argument [1]
as well as its return value, at least according ARM ABI [2].

Additionally android::SurfaceComposerClient::Transaction::apply(bool)
shim has void return value instead of status_t so the caller retrieves
random value.

[1] https://review.lineageos.org/c/LineageOS/android_device_xiaomi_sdm710-common/+/360011/comments/eb6600df_3e2fb434
[2] 617079d8a0/cppabi32/cppabi32.rst (L576)

Change-Id: I7b14b5d3ca6008c1e4b3f5fcbaece5021b3cbb82
Signed-off-by: Ivan Vecera <ivan@cera.cz>
2023-06-26 15:20:07 +02:00
LuK1337
e386376f9c
compat: Add libcamera_metadata shim for stripping out system camera cap
Change-Id: I8f7772fc9ec15a00c4b630866aa7fc162a52c1aa
2022-11-25 22:27:26 +02:00
Nolen Johnson
e4fbaa32d3 compat: Provide a libip_checksum shim
* * In Android T, AOSP moved `libnetutils` to an APEX that is inaccessible
  to the vendor namespace - and it can't be built to vendor in any
  treble-compliant way.

* Our `wfc-pkt-router` blob lives on vendor, and relies on `libnetutils.so`.

* Upon further analysis, we only reply on a few checksum related functions,
  such as the symbol `ipv4_pseudo_header_checksum`, which lives in the (now)
  staticly included dependency of `libnetutils.so`, `libip_checksum`.

* To work around this, we enabled building `libip_checksum` as a stand-alone
  vendor_available library called `libip_checksum_shim.so`, and `patchelf`
  `wfc-pkt-router` to depend on `libipp_checksum_shim.so`.

Change-Id: I7dff9ec6c8ff146f6090e9519ece7844b4a057eb
2022-11-10 15:19:21 -05:00
Nolen Johnson
f25f2ec083 compat: libcutils_shim: Make it vendor_available
Change-Id: I9796ab3db63988837e843105ebec93cc27a6c194
2022-11-03 00:13:35 -04:00
Michael Bestas
ce8f7cfed4
libgui: Add SurfaceComposerClient shim
Change-Id: Ie0ce6a17cebd079584a3121524eb79bf64a88df3
2022-11-02 04:25:13 +02:00
Nolen Johnson
fd79adbaeb compat: libui_shim: Allow building 32-bit versions
* msm8998 camera stacks need this.

Change-Id: I87b69209bf73120e11d7d5c3b686d3b0a989abb9
2022-11-02 01:01:32 +01:00
Nolen Johnson
eb2e7226b8 compat: libui_shim: Make vendor available
* msm8998 camera stacks need this.

Change-Id: I5046eab287e3f14f024cd88293dfe4c5279f6667
2022-11-02 02:01:26 +02:00
Arian
861345fd7f compat: libpiex_shim: Improve shim
Change-Id: Id11965102d7d5dce50f989c99810cda6a43aa1ec
2022-11-01 10:35:17 +00:00
daniml3
b6e1983240
compat: Add GetPreviewImageData shim for camera
Signed-off-by: daniml3 <daniel@danielml.dev>
Change-Id: Iad9d37b992775b6d7b9b52ed4637c70fd13ede7f
2022-11-01 15:23:42 +05:30
Ethan Chen
f0f1e67f41 compat: Add shim for Fence destructor
* This was replaced with a default destructor which has no visible
  linkage. No-op the destructor call and hope the actual destructor is
  called from underneath.

Change-Id: Id039e916c24959e9f60391bc10886df878f4d265
2022-10-27 17:21:16 +01:00
Ethan Chen
e2f889da0b compat: Add shim for libbase LogMessage functions
Change-Id: I4d1db75e5407586c9b69d94803af0ef9a9a91037
2022-10-19 11:40:51 +02:00
Nolen Johnson
51e834f21f libcutils_shim: jstring: Import strcpy8to16 definition
Change-Id: Ieb1d53d667aafa333dc2b846f81bf3c51f854cd1
2022-09-21 13:10:09 -04:00
LuK1337
c3f51682eb libgui/libui: Switch to SPDX license identifiers
Change-Id: Iaf4cbd3ea8cdbf74bff42466a51f81af88b82c81
2022-09-21 18:20:58 +02:00
LuK1337
8c9cff232b libgui/libui: Add and run clang-format
Change-Id: I34ad46b99904e48be1a273486a42e0dc7edea48f
2022-09-21 18:19:26 +02:00
LuK1337
039f81353b libgui: Remove namespace android
Change-Id: I8cb93369d22ffc2fb61f58c570580b8c19898bfd
2022-09-21 18:19:26 +02:00
LuK1337
edf122ea20 Add missing commas to Android.bp
Change-Id: I5ebb4758e4609fcb971a3d507829f0bc91db8dcd
2022-09-21 18:19:26 +02:00
Nolen Johnson
12973d5ad4 Provide a shim for libui
Co-authored-by: Erfan Abdi <erfangplus@gmail.com>
Co-authored-by: Quallenauge <Hamsi2k@freenet.de>
Change-Id: I27d511340f0f2497bbeb2b046c18b66606610040
2022-09-21 16:42:55 +01:00
Jan Altensen
20c7906710 Provide shim for android_memset32
* memset32.S and android_memset.S taken from Q where this still existed.

Change-Id: Iaf59389e32b87d181f6dccc34e9174da25171f4f
2022-09-21 16:26:12 +01:00
dianlujitao
004fc53230 Provide shim for libcutils strdup8to16/strdup16to8
Co-authored-by: Demon000 <demonsingur@gmail.com>
Co-authored-by: Arian <arian.kulmer@web.de>
Change-Id: Ic5d732f3e98ba45c886db9646d6ef30eb0d42bf4
2022-09-21 16:25:02 +01:00
Erfan Abdi
aae0cea26d Provide libgui{,_vendor} shim for 4.4/4.9-era camera blobs
Signed-off-by: Jarl-Penguin <jarlpenguin@outlook.com>
Change-Id: I5e622e68422f5c4da13c0752a7eb3f4b20ddae49
2022-09-21 12:08:45 +01:00
Sebastiano Barezzi
572788148f
Add android.hidl.{base|manager}@1.0 shim
Some qcom blobs still depend on it.

Change-Id: I5457ebbadd95e4c43af4f4dd2e1a1413a241d865
2022-09-15 20:45:53 +03:00
Michael Bestas
65e78e1596
Add aidl shim libraries for S compatibility
T changed *ndk_platform.so to *ndk.so.
Add shim libraries to make old blobs work again.

Change-Id: I77074f1fadbd44a63b6b9e9822632064d164ef94
2022-09-15 20:45:15 +03:00
Michael Bestas
793b874c4d
Add libavservices_minijail_vendor shim
This has been removed in frameworks/av commit
a03603523a5ec96c75153d39a2369c306f88fa70
but older vendor omx blobs still depend on it.

Change-Id: I49f7756a1fd3c76f650a1ae5c22053553c8cfd9d
2022-09-13 03:58:05 +03:00
Michael Bestas
e21e048ef8 Initial empty repository 2022-09-13 02:29:55 +02:00