From 33604a56dc35a04c6b4233f2030cebc60e8dcfe9 Mon Sep 17 00:00:00 2001 From: Etienne Cordonnier Date: Fri, 3 Mar 2023 11:26:18 +0100 Subject: android-tools: make it work with devtool devtool modify android-tools was failing with an error: - regenerate patches in the git format working with devtool - add debian patches to yocto instead of applying them manually with do_unpack_and_patch_debian, to make it work with devtool Signed-off-by: Etienne Cordonnier --- ...hing-adb.mk-to-build-in-yocto-environment.patch | 62 +++++++++++++++++++ ...odifications-to-make-it-build-in-yocto-en.patch | 56 ++++++++++++++++++ ...003-socket.h-removing-dependency-of-gtest.patch | 61 +++++++++++++++++++ ...fastboot.mk-to-build-in-yocto-environment.patch | 63 ++++++++++++++++++++ ...n-t-use-sparse_file_import_auto-in-load_b.patch | 54 +++++++++++++++++ ...modifications-to-make-it-build-in-yocto-e.patch | 45 ++++++++++++++ ...tils.mk-modifications-to-make-it-build-in.patch | 51 ++++++++++++++++ ...odifications-to-make-it-build-in-yocto-en.patch | 41 +++++++++++++ ...img2simg.mk-to-build-in-yocto-environment.patch | 52 ++++++++++++++++ ...simg2img.mk-to-build-in-yocto-environment.patch | 52 ++++++++++++++++ ...g-liblog.mk-to-build-in-yocto-environment.patch | 53 +++++++++++++++++ ...ibsparse.mk-to-build-in-yocto-environment.patch | 58 ++++++++++++++++++ ...bziparchive.mk-to-build-in-yocto-environm.patch | 59 ++++++++++++++++++ ...bbacktrace.mk-to-build-in-yocto-environme.patch | 69 ++++++++++++++++++++++ ...Use-namespace-std-to-compile-libbacktrace.patch | 32 ++++++++++ 15 files changed, 808 insertions(+) create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0001-patching-adb.mk-to-build-in-yocto-environment.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0002-libadb.mk-modifications-to-make-it-build-in-yocto-en.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0003-socket.h-removing-dependency-of-gtest.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0004-patching-fastboot.mk-to-build-in-yocto-environment.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0005-fastboot-don-t-use-sparse_file_import_auto-in-load_b.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0006-libbase.mk-modifications-to-make-it-build-in-yocto-e.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0007-libcrypto_utils.mk-modifications-to-make-it-build-in.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0008-libcutils-modifications-to-make-it-build-in-yocto-en.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0009-patching-img2simg.mk-to-build-in-yocto-environment.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0010-patching-simg2img.mk-to-build-in-yocto-environment.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0011-patching-liblog.mk-to-build-in-yocto-environment.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0012-patching-libsparse.mk-to-build-in-yocto-environment.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0013-patching-libziparchive.mk-to-build-in-yocto-environm.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0014-patching-libbacktrace.mk-to-build-in-yocto-environme.patch create mode 100644 dynamic-layers/selinux/android-tools/android-tools/core/0015-Use-namespace-std-to-compile-libbacktrace.patch (limited to 'dynamic-layers/selinux/android-tools/android-tools/core') diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0001-patching-adb.mk-to-build-in-yocto-environment.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0001-patching-adb.mk-to-build-in-yocto-environment.patch new file mode 100644 index 0000000..d2ba525 --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0001-patching-adb.mk-to-build-in-yocto-environment.patch @@ -0,0 +1,62 @@ +From d133fc2c71fb6b0358af453b03bcb6d1874e902a Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 12:25:40 +0100 +Subject: [PATCH 01/15] patching adb.mk to build in yocto environment. + +Changes include: +Introduced an output folder which will keep all the outputs from the +android-tools. + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary to the OUT_DIR + +Signed-off-by: Nisha Parrakat + +Upstream-Status: Pending +--- + debian/adb.mk | 12 +++++++----- + 1 file changed, 7 insertions(+), 5 deletions(-) + +diff --git a/debian/adb.mk b/debian/adb.mk +index 8dbacf9a..97c9d6ca 100644 +--- a/debian/adb.mk ++++ b/debian/adb.mk +@@ -1,3 +1,4 @@ ++include ../../rules_yocto.mk + NAME = adb + + SOURCES = client/adb_client.cpp \ +@@ -12,10 +13,10 @@ SOURCES = client/adb_client.cpp \ + + SOURCES := $(foreach source, $(SOURCES), adb/$(source)) + CXXFLAGS += -std=gnu++2a +-CPPFLAGS += -Iinclude -Iadb -Ibase/include \ ++CPPFLAGS += -Iinclude -Iadb -Ibase/include -I$(OUT_DIR)/usr/include/ \ + -DADB_VERSION='"$(DEB_VERSION)"' -DADB_HOST=1 -D_GNU_SOURCE +-LDFLAGS += -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android -Wl,-rpath-link=. \ +- -lpthread -L. -ladb -lbase ++LDFLAGS += -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android -Wl,-rpath-link=$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/ \ ++ -lpthread -L$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/ -ladb -lbase + + # -latomic should be the last library specified + # https://github.com/android/ndk/issues/589 +@@ -24,7 +25,8 @@ ifneq ($(filter armel mipsel,$(DEB_HOST_ARCH)),) + endif + + build: $(SOURCES) +- $(CXX) $^ -o adb/$(NAME) $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) ++ mkdir --parents $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/adb ++ $(CXX) $^ -o $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/adb/$(NAME) $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) + + clean: +- $(RM) adb/$(NAME) ++ $(RM) $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/adb/$(NAME) +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0002-libadb.mk-modifications-to-make-it-build-in-yocto-en.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0002-libadb.mk-modifications-to-make-it-build-in-yocto-en.patch new file mode 100644 index 0000000..1281caa --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0002-libadb.mk-modifications-to-make-it-build-in-yocto-en.patch @@ -0,0 +1,56 @@ +From f802e7685cfbdd66d74da2975b3a1c6d77f1a2de Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 12:28:10 +0100 +Subject: [PATCH 02/15] libadb.mk: modifications to make it build in yocto + environment + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary to the OUT_DIR + +Signed-off-by: Nisha Parrakat +--- + debian/libadb.mk | 11 ++++++----- + 1 file changed, 6 insertions(+), 5 deletions(-) + +diff --git a/debian/libadb.mk b/debian/libadb.mk +index ae240c98..db5da353 100644 +--- a/debian/libadb.mk ++++ b/debian/libadb.mk +@@ -1,3 +1,4 @@ ++include ../../rules_yocto.mk + NAME := libadb + + LIBADB_SRC_FILES := \ +@@ -43,18 +44,18 @@ CPPFLAGS += \ + -Ibase/include \ + -Idiagnose_usb/include \ + -Ilibcrypto_utils/include \ +- -Iinclude \ ++ -Iinclude -I$(OUT_DIR)/usr/include \ + -DPLATFORM_TOOLS_VERSION='"$(PLATFORM_TOOLS_VERSION)"' \ + -DADB_HOST=1 -DADB_VERSION='"$(DEB_VERSION)"' + + LDFLAGS += -shared -Wl,-soname,$(NAME).so.0 \ + -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android \ +- -L/usr/lib/$(DEB_HOST_MULTIARCH)/android -lcrypto \ +- -lpthread -L. -lbase -lcutils -lcrypto_utils -lusb-1.0 ++ -L$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android -lcrypto \ ++ -lpthread -lbase -lcutils -lcrypto_utils -lusb-1.0 + + $(NAME).so: $(SOURCES) +- $(CXX) $^ -o $(NAME).so.0 $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) +- ln -s $(NAME).so.0 $(NAME).so ++ $(CXX) $^ -o $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so.0 $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) ++ ln -sf $(NAME).so.0 $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so + + transport_mdns_unsupported.cpp: + echo 'void init_mdns_transport_discovery(void) {}' > transport_mdns_unsupported.cpp +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0003-socket.h-removing-dependency-of-gtest.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0003-socket.h-removing-dependency-of-gtest.patch new file mode 100644 index 0000000..56c25ea --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0003-socket.h-removing-dependency-of-gtest.patch @@ -0,0 +1,61 @@ +From 4fdd086c2e9c85bc5a367a861696191e190cebc9 Mon Sep 17 00:00:00 2001 +From: Nisha Parrakat +Date: Thu, 2 Mar 2023 17:20:48 +0100 +Subject: [PATCH 03/15] socket.h: removing dependency of gtest + +Removed the dependency of gtest on the build of fastboot binary. +Fixes below error + +In file included from fastboot/fastboot.cpp:70: +| In file included from fastboot/tcp.h:36: +| fastboot/socket.h:43:10: fatal error: 'gtest/gtest_prod.h' file not found +| #include +| ^~~~~~~~~~~~~~~~~~~~ +| 1 error generated. +| In file included from fastboot/socket.cpp:29: +| fastboot/socket.h:43:10: fatal error: 'gtest/gtest_prod.h' file not found +| #include +| ^~~~~~~~~~~~~~~~~~~~ +| 1 error generated. +| In file included from fastboot/tcp.cpp:29: +| In file included from fastboot/tcp.h:36: +| fastboot/socket.h:43:10: fatal error: 'gtest/gtest_prod.h' file not found +| #include +| ^~~~~~~~~~~~~~~~~~~~ +| 1 error generated. +| In file included from fastboot/udp.cpp:31: +| In file included from fastboot/udp.h:34: +| fastboot/socket.h:43:10: fatal error: 'gtest/gtest_prod.h' file not found +| #include +| ^~~~~~~~~~~~~~~~~~~~ +| 1 error generated. + +Signed-off-by: Nisha Parrakat +--- + fastboot/socket.h | 3 --- + 1 file changed, 3 deletions(-) + +diff --git a/fastboot/socket.h b/fastboot/socket.h +index e791f2c8..671fc115 100644 +--- a/fastboot/socket.h ++++ b/fastboot/socket.h +@@ -40,7 +40,6 @@ + + #include + #include +-#include + + // Socket interface to be implemented for each platform. + class Socket { +@@ -119,8 +118,6 @@ class Socket { + socket_send_buffers_function_ = &socket_send_buffers; + + private: +- FRIEND_TEST(SocketTest, TestTcpSendBuffers); +- FRIEND_TEST(SocketTest, TestUdpSendBuffers); + + DISALLOW_COPY_AND_ASSIGN(Socket); + }; +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0004-patching-fastboot.mk-to-build-in-yocto-environment.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0004-patching-fastboot.mk-to-build-in-yocto-environment.patch new file mode 100644 index 0000000..82ec560 --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0004-patching-fastboot.mk-to-build-in-yocto-environment.patch @@ -0,0 +1,63 @@ +From e826f68c68e05b0f5cc3b3c10d7d9e4deb135114 Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:14:15 +0100 +Subject: [PATCH 04/15] patching fastboot.mk to build in yocto environment. + +Changes include: +Introduced an output folder which will keep all the outputs from the +android-tools. + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary to the OUT_DIR + +Signed-off-by: Nisha Parrakat + +Upstream-Status: Pending +--- + debian/fastboot.mk | 12 +++++++----- + 1 file changed, 7 insertions(+), 5 deletions(-) + +diff --git a/debian/fastboot.mk b/debian/fastboot.mk +index d1aba626..e75fa87c 100644 +--- a/debian/fastboot.mk ++++ b/debian/fastboot.mk +@@ -1,3 +1,4 @@ ++include ../../rules_yocto.mk + NAME = fastboot + fastboot_SOURCES = \ + bootimg_utils.cpp \ +@@ -38,11 +39,11 @@ CPPFLAGS += \ + -Ifs_mgr/liblp/include \ + -I/usr/include/android/openssl \ + -Ilibsparse/include \ +- -Ilibziparchive/include ++ -Ilibziparchive/include -I$(OUT_DIR)/usr/include/ + LDFLAGS += -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android \ + -fuse-ld=gold \ +- -Wl,-rpath-link=. \ +- -L. -lziparchive -lsparse -lbase -lcutils -ladb -lcrypto -lext4_utils \ ++ -Wl,-rpath-link=$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android \ ++ -L$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android -lziparchive -lsparse -lbase -lcutils -ladb -lcrypto -lext4_utils \ + -L/usr/lib/$(DEB_HOST_MULTIARCH)/android \ + -l7z \ + +@@ -53,7 +54,8 @@ ifneq ($(filter armel mipsel,$(DEB_HOST_ARCH)),) + endif + + build: $(SOURCES) +- $(CXX) $^ -o fastboot/$(NAME) $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) ++ mkdir --parents $(OUT_DIR)/usr/bin/fastboot ++ $(CXX) $^ -o $(OUT_DIR)/usr/bin/fastboot/$(NAME) $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) + + clean: +- $(RM) fastboot/$(NAME) ++ $(RM) $(OUT_DIR)/usr/bin/fastboot/$(NAME) +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0005-fastboot-don-t-use-sparse_file_import_auto-in-load_b.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0005-fastboot-don-t-use-sparse_file_import_auto-in-load_b.patch new file mode 100644 index 0000000..d465ad6 --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0005-fastboot-don-t-use-sparse_file_import_auto-in-load_b.patch @@ -0,0 +1,54 @@ +From a4839f29e1286b0c53208a45b9c237d81021f829 Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:15:47 +0100 +Subject: [PATCH 05/15] fastboot: don't use sparse_file_import_auto() in + load_buf_fd() + +upstream commit taken as below Original Issue link https://android-review.googlesource.com/c/platform/system/core/+/1123485 + +Commit taken below: + +fastboot: don't use sparse_file_import_auto() in load_buf_fd() + +load_buf_fd() attempts to find the size of the file that it is about +to load by first calling sparse_file_import_auto() then using +sparse_file_len() upon success or falling back to the file size on the +filesystem on failure. + +This is problematic however as sparse_file_import_auto() creates a +sparse_file out of the normal file, but does not resparse it, so an +assertion fails during the sparse_file_len() call. + +This is fixed by using sparse_file_import() instead. This will fail +in the case that the file is not sparse and the call to +sparse_file_len() will be properly skipped. + +Bug: 140538105 +Test: flash blueline factory image with assertions enabled in + libsparse/sparse.cpp + +Change-Id: I0283be33563a3301ce5b09bde41105a20f91086c + +https://android.googlesource.com/platform/system/core/+/fbb9535aaea5ae4011f3c3edf4c00b27452f57ec +Upstream-Status: Backport [commit fbb9535aaea5ae4011f3c3edf4c00b27452f57ec] +Signed-off-by: Nisha Parrakat +--- + fastboot/fastboot.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/fastboot/fastboot.cpp b/fastboot/fastboot.cpp +index 3b7b5571..0ae9402e 100644 +--- a/fastboot/fastboot.cpp ++++ b/fastboot/fastboot.cpp +@@ -869,7 +869,7 @@ static bool load_buf_fd(int fd, struct fastboot_buffer* buf) { + return false; + } + +- if (sparse_file* s = sparse_file_import_auto(fd, false, false)) { ++ if (sparse_file* s = sparse_file_import(fd, false, false)) { + buf->image_size = sparse_file_len(s, false, false); + sparse_file_destroy(s); + } else { +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0006-libbase.mk-modifications-to-make-it-build-in-yocto-e.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0006-libbase.mk-modifications-to-make-it-build-in-yocto-e.patch new file mode 100644 index 0000000..6211f04 --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0006-libbase.mk-modifications-to-make-it-build-in-yocto-e.patch @@ -0,0 +1,45 @@ +From 22c7140dc170ecb26bde33fed4c9249b164f8d3c Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:19:08 +0100 +Subject: [PATCH 06/15] libbase.mk: modifications to make it build in yocto + environment + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary to the OUT_DIR + +Signed-off-by: Nisha Parrakat +--- + debian/libbase.mk | 8 +++++--- + 1 file changed, 5 insertions(+), 3 deletions(-) + +diff --git a/debian/libbase.mk b/debian/libbase.mk +index 80da48f3..e6c3e365 100644 +--- a/debian/libbase.mk ++++ b/debian/libbase.mk +@@ -1,3 +1,4 @@ ++include ../../rules_yocto.mk + NAME = libbase + SOURCES = \ + chrono_utils.cpp \ +@@ -20,8 +21,9 @@ CPPFLAGS += -Iinclude -Ibase/include + LDFLAGS += -shared -Wl,-soname,$(NAME).so.0 + + build: $(SOURCES) +- $(CXX) $^ -o $(NAME).so.0 $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) +- ln -s $(NAME).so.0 $(NAME).so ++ $(CXX) $^ -o $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so.0 $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) ++ ln -sf $(NAME).so.0 $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so ++ cp -r base/include/* $(OUT_DIR)/usr/include/ + + clean: +- $(RM) $(NAME).so* ++ $(RM) $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so* +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0007-libcrypto_utils.mk-modifications-to-make-it-build-in.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0007-libcrypto_utils.mk-modifications-to-make-it-build-in.patch new file mode 100644 index 0000000..af92726 --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0007-libcrypto_utils.mk-modifications-to-make-it-build-in.patch @@ -0,0 +1,51 @@ +From cae154ec12a864ada8372b393fceb1d682c78c60 Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 14:38:05 +0100 +Subject: [PATCH 07/15] libcrypto_utils.mk: modifications to make it build in + yocto environment + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary and header to the OUT_DIR + +Signed-off-by: Nisha Parrakat +--- + debian/libcrypto_utils.mk | 14 ++++++++------ + 1 file changed, 8 insertions(+), 6 deletions(-) + +diff --git a/debian/libcrypto_utils.mk b/debian/libcrypto_utils.mk +index 3afd4124..80c52f30 100644 +--- a/debian/libcrypto_utils.mk ++++ b/debian/libcrypto_utils.mk +@@ -1,15 +1,17 @@ ++include ../../rules_yocto.mk + NAME:= libcrypto_utils + SOURCES := android_pubkey.c + SOURCES := $(foreach source, $(SOURCES), libcrypto_utils/$(source)) +-CPPFLAGS += -Ilibcrypto_utils/include -Iinclude ++CPPFLAGS += -Ilibcrypto_utils/include -Iinclude -I$(OUT_DIR)/usr/include + LDFLAGS += -shared -Wl,-soname,$(NAME).so.0 \ + -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android \ +- -L/usr/lib/$(DEB_HOST_MULTIARCH)/android \ +- -lcrypto -Wl,-z,defs ++ -L$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android \ ++ -l:libcrypto.so.0 -Wl,-z,defs + + build: $(SOURCES) +- $(CC) $^ -o $(NAME).so.0 $(CPPFLAGS) $(LDFLAGS) +- ln -s $(NAME).so.0 $(NAME).so ++ $(CC) $^ -o $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so.0 $(CPPFLAGS) $(LDFLAGS) ++ ln -sf $(NAME).so.0 $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so ++ cp -r libcrypto_utils/include/* $(OUT_DIR)/usr/include/ + + clean: +- $(RM) $(NAME).so* ++ $(RM) $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so* +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0008-libcutils-modifications-to-make-it-build-in-yocto-en.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0008-libcutils-modifications-to-make-it-build-in-yocto-en.patch new file mode 100644 index 0000000..b876229 --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0008-libcutils-modifications-to-make-it-build-in-yocto-en.patch @@ -0,0 +1,41 @@ +From 4af9cc9e93e5cb09583c0fedeccae3fa195dbe7b Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:26:08 +0100 +Subject: [PATCH 08/15] libcutils: modifications to make it build in yocto + environment +--- + debian/libcutils.mk | 10 ++++++---- + 1 file changed, 6 insertions(+), 4 deletions(-) + +diff --git a/debian/libcutils.mk b/debian/libcutils.mk +index 7cd18d87..bb45fb57 100644 +--- a/debian/libcutils.mk ++++ b/debian/libcutils.mk +@@ -1,3 +1,4 @@ ++include ../../rules_yocto.mk + NAME = libcutils + + # copied from libcutils/Android.bp +@@ -50,14 +51,15 @@ CPPFLAGS += \ + -Iinclude \ + + LDFLAGS += -shared -Wl,-soname,$(NAME).so.0 \ +- -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android -lpthread -L. -llog -lbase ++ -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android -lpthread -L$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/ -llog -lbase + + build: $(COBJECTS) $(CXXOBJECTS) +- $(CXX) $^ -o $(NAME).so.0 $(LDFLAGS) +- ln -s $(NAME).so.0 $(NAME).so ++ $(CXX) $^ -o $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so.0 $(LDFLAGS) ++ ln -sf $(NAME).so.0 $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so ++ cp -r libcutils/include/cutils $(OUT_DIR)/usr/include/ + + clean: +- $(RM) $(CXXOBJECTS) $(COBJECTS) $(NAME).so* ++ $(RM) $(CXXOBJECTS) $(COBJECTS) $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so* + + $(COBJECTS): %.o: %.c + $(CC) $< -o $@ $(CFLAGS) $(CPPFLAGS) +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0009-patching-img2simg.mk-to-build-in-yocto-environment.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0009-patching-img2simg.mk-to-build-in-yocto-environment.patch new file mode 100644 index 0000000..4ecfa6f --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0009-patching-img2simg.mk-to-build-in-yocto-environment.patch @@ -0,0 +1,52 @@ +From bea40821d787ca31b38d5879fbf751be1dbea622 Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:33:30 +0100 +Subject: [PATCH 09/15] patching img2simg.mk to build in yocto environment. + +Changes include: +Introduced an output folder which will keep all the outputs from the +android-tools. + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary to the OUT_DIR + +Signed-off-by: Nisha Parrakat + +Upstream-Status: Pending +--- + debian/img2simg.mk | 11 ++++++----- + 1 file changed, 6 insertions(+), 5 deletions(-) + +diff --git a/debian/img2simg.mk b/debian/img2simg.mk +index f1036cef..94772381 100644 +--- a/debian/img2simg.mk ++++ b/debian/img2simg.mk +@@ -1,13 +1,14 @@ ++include ../../rules_yocto.mk + NAME = img2simg + SOURCES = img2simg.cpp + SOURCES := $(foreach source, $(SOURCES), libsparse/$(source)) + CPPFLAGS += -Ilibsparse/include -Iinclude -std=gnu++17 +-LDFLAGS += -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android \ +- -Wl,-rpath-link=. \ +- -L. -lsparse ++LDFLAGS += -Wl,-rpath=$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android \ ++ -Wl,-rpath-link=$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/ \ ++ -L$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/ -lsparse + + build: $(SOURCES) +- $(CXX) $^ -o libsparse/$(NAME) $(CPPFLAGS) $(LDFLAGS) ++ $(CXX) $^ -o $(OUT_DIR)/usr/bin/$(NAME) $(CPPFLAGS) $(LDFLAGS) + + clean: +- $(RM) libsparse/$(NAME) ++ $(RM) $(OUT_DIR)/usr/bin/$(NAME) +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0010-patching-simg2img.mk-to-build-in-yocto-environment.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0010-patching-simg2img.mk-to-build-in-yocto-environment.patch new file mode 100644 index 0000000..aa60058 --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0010-patching-simg2img.mk-to-build-in-yocto-environment.patch @@ -0,0 +1,52 @@ +From 08441cf4334b911dba8c493dca3b1e2166c7d322 Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:34:34 +0100 +Subject: [PATCH 10/15] patching simg2img.mk to build in yocto environment. + +Changes include: +Introduced an output folder which will keep all the outputs from the +android-tools. + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary to the OUT_DIR + +Signed-off-by: Nisha Parrakat + +Upstream-Status: Pending +--- + debian/simg2img.mk | 11 ++++++----- + 1 file changed, 6 insertions(+), 5 deletions(-) + +diff --git a/debian/simg2img.mk b/debian/simg2img.mk +index 07fb56b4..d319c87e 100644 +--- a/debian/simg2img.mk ++++ b/debian/simg2img.mk +@@ -1,13 +1,14 @@ ++include ../../rules_yocto.mk + NAME = simg2img + SOURCES = simg2img.cpp sparse_crc32.cpp + SOURCES := $(foreach source, $(SOURCES), libsparse/$(source)) + CPPFLAGS += -Ilibsparse/include -Iinclude -std=gnu++17 +-LDFLAGS += -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android \ +- -Wl,-rpath-link=. \ +- -L. -lsparse ++LDFLAGS += -Wl,-rpath=$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android \ ++ -Wl,-rpath-link=$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android \ ++ -L$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android -lsparse + + build: $(SOURCES) +- $(CXX) $^ -o libsparse/$(NAME) $(CPPFLAGS) $(LDFLAGS) ++ $(CXX) $^ -o $(OUT_DIR)/usr/bin/$(NAME) $(CPPFLAGS) $(LDFLAGS) + + clean: +- $(RM) libsparse/$(NAME) ++ $(RM) $(OUT_DIR)/usr/bin/$(NAME) +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0011-patching-liblog.mk-to-build-in-yocto-environment.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0011-patching-liblog.mk-to-build-in-yocto-environment.patch new file mode 100644 index 0000000..7a37757 --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0011-patching-liblog.mk-to-build-in-yocto-environment.patch @@ -0,0 +1,53 @@ +From 99e46ec157e6fb912258ac6506896196e53d790b Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:35:44 +0100 +Subject: [PATCH 11/15] patching liblog.mk to build in yocto environment. + +Changes include: +Introduced an output folder which will keep all the outputs from the +android-tools. + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary to the OUT_DIR + +Signed-off-by: Nisha Parrakat + +Upstream-Status: Pending +--- + debian/liblog.mk | 8 +++++--- + 1 file changed, 5 insertions(+), 3 deletions(-) + +diff --git a/debian/liblog.mk b/debian/liblog.mk +index eb1909b9..3b40d710 100644 +--- a/debian/liblog.mk ++++ b/debian/liblog.mk +@@ -1,3 +1,4 @@ ++include ../../rules_yocto.mk + NAME = liblog + + # copied from liblog/Android.bp +@@ -39,11 +40,12 @@ CPPFLAGS += \ + LDFLAGS += -shared -Wl,-soname,$(NAME).so.0 -lpthread + + build: $(COBJECTS) $(CXXOBJECTS) +- $(CXX) $^ -o $(NAME).so.0 $(LDFLAGS) +- ln -s $(NAME).so.0 $(NAME).so ++ $(CXX) $^ -o $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so.0 $(LDFLAGS) ++ ln -sf $(NAME).so.0 $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so ++ cp -r liblog/include/* $(OUT_DIR)/usr/include/ + + clean: +- $(RM) $(COBJECTS) $(CXXOBJECTS) $(NAME).so* ++ $(RM) $(COBJECTS) $(CXXOBJECTS) $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so* + + $(COBJECTS): %.o: %.c + $(CC) $< -o $@ $(CFLAGS) $(CPPFLAGS) +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0012-patching-libsparse.mk-to-build-in-yocto-environment.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0012-patching-libsparse.mk-to-build-in-yocto-environment.patch new file mode 100644 index 0000000..029cc1c --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0012-patching-libsparse.mk-to-build-in-yocto-environment.patch @@ -0,0 +1,58 @@ +From 65ddf7ea7daae721b2d331164155542820ed3e33 Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:36:58 +0100 +Subject: [PATCH 12/15] patching libsparse.mk to build in yocto environment. + +Changes include: +Introduced an output folder which will keep all the outputs from the +android-tools. + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary to the OUT_DIR + +Signed-off-by: Nisha Parrakat + +Upstream-Status: Pending +--- + debian/libsparse.mk | 9 +++++---- + 1 file changed, 5 insertions(+), 4 deletions(-) + +diff --git a/debian/libsparse.mk b/debian/libsparse.mk +index de280def..64caa45f 100644 +--- a/debian/libsparse.mk ++++ b/debian/libsparse.mk +@@ -1,3 +1,4 @@ ++include ../../rules_yocto.mk + NAME = libsparse + SOURCES = \ + backed_block.cpp \ +@@ -18,16 +19,16 @@ LDFLAGS += \ + -shared -Wl,-soname,$(NAME).so.0 \ + -lz \ + -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android \ +- -L. \ ++ -L$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/ \ + -lbase + + + build: $(COBJECTS) $(CXXOBJECTS) +- $(CXX) $^ -o $(NAME).so.0 $(LDFLAGS) +- ln -s $(NAME).so.0 $(NAME).so ++ $(CXX) $^ -o $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so.0 $(LDFLAGS) ++ ln -sf $(NAME).so.0 $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so + + clean: +- $(RM) $(CXXOBJECTS) $(COBJECTS) $(NAME).so* ++ $(RM) $(CXXOBJECTS) $(COBJECTS) $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so* + + $(COBJECTS): %.o: %.c + $(CC) $< -o $@ $(CFLAGS) $(CPPFLAGS) +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0013-patching-libziparchive.mk-to-build-in-yocto-environm.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0013-patching-libziparchive.mk-to-build-in-yocto-environm.patch new file mode 100644 index 0000000..b49ec3b --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0013-patching-libziparchive.mk-to-build-in-yocto-environm.patch @@ -0,0 +1,59 @@ +From ae2bf1925fe02ea040005df27842c77c6d02b051 Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:39:24 +0100 +Subject: [PATCH 13/15] patching libziparchive.mk to build in yocto + environment. + +Changes include: +Introduced an output folder which will keep all the outputs from the +android-tools. + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary to the OUT_DIR + +Signed-off-by: Nisha Parrakat + +Upstream-Status: Pending +--- + debian/libziparchive.mk | 12 +++++++----- + 1 file changed, 7 insertions(+), 5 deletions(-) + +diff --git a/debian/libziparchive.mk b/debian/libziparchive.mk +index 803ea58e..6a697059 100644 +--- a/debian/libziparchive.mk ++++ b/debian/libziparchive.mk +@@ -1,3 +1,4 @@ ++include ../../rules_yocto.mk + NAME = libziparchive + SOURCES = zip_archive.cc \ + zip_archive_stream_entry.cc\ +@@ -5,14 +6,15 @@ SOURCES = zip_archive.cc \ + SOURCES := $(foreach source, $(SOURCES), libziparchive/$(source)) + CXXFLAGS += -std=gnu++17 + CPPFLAGS += -DZLIB_CONST -D_FILE_OFFSET_BITS=64 \ +- -Iinclude -Ibase/include -Ilibziparchive/include ++ -Iinclude -Ibase/include -Ilibziparchive/include -I$(OUT_DIR)/usr/include/ + LDFLAGS += -shared -Wl,-soname,$(NAME).so.0 \ + -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android \ +- -lz -L. -llog -lbase ++ -lz -L$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android -llog -lbase + + build: $(SOURCES) +- $(CXX) $^ -o $(NAME).so.0 $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) +- ln -s $(NAME).so.0 $(NAME).so ++ $(CXX) $^ -o $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so.0 $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) ++ ln -sf $(NAME).so.0 $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so ++ cp -r libziparchive/include/* $(OUT_DIR)/usr/include/ + + clean: +- $(RM) $(NAME).so* ++ $(RM) $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so* +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0014-patching-libbacktrace.mk-to-build-in-yocto-environme.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0014-patching-libbacktrace.mk-to-build-in-yocto-environme.patch new file mode 100644 index 0000000..433caf2 --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0014-patching-libbacktrace.mk-to-build-in-yocto-environme.patch @@ -0,0 +1,69 @@ +From a99b74f25c7f786e26b5400218090d86596d4541 Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:40:32 +0100 +Subject: [PATCH 14/15] patching libbacktrace.mk to build in yocto environment. + +Changes include: +Introduced an output folder which will keep all the outputs from the +android-tools. + +Adding an include file that is setting the common flags. +Changed the cppflag to include the headers from other components +of android-tools + +Modified LDflags so that the libraries that are coming from other android-tools +are searched in the output folder. + +Modified the build rule so that it outputs the binary to the OUT_DIR + +Signed-off-by: Nisha Parrakat + +Upstream-Status: Pending +--- + debian/libbacktrace.mk | 14 +++++++------- + 1 file changed, 7 insertions(+), 7 deletions(-) + +diff --git a/debian/libbacktrace.mk b/debian/libbacktrace.mk +index 330d211c..229b39d9 100644 +--- a/debian/libbacktrace.mk ++++ b/debian/libbacktrace.mk +@@ -1,5 +1,5 @@ + +-include /usr/share/dpkg/architecture.mk ++include ../../rules_yocto.mk + + NAME = libbacktrace + +@@ -88,11 +88,11 @@ CPPFLAGS += \ + -Ilibprocinfo/include \ + -Ilibunwindstack/include \ + -I/usr/include/android/lzma \ +- -I/usr/include/android/unwind ++ -I$(OUT_DIR)/usr/include/android/libunwind + LDFLAGS += -shared -Wl,-soname,$(NAME).so.0 \ + -Wl,-rpath=/usr/lib/$(DEB_HOST_MULTIARCH)/android \ +- -L/usr/lib/$(DEB_HOST_MULTIARCH)/android -lunwind \ +- -L. -lbase -llog -lpthread -l7z ++ -L$(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android -lunwind \ ++ -lbase -llog -lpthread -l7z + + # -latomic should be the last library specified + # https://github.com/android/ndk/issues/589 +@@ -104,11 +104,11 @@ ifeq ($(DEB_HOST_ARCH), mipsel) + endif + + build: $(COBJECTS) $(CXXOBJECTS) $(OBJECTS_ASSEMBLY) +- $(CXX) $^ -o $(NAME).so.0 $(LDFLAGS) +- ln -s $(NAME).so.0 $(NAME).so ++ $(CXX) $^ -o $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so.0 $(LDFLAGS) ++ ln -sf $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so.0 $(NAME).so + + clean: +- $(RM) $(COBJECTS) $(CXXOBJECTS) $(NAME).so* ++ $(RM) $(COBJECTS) $(CXXOBJECTS) $(OUT_DIR)/usr/lib/$(DEB_HOST_MULTIARCH)/android/$(NAME).so* + + $(CXXOBJECTS): %.o: %.cpp + $(CXX) $< -o $@ $(CXXFLAGS) $(CPPFLAGS) +-- +2.36.1.vfs.0.0 + diff --git a/dynamic-layers/selinux/android-tools/android-tools/core/0015-Use-namespace-std-to-compile-libbacktrace.patch b/dynamic-layers/selinux/android-tools/android-tools/core/0015-Use-namespace-std-to-compile-libbacktrace.patch new file mode 100644 index 0000000..d8fee66 --- /dev/null +++ b/dynamic-layers/selinux/android-tools/android-tools/core/0015-Use-namespace-std-to-compile-libbacktrace.patch @@ -0,0 +1,32 @@ +From 19a16829ef7b7ffd6466b9b90585d667a1663969 Mon Sep 17 00:00:00 2001 +From: Etienne Cordonnier +Date: Fri, 3 Mar 2023 13:43:50 +0100 +Subject: [PATCH 15/15] Use namespace std to compile libbacktrace + +To Fix the below error + + In file included from libunwindstack/DwarfSection.cpp:21: +| libunwindstack/include/unwindstack/DwarfMemory.h:32:29: error: unknown type name 'size_t'; did you mean 'std::size_t'? +| bool ReadBytes(void* dst, size_t num_bytes); +| ^~~~~~ +| std::size_t +--- + libunwindstack/include/unwindstack/DwarfMemory.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/libunwindstack/include/unwindstack/DwarfMemory.h b/libunwindstack/include/unwindstack/DwarfMemory.h +index 244c0e12..0a3fefeb 100644 +--- a/libunwindstack/include/unwindstack/DwarfMemory.h ++++ b/libunwindstack/include/unwindstack/DwarfMemory.h +@@ -23,7 +23,7 @@ namespace unwindstack { + + // Forward declarations. + class Memory; +- ++using namespace std; + class DwarfMemory { + public: + DwarfMemory(Memory* memory) : memory_(memory) {} +-- +2.36.1.vfs.0.0 + -- cgit v1.2.3-54-g00ecf