universal7885: Also allow extracting target device blobs only

Change-Id: Ib5157b1e182ac6faf212793871ddff28fc32063d
Signed-off-by: SamarV-121 <samarvispute121@gmail.com>
This commit is contained in:
Bruno Martins 2020-05-24 08:52:36 +01:00 committed by roynatech2544
commit 84a5f074c8

View file

@ -50,13 +50,17 @@ function blob_fixup {
CLEAN_VENDOR=true
ONLY_COMMON=
ONLY_TARGET=
SECTION=
KANG=
while [ "${#}" -gt 0 ]; do
case "${1}" in
-o | --only-common )
ONLY_COMMON=false
--only-common )
ONLY_COMMON=true
;;
--only-target )
ONLY_TARGET=true
;;
-n | --no-cleanup )
CLEAN_VENDOR=false
@ -80,10 +84,13 @@ if [ -z "${SRC}" ]; then
fi
# Initialize the helper for common device
setup_vendor "${DEVICE_COMMON}" "${VENDOR}" "${LINEAGE_ROOT}" true "${CLEAN_VENDOR}"
if [ -z "${ONLY_TARGET}" ]; then
# Initialize the helper for common device
setup_vendor "${DEVICE_COMMON}" "${VENDOR}" "${LINEAGE_ROOT}" true "${CLEAN_VENDOR}"
extract "${MY_DIR}/proprietary-files.txt" "${SRC}" \
"${KANG}" --section "${SECTION}"
extract "${MY_DIR}/proprietary-files.txt" "${SRC}" \
"${KANG}" --section "${SECTION}"
fi
if [ -z "${ONLY_COMMON}" ] && [ -s "${MY_DIR}/../${DEVICE}/proprietary-files.txt" ]; then
# Reinitialize the helper for device