Search
SailfishOS Open Build Service
>
Projects
>
nemo
:
devel:hw
:
nv:tegra3:nexus7
>
nexus7-fw-installer
> nexus7-fw-install
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File nexus7-fw-install of Package nexus7-fw-installer
#!/bin/sh TMP_PATH="/tmp/nexus7_fw_install" URL="https://dl.google.com/dl/android/aosp" TGZ_FILE="broadcom-grouper-jzo54k-26240daf.tgz" MD5_SUM="d9f54118d7dc467bea232e20017290a8" SHA1_SUM="3eb767b236862a184fd1363066a58b1c792e9b19" SELF_EXTRACTOR="extract-broadcom-grouper.sh" mkdir -p $TMP_PATH cd $TMP_PATH if [ ! -e $TGZ_FILE ]; then echo "Downloading firmware package from: $URL/$TGZ_FILE" curl -k -o $TGZ_FILE $URL/$TGZ_FILE ; fi echo "$MD5_SUM $TGZ_FILE" > $TGZ_FILE.md5 echo "$SHA1_SUM $TGZ_FILE" > $TGZ_FILE.sha1 echo -e "\nChecking MD5 sum." md5sum -c $TGZ_FILE.md5 if [ $? -eq 0 ]; then echo "MD5 sum verified." ; else echo "MD5 checksum invalid." echo "Stopping further execution." exit 1 ; fi echo -e "\nChecking SHA1 sum." sha1sum -c $TGZ_FILE.sha1 if [ $? -eq 0 ]; then echo "SHA1 sum verified." ; else echo "SHA1 checksum invalid." echo "Stopping further execution." exit 2 ; fi if [ ! -e $SELF_EXTRACTOR ]; then echo -e "\nExtracting firmware package..." tar xf $TGZ_FILE ; fi if [ ! -d "vendor" ] ; then echo -e "\nRunning self extractor..." echo "Please follow the instrutions and read the license." echo "Press <ENTER> to scroll down a single line." echo "Press <SPACE> to scroll down an entire page." ./$SELF_EXTRACTOR ; fi if [ $? -ne 0 ] ; then echo -e "\nRunning the selfextractor terminated with non zero status." echo "Reasons could be that you didn't accept the license or an error happened." echo "Terminating this script." exit 3 ; fi if [ ! -d "vendor" ] ; then echo -e "\nExtracted files not found." echo "Terminating the installation script." exit 4 ; fi mkdir -p /lib/nexus7_fw cp -r vendor /lib/nexus7_fw echo -e "\nInstallation of Nexus 7 firmware finished. :)"