[AIOT] Build OS Debian for PV100A

1. Create an Ubuntu machine environment (Using the following versions : Ubuntu 20.04.)

2. Download Debian source code from github (http://github.com/ASUS-IPC/manifest)

 $ git config --global user.name "Your Name"
 $ git config --global user.email "Your Email"
 
$ mkdir ~/bin (this step may not be needed if the bin folder already exists)
 
$ curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
$ chmod a+x ~/bin/repo
$ export PATH=~/bin:$PATH
$ mkdir ~/debian-imx_8m
$ cd ~/ debian-imx_8m
 
$ repo init -u http://github.com/ASUS-IPC/manifest.git -m $manifest_name
 

Ex. for asus-debian-4.14.98.xml

$ repo init -u http://github.com/ASUS-IPC/manifest.git -m asus-debian-4.14.98.xml
$ repo sync -j4
 

3. Setup Docker

  • Uninstall old versions
$ sudo apt-get remove docker docker-engine docker.io containerd runc
 
  • Install Docker Engine - Community
$ sudo apt-get update
$ sudo apt-get install apt-transport-http ca-certificates curl gnupg-agent software-properties-common
$ curl -fsSL http://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
$ sudo apt-key fingerprint 0EBFCD88
$ sudo add-apt-repository "deb [arch=amd64] http://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
$ sudo apt-get update
$ sudo apt-get install docker-ce docker-ce-cli containerd.io
$ sudo docker run hello-world
 

http://docs.docker.com/engine/installation/linux/docker-ce/ubuntu/

Manage Docker as a non-root user

If you don’t want to preface the docker command with sudo, create a Unix group called docker and add users to it.

$ sudo groupadd docker
$ sudo usermod -aG docker $USER
$ sudo reboot

$ docker run hello-world
 

http://docs.docker.com/install/linux/linux-postinstall/

4. Docker build:

Go to the directory where the downloaded the code base is located in, and execute the script. This will take a while as it installs the necessary packages on the host and builds the Docker image.

$ cd ~/debian-imx_8m
$ ./docker_builder/docker-builder-run.sh
 

Once the step above is finished, you are in the shell of the newly started Docker container. You can issue the following command to build all the images for debian.

Build from build.sh

$VERSION=RELEASE ./build.sh
Select “5” to build image for PV100A_2G
Then,
Select “1” to build All image 
 

5. After you build successfully, it will copy bootloader, raw image, flash tool to debian-imx_8m /Image-imx8mq-pv100a2g_debian folder, please reference PV100A Debian flash image SOP.pdf to flash image