Firefly Open Source Community

Title: Error when building the Linux SDK [Print This Page]

Author: balbes150    Time: 5/28/2022 15:04
Title: Error when building the Linux SDK
I am trying to build ubuntu firmware for R1 using the instruction.

https://wiki.t-firefly.com/en/Cl ... tion.html#linux-sdk

When I run the build, I get an error.

  1. user@user-VirtualBox:~/r1/rk3399_linux_release_v2.5.1_20210301$ ./build.sh kernel
  2. processing option: kernel
  3. ============Start building kernel============
  4. TARGET_ARCH          =arm64
  5. TARGET_KERNEL_CONFIG =firefly_linux_defconfig
  6. TARGET_KERNEL_DTS    =rk3399-firefly-CS-R1-jd4-sub
  7. TARGET_KERNEL_CONFIG_FRAGMENT =
  8. ==========================================
  9. /home/user/r1/rk3399_linux_release_v2.5.1_20210301
  10. #
  11. # configuration written to .config
  12. #
  13. scripts/kconfig/conf  --silentoldconfig Kconfig
  14.   CHK     include/config/kernel.release
  15.   CHK     include/generated/uapi/linux/version.h
  16.   HOSTLD  scripts/dtc/dtc
  17.   CHK     scripts/mod/devicetable-offsets.h
  18.   CHK     include/generated/utsrelease.h
  19. /usr/bin/ld: scripts/dtc/dtc-parser.tab.o:(.bss+0x10): §á§à§Ó§ä§à§â§ß§à§Ö §à§á§â§Ö§Õ§Ö§Ý§Ö§ß§Ú§Ö «yylloc»; scripts/dtc/dtc-lexer.lex.o:(.bss+0x0): §Ù§Õ§Ö§ã§î §á§Ö§â§Ó§à§Ö §à§á§â§Ö§Õ§Ö§Ý§Ö§ß§Ú§Ö
  20. collect2: error: ld returned 1 exit status
  21. make[2]: *** [scripts/Makefile.host:100: scripts/dtc/dtc] §°§ê§Ú§Ò§Ü§Ñ 1
  22. make[1]: *** [scripts/Makefile.build:484: scripts/dtc] §°§ê§Ú§Ò§Ü§Ñ 2
  23. make: *** [Makefile:579: scripts] Error 2
  24. make: *** Waiting for unfinished jobs....
  25.   CHK     include/generated/timeconst.h
  26.   CHK     include/generated/bounds.h
  27.   CHK     include/generated/asm-offsets.h
  28.   CALL    scripts/checksyscalls.sh
  29. ERROR: Running build_kernel failed!
  30. ERROR: exit code 2 from line 721:
  31.     make ARCH=$RK_ARCH $RK_KERNEL_DTS.img -j$RK_JOBS
Copy the code

Author: 895816513    Time: 5/28/2022 17:29
Please confirm the installation of the following files

  1. sudo apt-get update

  2. sudo apt-get install repo git-core gitk git-gui gcc-arm-linux-gnueabihf u-boot-tools device-tree-compiler \
  3. gcc-aarch64-linux-gnu mtools parted libudev-dev libusb-1.0-0-dev python-linaro-image-tools \
  4. linaro-image-tools gcc-arm-linux-gnueabihf libssl-dev liblz4-tool genext2fs lib32stdc++6 \
  5. gcc-aarch64-linux-gnu g+conf autotools-dev libsigsegv2 m4 intltool libdrm-dev curl sed make \
  6. binutils build-essential gcc g++ bash patch gzip bzip2 perl tar cpio python unzip rsync file bc wget \
  7. libncurses5 libqt4-dev libglib2.0-dev libgtk2.0-dev libglade2-dev cvs git mercurial rsync openssh-client \
  8. subversion asciidoc w3m dblatex graphviz python-matplotlib libssl-dev texinfo fakeroot \
  9. libparse-yapp-perl default-jre patchutils swig chrpath diffstat gawk
Copy the code



refer: https://wiki.t-firefly.com/en/Co ... ux_compile_gpt.html
Author: balbes150    Time: 5/29/2022 14:43
895816513 Posted at 5/28/2022 12:29
Please confirm the installation of the following files

Yes, I have installed these packages, but some packages are missing from the repository.

E: §¯§Ö§Ó§à§Ù§Þ§à§Ø§ß§à §ß§Ñ§Û§ä§Ú §á§Ñ§Ü§Ö§ä python-linaro-image-tools
E: §¯§Ö§Ó§à§Ù§Þ§à§Ø§ß§à §ß§Ñ§Û§ä§Ú §á§Ñ§Ü§Ö§ä linaro-image-tools
E: §¯§Ö§Ó§à§Ù§Þ§à§Ø§ß§à §ß§Ñ§Û§ä§Ú §á§Ñ§Ü§Ö§ä libqt4-dev
E: §¥§Ý§ñ §á§Ñ§Ü§Ö§ä§Ñ «python-matplotlib» §ß§Ö §ß§Ñ§Û§Õ§Ö§ß §Ü§Ñ§ß§Õ§Ú§Õ§Ñ§ä §ß§Ñ §å§ã§ä§Ñ§ß§à§Ó§Ü§å

