Build Linux Image for HDL Coder

2 views (last 30 days)
John
John on 24 Feb 2025
Commented: John on 24 Feb 2025
I'm trying to follow along with the documentation here: https://www.mathworks.com/help/hdlcoder/ug/xilinx-zynq-linux-image-for-custom-boards.html for creating the Linux image using Mathwork's buildroot. Eventually I have a custom board that I need to create an image for but initially I was trying to build image for the Arrow SoC kit. I did a git clone https://github.com/mathworks/buildroot and I checked out the mathworks_socfpga_R23.2.0 tag. I ran the command:
python build.py -b sockit -p socfpga --brconfig BR2_TOOLCHAIN_EXTERNAL_PATH='/opt/linaro/aarch32-6.3.1-2017.02'
However, it keeps failing on:
Incorrect selection of kernel headers: expected 3.1.x, got 4.6.x
I'm not able to resolve this by changing the header selection in make menuconfig. I'd appreciate any suggestions on how to resolve this. Thank you.
  1 Comment
John
John on 24 Feb 2025
I got passed this error by editing the following lines of board/mathworks/socfpga/defconfig/linaro.defconfig:
BR2_TOOLCHAIN_EXTERNAL_GCC_6=y
BR2_TOOLCHAIN_EXTERNAL_HEADERS_4_6=y
However, I am now getting the error:
freadahead.c: In function 'freadahead':
freadahead.c:92:3: error: #error "Please port gnulib freadahead.c to your platform! Look at the definition of fflush, fread, ungetc on your system, then report this to bug-gnulib."
92 | #error "Please port gnulib freadahead.c to your platform! Look at the definition of fflush, fread, ungetc on your system, then report this to bug-gnulib."
| ^~~~~
Thanks for any help.

Sign in to comment.

Answers (0)

Categories

Find more on Code Generation in Help Center and File Exchange

Tags

Products


Release

R2024b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!