Skip to content

Commit 9d30d59

Browse files
committed
Sync with microG unofficial installer
1 parent 547f1e6 commit 9d30d59

File tree

5 files changed

+242
-87
lines changed

5 files changed

+242
-87
lines changed

build.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ rm -f "${TEMP_DIR}/zip-content/misc/busybox/busybox-"mips* || ui_error 'Failed t
234234
rm -f "${TEMP_DIR}/zip-content/LICENSES/Info-ZIP.txt" || ui_error 'Failed to delete unused files in the temp dir'
235235
rm -f "${TEMP_DIR}/zip-content/LICENSES/Unlicense.txt" || ui_error 'Failed to delete unused files in the temp dir'
236236

237-
printf '%s\n%s\n\n%s\n' '# SPDX-FileCopyrightText: none' '# SPDX-License-Identifier: CC0-1.0' "buildType=${BUILD_TYPE:?}" 1> "${TEMP_DIR:?}/zip-content/build-type.prop" || ui_error 'Failed to create the "build-type.prop" file'
237+
printf '%s\n%s\n%s\n\n%s\n' '# -*- coding: utf-8; mode: conf-unix -*-' '# SPDX-FileCopyrightText: none' '# SPDX-License-Identifier: CC0-1.0' "buildType=${BUILD_TYPE:?}" 1> "${TEMP_DIR:?}/zip-content/info.prop" || ui_error "Failed to create the 'info.prop' file"
238238

239239
if test "${OPENSOURCE_ONLY:?}" = 'false'; then
240240
files_to_download | while IFS='|' read -r LOCAL_FILENAME LOCAL_PATH MIN_API MAX_API FINAL_FILENAME INTERNAL_NAME FILE_HASH _; do
@@ -254,6 +254,9 @@ if test "${OPENSOURCE_ONLY:?}" = 'false'; then
254254
fi
255255

256256
printf '%s\n' 'Setting name;Visibility;Type' 1> "${TEMP_DIR:?}/zip-content/setprop-settings-list.csv" || ui_error 'Failed to generate setprop settings list (1)'
257+
printf '%s\n' 'DRY_RUN;local;integer' 1>> "${TEMP_DIR:?}/zip-content/setprop-settings-list.csv" || ui_error 'Failed to generate setprop settings list (2)'
258+
printf '%s\n' 'KEY_TEST_ONLY;local;integer' 1>> "${TEMP_DIR:?}/zip-content/setprop-settings-list.csv" || ui_error 'Failed to generate setprop settings list (3)'
259+
257260
while IFS='#=; ' read -r _ PROP_NAME PROP_VALUE PROP PROP_VISIBILITY PROP_TYPE _; do
258261
if test "${PROP?}" != 'setprop'; then continue; fi
259262

zip-content/customize.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ package_extract_file_may_fail()
277277
} ||
278278
{
279279
rm -f -- "${2:?}" || true
280-
ui_warning "Failed to extract the file '${1}' from this archive"
280+
ui_debug "Failed to extract the file '${1}' from this archive"
281281
return 1
282282
}
283283
}
@@ -362,14 +362,15 @@ fi
362362
set_perm_safe 0 0 0755 "${TMP_PATH:?}"
363363

364364
PREVIOUS_PATH="${PATH:-%empty}"
365+
DEVICE_TWRP="$(command -v twrp)" || DEVICE_TWRP=''
365366
DEVICE_GETPROP="$(command -v getprop)" || DEVICE_GETPROP=''
366367
DEVICE_MOUNT="$(command -v mount)" || DEVICE_MOUNT=''
367368
DEVICE_DUMPSYS="$(command -v dumpsys)" || DEVICE_DUMPSYS=''
368369
DEVICE_STAT="$(command -v stat)" || DEVICE_STAT=''
369370
DEVICE_PM="$(command -v pm)" || DEVICE_PM=''
370371
DEVICE_AM="$(command -v am)" || DEVICE_AM=''
371-
readonly PREVIOUS_PATH DEVICE_GETPROP DEVICE_MOUNT DEVICE_DUMPSYS DEVICE_STAT DEVICE_PM DEVICE_AM
372-
export PREVIOUS_PATH DEVICE_GETPROP DEVICE_MOUNT DEVICE_DUMPSYS DEVICE_STAT DEVICE_PM DEVICE_AM
372+
readonly PREVIOUS_PATH DEVICE_TWRP DEVICE_GETPROP DEVICE_MOUNT DEVICE_DUMPSYS DEVICE_STAT DEVICE_PM DEVICE_AM
373+
export PREVIOUS_PATH DEVICE_TWRP DEVICE_GETPROP DEVICE_MOUNT DEVICE_DUMPSYS DEVICE_STAT DEVICE_PM DEVICE_AM
373374

374375
if test "${TEST_INSTALL:-false}" = 'false'; then
375376
create_dir_safe "${TMP_PATH:?}/bin"

0 commit comments

Comments
 (0)