diff options
author | Bruno Martins <bgcngm@gmail.com> | 2020-05-24 08:52:36 +0100 |
---|---|---|
committer | Davide Garberi <dade.garberi@gmail.com> | 2021-10-19 15:09:38 +0200 |
commit | b2f8eeed02fa582450129dda3421fcb683ba5577 (patch) | |
tree | fb45d23534d8076ac36c0aeb79c127185f60237f | |
parent | 30df991957870ec08fe9f1ffd3efa2064d92454c (diff) |
msm8996-common: Also allow extracting target device blobs only
Change-Id: Ib5157b1e182ac6faf212793871ddff28fc32063d
-rwxr-xr-x | extract-files.sh | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/extract-files.sh b/extract-files.sh index ea3396b..27291a5 100755 --- a/extract-files.sh +++ b/extract-files.sh @@ -1,7 +1,7 @@ #!/bin/bash # # Copyright (C) 2016 The CyanogenMod Project -# Copyright (C) 2017 The LineageOS Project +# Copyright (C) 2017-2020 The LineageOS Project # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -35,13 +35,17 @@ source "${HELPER}" 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 @@ -144,11 +148,13 @@ function blob_fixup() { esac } -# Initialize the helper for common device -setup_vendor "${DEVICE_COMMON}" "${VENDOR}" "${ANDROID_ROOT}" true "${CLEAN_VENDOR}" +if [ -z "${ONLY_TARGET}" ]; then + # Initialize the helper for common device + setup_vendor "${DEVICE_COMMON}" "${VENDOR}" "${ANDROID_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 |