Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add support for intermediate updates #58

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions build-loader.sh
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,7 @@ if [ ! -d "${BRP_UPAT_DIR}" ]; then

brp_verify_file_sha256 "${BRP_PAT_FILE}" "$(brp_json_get_field "${BRP_REL_CONFIG_JSON}" "os.sha256")"
brp_unpack_tar "${BRP_PAT_FILE}" "${BRP_UPAT_DIR}"

else
pr_info "Found unpacked PAT at \"%s\" - skipping unpacking" "${BRP_UPAT_DIR}"
fi
Expand All @@ -213,6 +214,16 @@ fi
##### LINUX KERNEL MODIFICATIONS #######################################################################################
# Prepare Linux kernel image
readonly BRP_ZLINUX_FILE=${BRP_UPAT_DIR}/$(brp_json_get_field "${BRP_REL_CONFIG_JSON}" 'files.zlinux.name')

if [ ! -f "${BRP_ZLINUX_FILE}" ]; then
pr_info "No zimage in Unpacked PAT - Try to find flashupdate package" "${BRP_PAT_FILE}"
readonly BRP_FLASHUPDATE_DEBFILE=$( ls -d ${BRP_UPAT_DIR}/flashupdate_*.deb | head -n1 )
if [ -f "${BRP_FLASHUPDATE_DEBFILE}" ]; then
pr_process "flashupdate found unpack"
"${DPKG_PATH}" -x "${BRP_FLASHUPDATE_DEBFILE}" "${BRP_UPAT_DIR}"
fi
fi

readonly BRP_ZLINUX_PATCHED_FILE="${BRP_BUILD_DIR}/zImage-patched"
if [ ! -f "${BRP_ZLINUX_PATCHED_FILE}" ]; then
# Using repack method to patch the kernel. This method assumes that it will be interrupted, someone will go and look
Expand Down
1 change: 1 addition & 0 deletions include/runtime.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ system_tools=(
[find]="find --version" # repacking ramdisks & finding empty trees
[chmod]="chmod --version" # making sure executables are executable
[dirname]="dirname --version" # creating directories from full paths
[dpkg]="dpkg --version" # extract flashupdate
)
typeset -A custom_tools
custom_tools=(
Expand Down