Which version Ubuntu is recommended to use ?

I use

DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=21.10
DISTRIB_CODENAME=impish
DISTRIB_DESCRIPTION="Ubuntu 21.10"


Author: balbes150    Time: 5/30/2022 01:11
Switched to Ubuntu 18.04LTS, the build works without errors.
It is advisable to specify the Ubuntu version in the documentation so that you immediately know which version to use.

By the way, as an option, it is desirable to release a version of Docker with a build system (without sources).
Author: balbes150    Time: 5/30/2022 20:02
rootfs  ubuntu is used to build the firmware for R1. The link from the wiki page for r1 leads to baidu, but it is not possible to download the archives (the service blocks sending outside of China). when trying to download rootfs from the firefly-rk3399 download page, it gives the message "not pages".


https://drive.google.com/drive/f ... VcG5Qc5qkgWaxnTi6-9


How can I build my own version of rootfs for R1 locally ?

Author: 895816513    Time: 5/31/2022 14:50
balbes150 Posted at 5/30/2022 01:11
Switched to Ubuntu 18.04LTS, the build works without errors.
It is advisable to specify the Ubuntu ...

Thanks for your suggestion, I have made the recommended changes.
Author: 895816513    Time: 5/31/2022 14:52
balbes150 Posted at 5/30/2022 20:02
rootfs  ubuntu is used to build the firmware for R1. The link from the wiki page for r1 leads to bai ...

https://en.t-firefly.com/doc/download/71.html#other_117
Author: balbes150    Time: 5/31/2022 15:01
895816513 Posted at 5/31/2022 09:50
Thanks for your suggestion, I have made the recommended changes.

Tnx

I wrote a Dockerfile that builds an image of an assembly system.

By the way, I have collected test firmware versions for R1. Can you check them (I don't have an AIO board to flash the rk3399-jd4 module if my firmware doesn't work correctly) ?

https://disk.yandex.ru/d/ZinDgPfp_C4xXg
Author: 895816513    Time: 5/31/2022 15:29
The sub board can be forcibly upgraded through the main board. If the firmware of the main board is wrong, you can make a TF upgrade card to upgrade the main board.

By the way, I'm uploading 4 rootfs, it will take about 3.5 hours, you check google drive when you get there.

  1. Ubuntu18.04-Lxde_RK3399PRO_v2.11-56_20220527.img.7z
  2. Ubuntu20.04-Gnome_RK3399PRO_v2.11-56_20220526.img.7z
  3. Ubuntu18.04-Minimal_RK3399PRO_v2.11-56_20220526.img.7z
  4. Ubuntu20.04-Minimal_RK3399PRO_v2.11-56_20220526.img.7z
Copy the code

Author: balbes150    Time: 5/31/2022 15:34
It is also desirable to fix a few minor errors in the documentation (this is not critical, but it can confuse a beginner). Some commands have extra spaces after the dot. There are such typos in different pages for other models (rk3399-jd4). For example.

. /build.sh CS-R1-3399-jd4-sub-ubuntu.mk

#Fully automated compiled firmware
$ . /build.sh

#Partial compilation

$ . /build.sh kernel
$ . /build.sh uboot
$ . /build.sh recovery

# Run . /mkfirmware.sh will automatically update the link to rockdev/rootfs.img.
$ . /build.sh firmware
Author: 895816513    Time: 5/31/2022 17:43
balbes150 Posted at 5/31/2022 15:34
It is also desirable to fix a few minor errors in the documentation (this is not critical, but it ca ...

Thank you for your feedback, it should be an error in text processing, we have made changes to the above problems.
Author: balbes150    Time: 5/31/2022 19:49
895816513 Posted at 5/31/2022 10:29
The sub board can be forcibly upgraded through the main board. If the firmware of the main board is  ...

Thanks. I have already downloaded these images and created firmware based on them

The question is, where can I find out how to build my version of rootfs correctly, what additional files\packages\settings special for firefly need to be used. I want to create a firmware with Armbian and AltLinux, which can be installed using standard BMC tools (now I have to manually write everything into modules and this takes a lot of time and is not suitable for mass use).
Author: balbes150    Time: 6/3/2022 17:58
taylorchan067 Posted at 6/2/2022 19:03
Did you get the solution on how to fix it. Because I am facing the same issue with my device and not ...

Write in detail what problem you are talking about and on what device.




Welcome Firefly Open Source Community (https://bbs.t-firefly.com/) Powered by Discuz! X3.1