MiSTeX-devel / MiSTeX-buildroot

Root filesystem for the Linux part of MiSTeX
MIT License
4 stars 5 forks source link

Cannot "make image" #1

Closed siffland closed 1 year ago

siffland commented 1 year ago

I know this is very early and was just trying to play along and create an image. If i follow the instruction in the readme i get the following error:

./confdata.c:1046:2: note: 'sprintf' output between 20 and 4116 bytes into a destination of size 4097
 1046 |  sprintf(buf, "%s.tmpconfig_tristate", dir);
      |  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./confdata.c:1054:18: warning: '.tmpconfig' directive writing 10 bytes into a region of size between 1 and 4097 [-Wformat-overflow=]
 1054 |  sprintf(buf, "%s.tmpconfig", dir);
      |                  ^~~~~~~~~~
./confdata.c:1054:2: note: 'sprintf' output between 11 and 4107 bytes into a destination of size 4097
 1054 |  sprintf(buf, "%s.tmpconfig", dir);
      |  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/bin/gcc -I/usr/include/ncursesw -DCURSES_LOC="<curses.h>"  -DNCURSES_WIDECHAR=1 -DLOCALE  -I/home/br-user/out/mistex/build/buildroot-config -DCONFIG_=\"\"   /home/br-user/out/mistex/build/buildroot-config/conf.o /home/br-user/out/mistex/build/buildroot-config/zconf.tab.o  -o /home/br-user/out/mistex/build/buildroot-config/conf
rm /home/br-user/out/mistex/build/buildroot-config/zconf.tab.c
  GEN     /home/br-user/out/mistex/Makefile
#
# configuration written to /home/br-user/out/mistex/.config
#
make[1]: Leaving directory '/home/br-user/out/buildroot-lichee'
BR2_DL_DIR=/home/br-user/out/dl BR2_JLEVEL=2 \
        make -C out/mistex BR2_EXTERNAL=/home/br-user/buildroot-external source all
make[1]: Entering directory '/home/br-user/out/mistex'
package/pkg-generic.mk:225: *** BR2_GLOBAL_PATCH_DIR contains nonexistent directory board/lichee/patches.  Stop.
make[1]: *** [Makefile:23: _all] Error 2
make[1]: Leaving directory '/home/br-user/out/mistex'
make: *** [Makefile:53: image] Error 2
root@76dbaa271d55:/home/br-user# 

Using a fresh Ubuntu and Docker install. Just want to help make the docs a little better and play along. Also would not mind seeing if the image works on a mango pi (since it has the same foot print as a pi zero).

hansfbaier commented 1 year ago

OK thanks for reporting this. I just pushed a fix. Please try this:

git pull
make rootshell
make mistex defconfig
make image
hansfbaier commented 1 year ago

And I see no reason why it shouldn't work with the Mango Pi as long as it uses the Allwinner D1 and you connect the same pins.

hansfbaier commented 1 year ago

After the image is built, you will run into issues with openFPGALoader. I am preparing a fix for that.

siffland commented 1 year ago

Awesome, it is compiling now, my build VM is a bit slow. The Mango Pi does use a D1 and is the same form factor as a Raspberry Pi zero (I believe the GPIO is the same), and I have it laying around. I ordered a DECA board to play with, but it has not arrived yet.

I think this project is great for the community moving forward.

hansfbaier commented 1 year ago

OK I am now done with fixing myopenFPGALoader. Please pull again.

hansfbaier commented 1 year ago

@siffland Ordering the DECA was a bit quick. I actually chose the DECA, because I thought it was not available anymore. Where were you able to get it? As it turned out, if using HDMI its resources (especially BRAM) are way too small for most cores. You could only run Template and Menu_MiSTeX. Main target going forward will be the QMTech Artix100T board. There are, however, efforts by a south american retro computing group (lead by @somhi) to use the MiSTeX menu system to load non-MiSTer cores, with the DeMiSTify framework.

siffland commented 1 year ago

No worries, the XC7A100T is the one i ordered. For some reason when i posted above I got the names mixed up. The DECA is was no where in stock anywhere.

It is compiling again.

hansfbaier commented 1 year ago

OK I just ran a successful image build with this


>>>   Executing post-image script support/scripts/genimage.sh
board/aw-ol/d1/genimage.cfg:45: no sub-section title/index for 'config'
INFO: cmd: "mkdir -p "/home/br-user/out/mistex/build/genimage.tmp"" (stderr):
INFO: cmd: "rm -rf "/home/br-user/out/mistex/build/genimage.tmp"/*" (stderr):
INFO: cmd: "mkdir -p "/home/br-user/out/mistex/build/genimage.tmp"" (stderr):
INFO: cmd: "cp -a "/tmp/tmp.d4OUigaqgI" "/home/br-user/out/mistex/build/genimage.tmp/root"" (stderr):
INFO: cmd: "find '/home/br-user/out/mistex/build/genimage.tmp/root' -depth -type d -printf '%P\0' | xargs -0 -I {} touch -r '/tmp/tmp.d4OUigaqgI/{}' '/home/br-user/out/mistex/build/genimage.tmp/root/{}'" (stderr):
INFO: cmd: "mkdir -p "/home/br-user/out/mistex/images"" (stderr):
INFO: vfat(boot.vfat): cmd: "dd if=/dev/zero of="/home/br-user/out/mistex/images/boot.vfat" seek=33554432 count=0 bs=1 2>/dev/null" (stderr):
INFO: vfat(boot.vfat): cmd: "mkdosfs   '/home/br-user/out/mistex/images/boot.vfat'" (stderr):
INFO: vfat(boot.vfat): adding file 'boot.img' as 'boot.img' ...
INFO: vfat(boot.vfat): cmd: "MTOOLS_SKIP_CHECK=1 mcopy -bsp -i '/home/br-user/out/mistex/images/boot.vfat' '/home/br-user/out/mistex/images/boot.img' '::'" (stderr):
INFO: vfat(boot.vfat): adding file 'Image' as 'Image' ...
INFO: vfat(boot.vfat): cmd: "MTOOLS_SKIP_CHECK=1 mcopy -bsp -i '/home/br-user/out/mistex/images/boot.vfat' '/home/br-user/out/mistex/images/Image' '::'" (stderr):
INFO: vfat(boot.vfat): adding file 'board.dtb' as 'board.dtb' ...
INFO: vfat(boot.vfat): cmd: "MTOOLS_SKIP_CHECK=1 mcopy -bsp -i '/home/br-user/out/mistex/images/boot.vfat' '/home/br-user/out/mistex/images/board.dtb' '::'" (stderr):
INFO: hdimage(sdcard.img): adding partition 'boot0' from 'boot0_sdcard.fex' ...
INFO: hdimage(sdcard.img): adding partition 'boot-packages' from 'boot_package.fex' ...
INFO: hdimage(sdcard.img): adding partition 'env' (in MBR) from 'env.fex' ...
INFO: hdimage(sdcard.img): adding partition 'env-redund' (in MBR) from 'env.fex' ...
INFO: hdimage(sdcard.img): adding partition 'boot' (in MBR) from 'boot.vfat' ...
INFO: hdimage(sdcard.img): adding partition 'rootfs' (in MBR) from 'rootfs.ext4' ...
INFO: hdimage(sdcard.img): writing GPT
INFO: hdimage(sdcard.img): writing hybrid MBR
make[1]: Leaving directory '/home/br-user/out/mistex'
root@10ef20078c1d:/home/br-user# ls out/mistex/images/ -l
total 1733800
-rw-r--r-- 1 root root   10547372 May 14 21:46 Image
[...]
Closing this ticket.