From 930edb666122d04ffb6a1ff1648181d5b08dda84 Mon Sep 17 00:00:00 2001 From: Sen Jiang Date: Wed, 18 Jan 2017 17:26:42 -0800 Subject: imgdiff: cache bsdiff suffix array in zip mode. In zip mode, if a chunk is not deflate or its filename can't be found in source chunks, the entire source file is used as old data for bsdiff, To avoid repeatedly construct the suffix array used by bsdiff, we cache the suffix array of the entire source file. Bug: 34281147 Test: =time -v imgdiff -z Chrome-ORF74B.apk Chrome-ORF76B.apk Chrome.imgdiff Change-Id: Ifd957ccecf7226fcb44dbf28c58969a06ef74f4b --- applypatch/Android.mk | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'applypatch/Android.mk') diff --git a/applypatch/Android.mk b/applypatch/Android.mk index ec3c6ee38..85b5c9fcd 100644 --- a/applypatch/Android.mk +++ b/applypatch/Android.mk @@ -124,6 +124,8 @@ libimgdiff_cflags := \ libimgdiff_static_libraries := \ libbsdiff \ + libdivsufsort \ + libdivsufsort64 \ libbase \ libz @@ -166,7 +168,5 @@ LOCAL_CFLAGS := -Werror LOCAL_STATIC_LIBRARIES := \ libimgdiff \ $(libimgdiff_static_libraries) \ - libbz \ - libdivsufsort \ - libdivsufsort64 + libbz include $(BUILD_HOST_EXECUTABLE) -- cgit v1.2.3