RZ-G/RZ-G2 BSP Porting Debian: Difference between revisions

From Renesas.info
(Add new page to describe how to build debian rootfs (not finished))
 
mNo edit summary
 
(4 intermediate revisions by the same user not shown)
Line 4: Line 4:
==Specification==
==Specification==
This guide describes how to make Debian rootfs to work on RZ/G2L serial products.
This guide describes how to make Debian rootfs to work on RZ/G2L serial products.
(Notes: GPU and Codec were not incluided yet, will update later)


'''Target Debian OS Version:''' bullseye11.0
'''Target Debian OS Version:''' bullseye11.0
Line 37: Line 39:


If this step is successful, you can see below messages
If this step is successful, you can see below messages
[[File:debian package download.png|thumb|Debian package download]]


[[File:debian package download.png|frameless|Debian package download]]


=== Rootfs configuration ===
{| class="mw-collapsible mw-collapsed wikitable" width="50%"
{| class="mw-collapsible mw-collapsed wikitable" width="50%"
|Initialize rootfs 
|Initialize rootfs 
Line 48: Line 51:
|}
|}
If this step is successful, you can see below contents
If this step is successful, you can see below contents
[[File:debian init.png|thumb|debian init]]
 
[[File:debian init.png|frameless|debian init]]
 
{| class="mw-collapsible mw-collapsed wikitable" width="50%"
|Additional Configuration
|-
|# cp -rf /etc/ssl root/etc             ###copy certification from ubuntu pc to debian
 
<nowiki>#</nowiki> chroot root
 
<nowiki>#</nowiki>
 
<nowiki>#</nowiki> apt-get update
 
<nowiki>#</nowiki> apt-get install vim openssh-server
 
<nowiki>#</nowiki> apt install net-tools iputils-ping bash bzip2
 
<nowiki>#</nowiki> vi /etc/ssh/sshd_config
 
change
 
<nowiki>#</nowiki>PermitRootLogin prohibit-password
 
to
 
PermitRootLogin yes
 
<nowiki>#</nowiki> adduser user    ### input password according to the hint
 
<nowiki>#</nowiki> passwd root      ### change root password
 
<nowiki>#</nowiki> echo "auto eth0" > /etc/network/interfaces.d/eth0
 
<nowiki>#</nowiki> echo "iface eth0 inet dhcp" >> /etc/network/interfaces.d/eth0
 
<nowiki>#</nowiki> vi /etc/ssh/sshd_config
 
<nowiki>#</nowiki> exit
|}
Compress rootfs
{| class="wikitable"
|+
|# cd root
<nowiki>#</nowiki> tar -cjf debian_bullseye_rootfs.tar.bz2 ./*
|}
Use debian_bullseye_rootfs.tar.bz2 to make sd card image (ignore)
 
This rootfs should be able to work on any VLP kernel
 
[[File:Debian11.png|frameless|Debian11]]

Latest revision as of 03:10, 12 January 2024

← Back to RZ-G/RZ-G2_BSP_Porting

SoC: All

Specification

This guide describes how to make Debian rootfs to work on RZ/G2L serial products.

(Notes: GPU and Codec were not incluided yet, will update later)

Target Debian OS Version: bullseye11.0

Target reference board: RZ/G2L,/G2LC,/G2UL SMARC

Host PC Environment: Ubuntu20.04

Debian Filesystem Building

Install QEMU

Run below command on Host Ubuntu PC

sudo apt-get install qemu qemu-user-static

Download Required Files

sudo apt-get install binfmt-support debootstrap

Download debian package 
$ sudo su - root

# mkdir ./debian

# cd ./debian

# debootstrap --arch=arm64 --foreign bullseye root http://deb.debian.org/debian/

### Notes: If you want to build Debian 10, you can use below command

# debootstrap --arch=arm64 --foreign buster root http://deb.debian.org/debian/

This step requires network connection, if failed, please try more times.

If this step is successful, you can see below messages

Debian package download

Rootfs configuration

Initialize rootfs 
# cp /usr/bin/qemu-arm-static ./root/usr/bin

# DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true LC_ALL=C LANGUAGE=C LANG=C chroot root debootstrap/debootstrap --second-stage

If this step is successful, you can see below contents

debian init

Additional Configuration
# cp -rf /etc/ssl root/etc             ###copy certification from ubuntu pc to debian

# chroot root

#

# apt-get update

# apt-get install vim openssh-server

# apt install net-tools iputils-ping bash bzip2

# vi /etc/ssh/sshd_config

change

#PermitRootLogin prohibit-password

to

PermitRootLogin yes

# adduser user ### input password according to the hint

# passwd root ### change root password

# echo "auto eth0" > /etc/network/interfaces.d/eth0

# echo "iface eth0 inet dhcp" >> /etc/network/interfaces.d/eth0

# vi /etc/ssh/sshd_config

# exit

Compress rootfs

# cd root

# tar -cjf debian_bullseye_rootfs.tar.bz2 ./*

Use debian_bullseye_rootfs.tar.bz2 to make sd card image (ignore)

This rootfs should be able to work on any VLP kernel

Debian11