Android/PreInstalledAPK: Difference between revisions

From OLPC
Jump to navigation Jump to search
(Created page with 'Download userdata.tar.bz2 file from [http://build.laptop.org/android/2014-05-05/ our build directory]')
 
No edit summary
 
(15 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Pre-installed APKs are packaged as a zip file in our build. If you would like to add/delete pre-installed APKs, it can be easily done by recreating zip file.
Download userdata.tar.bz2 file from [http://build.laptop.org/android/2014-05-05/ our build directory]

0. Download 32014o4.zd from the OLPC OS release directory,

1. Download kernel, ramdisk.img, system.img, and userdata.tar.bz2 files from the Android [http://build.laptop.org/android/latest/ build directory],

2. Prepare new userdata.tar.bz2 file

mkdir userdata
cd userdata/
cp ~/Downloads/userdata.tar.bz2 ./
tar -xvjpf userdata.tar.bz2

cp ~/Downloads/XXX0.apk data/apk/
cp ~/Downloads/XXX1.apk data/apk/
.....

rm -f userdata.tar.bz2
tar -jcvf userdata.tar.bz2 data

3. Download image build script

git clone git://dev.laptop.org/users/ben/android_vendor_olpc_xo4 android-4.3.1-xo4
cd sugar-combiner
make

4. Recreate zd image using your userdata.tar.bz2.

* install the {{code|android-tools-fsutils}} package or ensure you have simg2img tools in your /usr/bin/ [http://dev.laptop.org/~ben/simg2img simg2img]

cd sugar-combiner
cp SUGAR_IMG_PATH/32014o4.zd ./
mkdir imgs
cp ANDROID_IMG_PATH/kernel imgs/
cp ANDROID_IMG_PATH/ramdisk.img imgs/
cp ANDROID_IMG_PATH/system.img imgs/
cp ANDROID_IMG_PATH/userdata.tar.bz2 imgs/
sudo ./mkzd.sh

5. 32014a4.zd is the image that contains new APKs which you added.

fs-update u:\32014a4.zd

Latest revision as of 21:30, 13 April 2015

Pre-installed APKs are packaged as a zip file in our build. If you would like to add/delete pre-installed APKs, it can be easily done by recreating zip file.

0. Download 32014o4.zd from the OLPC OS release directory,

1. Download kernel, ramdisk.img, system.img, and userdata.tar.bz2 files from the Android build directory,

2. Prepare new userdata.tar.bz2 file

  mkdir userdata
  cd userdata/
  cp ~/Downloads/userdata.tar.bz2 ./
  tar -xvjpf userdata.tar.bz2
  cp ~/Downloads/XXX0.apk data/apk/
  cp ~/Downloads/XXX1.apk data/apk/
  .....
  rm -f userdata.tar.bz2 
  tar -jcvf userdata.tar.bz2 data

3. Download image build script

  git clone git://dev.laptop.org/users/ben/android_vendor_olpc_xo4 android-4.3.1-xo4
  cd sugar-combiner
  make

4. Recreate zd image using your userdata.tar.bz2.

  • install the android-tools-fsutils package or ensure you have simg2img tools in your /usr/bin/ simg2img
  cd sugar-combiner
  cp SUGAR_IMG_PATH/32014o4.zd ./
  mkdir imgs
  cp ANDROID_IMG_PATH/kernel imgs/
  cp ANDROID_IMG_PATH/ramdisk.img imgs/
  cp ANDROID_IMG_PATH/system.img imgs/
  cp ANDROID_IMG_PATH/userdata.tar.bz2 imgs/
  sudo ./mkzd.sh

5. 32014a4.zd is the image that contains new APKs which you added.

  fs-update u:\32014a4.zd