You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi there,
I'm currently encountering a linking error while trying to compile BusyBox on my Ubuntu 20.04 system. I have tried checking for missing libraries, but the issue persists.Here are the details of the error:
First Step
I tried to boot linux with u-boot ,but it failed as the lack of init process.
Here is the output info below:
[ 0.179696] platform 502b0000.pinmux: Fixed dependency cycle(s) with /soc/bus@50200000/pinmux@502b0000/jtag-pinmux
[ 0.195124] platform 50440000.syscon: Fixed dependency cycle(s) with /soc/bus@50400000/syscon@50440000/clock-controller
[ 0.210875] k210-sysctl 50440000.syscon: K210 system controller
[ 0.222554] k210-rst 50440000.syscon:reset-controller: K210 reset controller
[ 0.230191] 38000000.serial: ttySIF0 at MMIO 0x38000000 (irq = 1, base_baud = 24375000) is a SiFive UART v0
[ 0.239278] printk: console [ttySIF0] enabled
[ 0.239278] printk: console [ttySIF0] enabled
[ 0.247891] printk: bootconsole [sifive0] disabled
[ 0.247891] printk: bootconsole [sifive0] disabled
[ 0.259842] cacheinfo: Unable to detect cache hierarchy for CPU 0
[ 0.268511] spi spi1.0: setup: ignoring unsupported mode bits a00
[ 0.274610] i2c_dev: i2c /dev entries driver
[ 0.290696] k210-fpioa 502b0000.pinmux: K210 FPIOA pin controller
[ 0.332473] mmc_spi spi3.0: SD/MMC host mmc0, no WP, no poweroff, cd polling
[ 0.343051] Waiting for root device /dev/mmcblk0p2...
[ 0.364506] mmc0: host does not support reading read-only switch, assuming write-enable
[ 0.371805] mmc0: new SDHC card on SPI
[ 0.377328] mmcblk0: mmc0:0000 SA16G 14.4 GiB
[ 0.416484] mmcblk0: p1 p2
[ 0.434923] VFS: Mounted root (ext2 filesystem) readonly on device 179:2.
[ 0.446836] devtmpfs: mounted
[ 0.449442] Freeing unused kernel image (initmem) memory: 116K
[ 0.454893] This architecture does not have kernel memory protection.
[ 0.461327] Run /sbin/init as init process
[ 0.465600] Run /etc/init as init process
[ 0.475219] Run /bin/init as init process
[ 0.478709] Run /bin/sh as init process
[ 0.482493] Kernel panic - not syncing: No working init found. Try passing init= option to kernel. See Linux Documentation/admin-guide/init.rst for guidance.
[ 0.496442] SMP: stopping secondary CPUs
[ 0.500363] ---[ end Kernel panic - not syncing: No working init found. Try passing init= option to kernel. See Linux Documentation/admin-guide/init.rst for guidance. ]---
Second
So, I guess may be it is the result of lack of BusyBox which built failed that I skipped before:
$ make SKIP_STRIP=y
CC applets/applets.o
In file included from include/libbb.h:13,
from include/busybox.h:8,
from applets/applets.c:9:
include/platform.h:164:11: fatal error: byteswap.h: No such file or directory
164 | # include <byteswap.h>
| ^~~~~~~~~~~~
compilation terminated.
make[1]: *** [scripts/Makefile.build:198: applets/applets.o] Error 1
make: *** [Makefile:372: applets_dir] Error 2
after that I tried with k210-linux-nommu/busybox$ make SKIP_STRIP=y CFLAGS="-I/opt/riscv64-uclibc/host/riscv64-buildroot-linux-uclibc/sysroot/usr/include"
but it return with
/opt/riscv64-uclibc/riscv64-buildroot-linux-uclibc/bin/ld.real: cannot find crt1.o: No such file or directory
collect2: error: ld returned 1 exit status
Note: if build needs additional libraries, put them in CONFIG_EXTRA_LDLIBS.
Example: CONFIG_EXTRA_LDLIBS="pthread dl tirpc audit pam"
make: *** [Makefile:718: busybox_unstripped] Error 1
And it not works with k210-linux-nommu/busybox$ make SKIP_STRIP=y CFLAGS="-I/opt/riscv64-uclibc/host/riscv64-buildroot-linux-uclibc/sysroot/usr/include" CONFIG_EXTRA_LDLIBS="/opt/riscv64-uclibc/host/riscv64-buildroot-linux-uclibc/sysroot/usr/lib/crt1.o"
still return the error:
/opt/riscv64-uclibc/riscv64-buildroot-linux-uclibc/bin/ld.real: cannot find crt1.o: No such file or directory
collect2: error: ld returned 1 exit status
Note: if build needs additional libraries, put them in CONFIG_EXTRA_LDLIBS.
Example: CONFIG_EXTRA_LDLIBS="pthread dl tirpc audit pam"
make: *** [Makefile:718: busybox_unstripped] Error 1
The text was updated successfully, but these errors were encountered:
Hi there,
I'm currently encountering a linking error while trying to compile BusyBox on my Ubuntu 20.04 system. I have tried checking for missing libraries, but the issue persists.Here are the details of the error:
First Step
I tried to boot linux with u-boot ,but it failed as the lack of
init process
.Here is the output info below:
Second
So, I guess may be it is the result of lack of BusyBox which built failed that I skipped before:
I find the files it needs
and then check the PATH is set
Third
after that I tried with
k210-linux-nommu/busybox$ make SKIP_STRIP=y CFLAGS="-I/opt/riscv64-uclibc/host/riscv64-buildroot-linux-uclibc/sysroot/usr/include"
but it return with
And it not works with
k210-linux-nommu/busybox$ make SKIP_STRIP=y CFLAGS="-I/opt/riscv64-uclibc/host/riscv64-buildroot-linux-uclibc/sysroot/usr/include" CONFIG_EXTRA_LDLIBS="/opt/riscv64-uclibc/host/riscv64-buildroot-linux-uclibc/sysroot/usr/lib/crt1.o"
still return the error:
The text was updated successfully, but these errors were encountered: