Skip to content
This repository has been archived by the owner on Dec 1, 2021. It is now read-only.

Add scripts to make 32bit and 64 bit os image #560

Merged
merged 45 commits into from Nov 12, 2019

Conversation

tk26eng
Copy link
Contributor

@tk26eng tk26eng commented Oct 24, 2019

This PR is for adding configurations for docker and scripts which can run on the docker to make rootfs of Ubuntu.

Motivation and Context

Now we want to support new os Ubuntu (bionic) as next distribution and 32bit and 64bit ARM CPU should be supported with them. I created docker configurations and some useful scripts to generate rootfs of Ubuntu.

Description

To know how to generate rootfs actually, please see docs/install/make_rootfs.md. I'll merge the contents of the file to Blueoil document after all required things like kernel or kernel modules are ready.

How has this been tested?

Test has been performed on host machine of Ubuntu 16.04. On the host, following commands were performed.

cd blueoil/
make rootfs-armhf
make rootfs-arm64

After these commands, we can see the generated files (rootfs_armhf.tgz and rootfs_arm64.tgz) under blueoil/dlk/hw/make_os/build.
About rootfs_armhf.tgz, I tested it on DE10-Nano with kernel of Blueoil's OS image.
About rootfs_arm64.tgz, I tested it on Ultra96v2 with test kernel for Ultra96v2 (This is not merged yet).
In those two environment, generated Ubuntu worked well.

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature / Optimization (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist:

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

@blueoil-butler blueoil-butler bot added the CI: auto-run Run CI automatically label Oct 24, 2019
@iizukak
Copy link
Member

iizukak commented Oct 25, 2019

@tk26eng
How about to use blueoil/Makefile ?

Add target to Makefile to create docker image and rootfs.

For example,

make os-docker
make rootfs-32
make rootfs-64

And we want to unity the document directory to blueoil/docs.

Copy link
Contributor

@hadusam hadusam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commented, please check them! 👍

docs/install/index.rst Outdated Show resolved Hide resolved
@tk26eng
Copy link
Contributor Author

tk26eng commented Nov 1, 2019

@hadusam
I fix all, so please check it again.

@tk26eng tk26eng requested a review from hadusam November 7, 2019 05:40
@iizukak
Copy link
Member

iizukak commented Nov 8, 2019

@hadusam How about this PR?

@hadusam
Copy link
Contributor

hadusam commented Nov 8, 2019

@iizukak Oh, sorry for late. I will check this!

Copy link
Member

@iizukak iizukak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tk26eng
Ownership Approval.
Please get Bash readability approval from @hadusam then merge.

Copy link
Contributor

@hadusam hadusam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tk26eng
Sorry for the late response ><
Overall, please use braces in your bash scripts for readability, e.g. $ROOTFS_DIR/usr/bin/ -> ${ROOTFS_DIR}/usr/bin/.
Also, I added nit-pick comments, please check them.
LGTM except for comments! 👍 So, please fix them! 🙇

make_os/build/make_rootfs.sh Outdated Show resolved Hide resolved
make_os/build/make_rootfs.sh Outdated Show resolved Hide resolved
make_os/build/make_rootfs.sh Outdated Show resolved Hide resolved
make_os/build/make_rootfs.sh Outdated Show resolved Hide resolved
make_os/build/make_rootfs.sh Outdated Show resolved Hide resolved
Makefile Outdated Show resolved Hide resolved
docker/Dockerfile_make_os Outdated Show resolved Hide resolved
docker/Dockerfile_make_os Outdated Show resolved Hide resolved
docker/Dockerfile_make_os Outdated Show resolved Hide resolved
make_os/build/make_rootfs.sh Outdated Show resolved Hide resolved
@hadusam hadusam mentioned this pull request Nov 8, 2019
9 tasks
@tk26eng
Copy link
Contributor Author

tk26eng commented Nov 8, 2019

@hadusam
I removed unnecessary --privileged option for docker run in Makefile.

Copy link
Contributor

@hadusam hadusam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Readability Approval, except for comments 👍

docker/Dockerfile_make_os Outdated Show resolved Hide resolved
make_os/build/make_rootfs.sh Outdated Show resolved Hide resolved
make_os/build/make_rootfs.sh Outdated Show resolved Hide resolved
make_os/build/make_rootfs.sh Outdated Show resolved Hide resolved
@tk26eng tk26eng requested a review from hadusam November 11, 2019 07:43
Copy link
Contributor

@hadusam hadusam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
Thanks 👍

@tk26eng
Copy link
Contributor Author

tk26eng commented Nov 12, 2019

@iizukak
Could you check again ? (Please merge if no problem)

@iizukak
Copy link
Member

iizukak commented Nov 12, 2019

@tk26eng OK will be merged after CI passed.

@tk26eng tk26eng merged commit 2c252e4 into blue-oil:master Nov 12, 2019
@tk26eng tk26eng deleted the make_os_image branch November 12, 2019 05:54
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
CI: auto-run Run CI automatically
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants