Include prebuilt static toybox

Built from lineage-18
This commit is contained in:
Alessandro Astone
2020-12-27 13:42:28 +01:00
parent 0dfbc1825a
commit ccacac122a
5 changed files with 21 additions and 4 deletions

View File

@@ -45,6 +45,7 @@ function create() {
echo "Build directories are now ready" >> $GLOG
echo "Getting prebuilts..."
echo "Copying stuff" >> $GLOG
cp $TOP/toybox-$GARCH $OUT/$GARCH/toybox >> $GLOG
cp -r $PREBUILT/* $OUT/$GARCH/system >> $GLOG
cp -r $COMMON/* $OUT/$GARCH/system >> $GLOG
echo "Generating addon.d script" >> $GLOG

View File

@@ -25,6 +25,8 @@ cleanup() {
ui_print "Cleaning up files"
cd ../
rm -rf system
rm -rf bin
rm toybox
ui_print "Unmounting partitions"
umount -l "$SYSTEM_MNT"
@@ -85,6 +87,24 @@ ui_print "**********************"
ui_print "MindTheGapps installer"
ui_print "**********************"
ui_print "Extracting files"
TMP=/tmp
cd "$TMP"
unzip -o "$ZIP"
rm -rf META-INF
ui_print "Setting up environment"
TOYBOX="${TMP}/toybox"
chmod +x "$TOYBOX"
TOYS_PATH="${TMP}/bin"
rm -rf "$TOYS_PATH";
$TOYBOX install -d "$TOYS_PATH"
for toy in $($TOYBOX); do
$TOYBOX ln -sf "$TOYBOX" "${TOYS_PATH}/${toy}"
done
PATH="${TOYS_PATH}:${PATH}"
ui_print "Mounting partitions"
# Ensure system is unmounted so mounting succeeds
@@ -129,10 +149,6 @@ SYSTEM_OUT="${SYSTEM_MNT}/system"
SYSTEM_STORAGE=`df $SYSTEM_MNT | tail -1 | tr -s ' ' | cut -d ' ' -f4`
STORAGE_BUFFER=10240
ui_print "Extracting files"
cd /tmp
unzip -o "$ZIP"
rm -rf META-INF
cd system
compute_apps_size

BIN
toybox-arm Normal file

Binary file not shown.

BIN
toybox-arm64 Normal file

Binary file not shown.

BIN
toybox-x86 Normal file

Binary file not shown.