whyred: Upstream extract_utils

Change-Id: I546e9648c33299d691a305f526a8c6115b06e03a
This commit is contained in:
Nicholas Lim 2018-11-09 10:37:11 +08:00
parent 76e3fc4e31
commit 7a88073282
2 changed files with 11 additions and 15 deletions

View file

@ -2,7 +2,6 @@
# #
# Copyright (C) 2016 The CyanogenMod Project # Copyright (C) 2016 The CyanogenMod Project
# Copyright (C) 2017 The LineageOS Project # Copyright (C) 2017 The LineageOS Project
# Copyright (C) 2018 The LineageOS Project
# #
# Licensed under the Apache License, Version 2.0 (the "License"); # Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License. # you may not use this file except in compliance with the License.
@ -19,9 +18,8 @@
set -e set -e
export DEVICE=whyred DEVICE=whyred
export VENDOR=xiaomi VENDOR=xiaomi
export TREBLE_COMPATIBLE=1
# Load extract_utils and do some sanity checks # Load extract_utils and do some sanity checks
MY_DIR="${BASH_SOURCE%/*}" MY_DIR="${BASH_SOURCE%/*}"
@ -57,8 +55,8 @@ if [ -z "$SRC" ]; then
SRC=adb SRC=adb
fi fi
# Initialize the helper for device # Initialize the helper
setup_vendor "$DEVICE" "$VENDOR" "$LINEAGE_ROOT" true "$CLEAN_VENDOR" setup_vendor "$DEVICE" "$VENDOR" "$LINEAGE_ROOT" false "$CLEAN_VENDOR"
extract "$MY_DIR"/proprietary-files.txt "$SRC" "$SECTION" extract "$MY_DIR"/proprietary-files.txt "$SRC" "$SECTION"

View file

@ -2,7 +2,6 @@
# #
# Copyright (C) 2016 The CyanogenMod Project # Copyright (C) 2016 The CyanogenMod Project
# Copyright (C) 2017 The LineageOS Project # Copyright (C) 2017 The LineageOS Project
# Copyright (C) 2018 The LineageOS Project
# #
# Licensed under the Apache License, Version 2.0 (the "License"); # Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License. # you may not use this file except in compliance with the License.
@ -19,10 +18,10 @@
set -e set -e
DEVICE=whyred
VENDOR=xiaomi
INITIAL_COPYRIGHT_YEAR=2018 INITIAL_COPYRIGHT_YEAR=2018
export DEVICE=whyred
export VENDOR=xiaomi
export TREBLE_COMPATIBLE=1
# Load extract_utils and do some sanity checks # Load extract_utils and do some sanity checks
MY_DIR="${BASH_SOURCE%/*}" MY_DIR="${BASH_SOURCE%/*}"
@ -37,14 +36,13 @@ if [ ! -f "$HELPER" ]; then
fi fi
. "$HELPER" . "$HELPER"
# Initialize the helper for common # Initialize the helper
setup_vendor "$DEVICE" "$VENDOR" "$LINEAGE_ROOT" true setup_vendor "$DEVICE" "$VENDOR" "$LINEAGE_ROOT"
# Copyright headers and guards # Copyright headers and guards
write_headers "whyred" write_headers
# The standard common blobs write_makefiles "$MY_DIR"/proprietary-files.txt true
write_makefiles "$MY_DIR"/proprietary-files.txt 1
# Finish # Finish
write_footers write_footers