mei 7f1c5b19cd some enchantments for build scripts (#1364)
* downloader aria2 replace curl

aria2 is a fast downloader and it can do much more than curl
 - skip download when target file exists
 - restart an interrupted download session
 - multithreading

* remove duplicate download item

* change btrfs compression to zstd and no force compression

* mkfs.btrfs options '--data single --metadata single --label btrfs'

disable dup(duplication) on microsd card

* [fstab] change mountopts[btrfs] compression method to zstd

lzo is no fater than zstd because the low 4k write performance on my
Samsung EVO+ 32GB microsd card.
meanwhile the best io size is above 32k based on benchmark

* replace dd with truncate, create a sparse disk image

* create btrfs subvolume by default

subvolume @ as rootfs, mount at /
subvolume @home as /home, mount at /home

* fix extraargs in armbianEnv.txt

* remove tmpfs mount on /tmp

A zram block device will mount on /tmp by
/usr/lib/armbian/armbian-zram-config.

And instead, mount /media as tmpfs.

* [rsync] add '--inplace' option, optimize for btrfs

* [general.sh] change ntp server to pool.ntp.org

* [general] new option to setup btrfs compression method

for support old and boring 3.x kernels

* [general] set btrfs space cache based kervel version

kernel version above 4.5 select 'v2' as default

* [btrfs] BTRFS_COMPRESSION accept compression ratio

BTRFS_COMPRESSION=zlib
BTRFS_COMPRESSION=zstd:5
BTRFS_COMPRESSION=zstd:12 are acceptable

* [btrfs] set btrfs compression to lzo when input is illegal

* [general] new option DOWNLOAD_MIRROR to select download mirror

current DOWNLOAD_MIRROR=china is used
the mirror is provided by tsinghua university

* [general] replace USE_MAINLINE_GOOGLE_MIRROR with MAINLINE_MIRROR

MAINLINE_MIRROR=google, use google provided mirror
MAINLINE_MIRROR=tuna, use tsinghua provided mirror
leave it empty, use official git.kernel.org

* fix btrfs default compression

* display $fscreateopt

* display_alert BTRFS_COMPRESSION

* try fix BTRFS_COMPRESSION variable not working

* debug fetch_from_repo

* configuration.sh debug BTRFS_COMPRESION

* update logic

* debug checking btrfs compression

* fix variable check,fix local variable usage

* [general] replace USE_MAINLINE_GOOGLE_MIRROR with MAINLINE_MIRROR

MAINLINE_MIRROR=google, use google provided mirror
MAINLINE_MIRROR=tuna, use tsinghua provided mirror
leave it empty, use official git.kernel.org

* [general] new option DOWNLOAD_MIRROR to select download mirror

current DOWNLOAD_MIRROR=china is used
the mirror is provided by tsinghua university

* Revert "try fix BTRFS_COMPRESSION variable not working"

This reverts commit 9814cfb054.

* Revert "debug fetch_from_repo"

This reverts commit ba571f0d89.

* add default compression method for mountopts

* remove useless var

* remove debug

* remove debug

* [general] set btrfs space cache based on kernel version

kernel version above 4.5 select 'v2' as default,
below 4.5 select 'v1' as default

* [general] reintroduce USE_MAINLINE_GOOGLE_MIRROR

* [general] case replaces 'if xx ;elif xxx;fi'

* [general] fix always downloading linux-firmware.git

clone to new dir 'linux-firmware-git' instead the old '$plugin_dir/lib/firmware'
,and then copy files as hardlinks.

* [general] create soft link instead of moving directory

* [btrfs] change rootfs subvolume name to @$RELEASE

now, the rootfs subvolume looks like @stretch,@bionic
it is possible to use different distribution in the same btrfs
partition.
2019-05-14 18:37:00 +02:00
2018-07-05 10:15:51 +02:00
2019-05-14 14:18:53 +02:00
2019-05-13 17:50:18 -04:00
2017-08-01 12:30:34 +03:00
2017-08-01 12:31:05 +03:00
2018-12-19 09:53:11 +02:00
2019-05-01 13:39:30 +02:00
2014-10-08 10:14:29 +02:00
2017-08-01 12:28:19 +03:00
2019-01-15 12:22:56 +01:00
2018-07-24 12:11:24 +00:00

Armbian

Debian based Linux for ARM based single-board computers

https://www.armbian.com

How to build an image or a kernel?

Supported build environment is Ubuntu Bionic 18.04 x64 (minimal iso image).

  • guest inside a VirtualBox or other virtualization software,
  • guest managed by Vagrant. This uses Virtualbox (as above) but does so in an easily repeatable way,
  • inside a Docker, systemd-nspawn or other container environment (example),
  • running natively on a dedicated PC or a server (not recommended),
  • 25GB disk space or more and 2GB RAM or more available for the VM, container or native OS,
  • superuser rights (configured sudo or root access).

Execution

apt-get -y install git
git clone https://github.com/armbian/build
cd build
./compile.sh

Make sure that full path to the build script does not contain spaces.

You will be prompted with a selection menu for a build option, a board name, a kernel branch and an OS release. Please check the documentation for advanced options and additional customization.

Build process uses caching for the compilation and the debootstrap process, so consecutive runs with similar settings will be much faster.

How to report issues?

Please read this notice first before opening an issue.

How to contribute?

  • Fork the project
  • Make one or more well commented and clean commits to the repository.
  • Perform a pull request in github's web interface.

If it is a new feature request, don't start the coding first. Remember to open an issue to discuss the new feature.

If you are struggling, check this detailed step by step guide on contributing.

Where to get more info?

Languages
Shell 68.7%
Python 9.5%
GSC 7.7%
JavaScript 5%
Batchfile 3.7%
Other 5.4%