Before running, if your host architecture is not loongarch64, you must first configure
qemu-user&binfmt.
docker run -it --rm --platform=linux/loong64 cake233/loong64-busybox
The following content discusses how this container is built.
git clone --depth=1 git://busybox.net/busybox.git git
cd git
make menuconfig
TUI: Settings --> Build Options --> [ * ] Build static binary (no shared libs) (i.e. CONFIG_STATIC=y ; CONFIG_STATIC_LIBGCC=y)
make defconfig
make -j4
make install
cd _install
doas tar -cvf ../../busybox.tar .
mkdir -p usr/lib
ln -s usr/lib lib
ln -s lib usr/lib64
ln -s usr/lib lib64
# $PWD is `path/to/_install`
pacman -r $PWD --dbpath /var/lib/pacman/ -S glibc
rm -rfv usr/share/*
FROM scratch
ADD busybox.tar /
CMD ["/bin/ash"]
Content type
Image
Digest
sha256:a82d47afc…
Size
1.2 MB
Last updated
over 3 years ago
docker pull cake233/loong64-busybox