summaryrefslogtreecommitdiffstats
path: root/dynamic-layers/selinux/android-tools/android-tools/libunwind_mk_change_out_dir.patch
diff options
context:
space:
mode:
authorNisha Parrakat <nishaparrakat@gmail.com>2021-08-08 08:18:35 +0000
committerKhem Raj <raj.khem@gmail.com>2021-08-12 10:08:16 -0700
commit1f1d3812a10e5a20069545d3ec1e2ae034ab05af (patch)
tree8526dd017f373037618726fe20db169d8a561c31 /dynamic-layers/selinux/android-tools/android-tools/libunwind_mk_change_out_dir.patch
parenteb92914e31ff872c032155997c42ca8b6e6d82a3 (diff)
downloadmeta-clang-1f1d3812a10e5a20069545d3ec1e2ae034ab05af.tar.gz
upgrade of android-tools to 10.0.0.r36
An older version is present in the meta-oe layer. Took the old recipe and adapted it in the following way: --Deleted all the old patches that were applicable for old version. --Used all the makefiles that come with the new version directly from the source code, just modifying them to install output to a specific folder as below a)added rules_yocto.mk that will mimic the debian/rules b)modified the makefiles of the components to output to a common dir. c) Built boringssl crypto with the option -DOPENSSL_NO_ASM to solve the below errors libcrypto.so.0: undefined reference to `aes_hw_encrypt' libcrypto.so.0: undefined reference to `aes_hw_set_encrypt_key' libcrypto.so.0: undefined reference to `gcm_gmult_v8' libcrypto.so.0: undefined reference to `gcm_init_v8' libcrypto.so.0: undefined reference to `sha256_block_data_order' libcrypto.so.0: undefined reference to `aes_hw_ctr32_encrypt_blocks' libcrypto.so.0: undefined reference to `aes_hw_cbc_encrypt' libcrypto.so.0: undefined reference to `vpaes_decrypt' libcrypto.so.0: undefined reference to `vpaes_encrypt' libcrypto.so.0: undefined reference to `gcm_gmult_neon' libcrypto.so.0: undefined reference to `sha1_block_data_order' libcrypto.so.0: undefined reference to `sha512_block_data_order' libcrypto.so.0: undefined reference to `gcm_init_neon' libcrypto.so.0: undefined reference to `aes_hw_set_decrypt_key' libcrypto.so.0: undefined reference to `vpaes_set_decrypt_key' libcrypto.so.0: undefined reference to `gcm_ghash_neon' libcrypto.so.0: undefined reference to `bn_mul_mont' libcrypto.so.0: undefined reference to `aes_hw_decrypt' libcrypto.so.0: undefined reference to `gcm_ghash_v8' libcrypto.so.0: undefined reference to `vpaes_cbc_encrypt' libcrypto.so.0: undefined reference to `ChaCha20_ctr32' libcrypto.so.0: undefined reference to `vpaes_ctr32_encrypt_blocks' libcrypto.so.0: undefined reference to `vpaes_set_encrypt_key' Attention : https://github.com/grpc/grpc/issues/9440 d) compiled android compatible version of libunwind to be used to build libbacktrace e) REQUIRES meta-selinux for libselinux, thus added it to BBFILES_DYNAMIC of this layer. f) checked compilation and packaging for for x86_64 and aarch64 g) UNTESTED android-tools-adbd.service , couldn't find how to build adbd that is needed by the service with the new version of android-tools. At present the service is still packaged but may not work. h) tested the adb and fastboot on the core-image-minimal by including the android-tools in the image and ran the commands with 'help' Signed-off-by: Nisha Parrakat <Nisha.Parrakat@kpit.com> Signed-off-by: Nisha Parrakat <nishaparrakat@gmail.com>
Diffstat (limited to 'dynamic-layers/selinux/android-tools/android-tools/libunwind_mk_change_out_dir.patch')
-rw-r--r--dynamic-layers/selinux/android-tools/android-tools/libunwind_mk_change_out_dir.patch47
1 files changed, 47 insertions, 0 deletions
diff --git a/dynamic-layers/selinux/android-tools/android-tools/libunwind_mk_change_out_dir.patch b/dynamic-layers/selinux/android-tools/android-tools/libunwind_mk_change_out_dir.patch
new file mode 100644
index 0000000..237d45c
--- /dev/null
+++ b/dynamic-layers/selinux/android-tools/android-tools/libunwind_mk_change_out_dir.patch
@@ -0,0 +1,47 @@
1patching libundwind to build in yocto environment.
2
3Changes include:
4Introduced an output folder which will keep all the outputs from the
5android-tools.
6
7Adding an include file that is setting the common flags.
8Changed the cppflag to include the headers from other components
9of android-tools
10
11Modified LDflags so that the libraries that are coming from other android-tools
12are searched in the output folder.
13
14Modified the build rule so that it outputs the binary to the OUT_DIR
15
16Passing the architecture details($CPU)from the recipe.
17
18Signed-off-by: Nisha Parrakat <Nisha.Parrakat@kpit.com>
19
20Upstream-Status: Pending
21
22--- git/external/libunwind/debian/libunwind.mk 2021-05-22 02:29:52.950324653 +0000
23+++ git/external/libunwind/debian/libunwind.mk 2021-05-22 02:30:48.535322846 +0000
24@@ -1,4 +1,4 @@
25-include debian/detect_arch.mk
26+include ../../rules_yocto.mk
27
28 ARCH_SOURCES = is_fpreg.c \
29 regname.c \
30@@ -131,10 +131,12 @@
31 CPPFLAGS += -Iinclude -Isrc $($(CPU)_INCLUDES) -Idebian/include
32 LDFLAGS += -shared -Wl,-soname,$(NAME).so.0 \
33 -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android \
34- -lpthread -nostdlib -lc -lgcc -Ldebian/out -l7z
35+ -lpthread -nostdlib -lc -lgcc -l7z
36
37 build: $(SOURCES)
38- mkdir --parents debian/out
39- ln -s /usr/lib/p7zip/7z.so debian/out/lib7z.so
40- $(CC) $^ -o debian/out/$(NAME).so.0 $(CFLAGS) $(CPPFLAGS) $(LDFLAGS)
41- ln -s $(NAME).so.0 debian/out/$(NAME).so
42+ mkdir --parents $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/
43+ mkdir --parents $(OUT_DIR)/usr/include/android/libunwind
44+ $(CC) $^ -o $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so.0 $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -Wno-header-guard -Wno-absolute-value
45+ ln -s $(NAME).so.0 $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so
46+ cp -r include/* debian/include/* $(OUT_DIR)/usr/include/android/libunwind/
47+