Buildroot 2017.08 compile fail
Closed this issue · 9 comments
Hi, I have the minibase-br 2018-02-10 release, and followed instructions. Buildroot fails with this message:
make[6]: *** No rule to make target '../src/c++11/libc++11convenience.la', needed by 'libstdc++.la'. Stop.
make[6]: Leaving directory '/mnt/sdc1/downloads2/input524/0-minibase-br/minibase-br/buildroot/output/build/host-gcc-final-6.4.0/build/x86_64-buildroot-linux-musl/libstdc++-v3/src'
make[5]: *** [Makefile:638: all-recursive] Error 1
Buildroot is host-sensitive. What host do you run on, that works?
Note, I am running EasyOS, which is a distribution compiled from source, so not a derivative of any of the mainline distros.
I am running host gcc 6.3.0, glibc 2.25, x86_64, 4.14.91 kernel.
Buildroot actually tries quite hard to not be particularly host-sensitive. I'm mostly running it on Arch hosts myself but I think it should work even on busybox-based distros.
The root cause for the failure should be above the quoted lines. Also check https://buildroot.org/downloads/manual/manual.html#requirement although I think it would report if any of the tools were missing.
Try building the same Buildroot version without minibase-br config, something like qemu_x86_64_defconfig
, to isolate the problem.
Interesting, tried an experiment, ran "make menuconfig" and made one change, "musl" to "glibc", then ran "make".
The interesting part is that compiling glibc went into an endless loop. I applied a patch, found here:
The patch worked. Very strange problem though, never encountered it before.
But then there was a failure with installing "xproto", trying to create directories that already exist.
I give up. Years ago, I played with Buildroot, had so much trouble. Same thing is happening now. What I use is OpenEmbedded/Yocto, or rather, my fork of it:
https://github.com/bkauler/oe-qky-src
For me, OE is rock-solid, builds on any distro. I am fascinated by what you have done, a complete rethink of the basics of a Linux distro. I plan to study minibase some more, especially how you have handled network management. If I want to compile a filesystem running on minibase, I will use my fork of OE.
If you haven't yet, try prebuilt.tar.xz. The parts that come from Buildroot aren't particularly interesting, and you'll get binaries there. It should be possible to build a similar system in Yocto, check the expected structure and try to get something similar. I'm afraid I won't be able to help with that though, my experience with Yocto mirrors yours with Buildroot. Just keep in mind X must be patched to work with vtmux. Weston doesn't, but if you want X you have to patch xserver.
Also if you're going to dig deeper, note that networking and wifi tools has been significantly reworked since then. That version should work, but current one is quite different design-wise. The rest remains more or less the same. I'm planning to update minibase-br once I'm done with what I'm doing in minibase now, but that would be in several weeks I guess.
Thanks for the feedback. Yes, I have been looking at your latest minibase in github, noticed it is different.
I will study the Xorg patch.
Note, I did a quick blog post about minibase a couple of days ago:
http://bkhome.org/news/201902/minibase-super-tiny-static-system.html
I have confirmed, it is necessary to be running the right host distribution.
I had tried with EasyOS and Quirky Linux, both failed, also tried the latest stable buildroot, also failed.
So, I downloaded Slackware x86_64 version 14.2, 2.6GB ISO file, and installed it, chose most of the packages -- just about everything, just left out the KDE and tcl/tk packages.
Can't get more plain-vanilla-Linux than Slackware, and a long way from bleeding-edge as 14.2 was released in 2016.
Yes, it works, buildroot in minibase-br compiled. That's good, now I have a host that works with buildroot.
A couple of issues though, with minibase-br. Following your instructions (note, a bit picky, but the "../" was missing):
# cd ../sys-1-plain
# make
./rootfs.sh: line 35: fakeroot: command not found
...I deleted the text "fakeroot". Slackware does not have fakeroot, perhaps it is in an extra package, but I am unfamiliar with the package management, running xfce, but there was no gui for package management, presume it is a commandline thing.
Anyway, I was logged in as root, so just deleting "fakeroot" was fine.
The next issue was this:
mkfs.fat 3.0.28 (2015-05-16)
/usr/lib/syslinux/efi64/syslinux.efi: No such file or directory
...slackware has /usr/share/syslinux, however, efi64/syslinux.efi is missing, no 'efi64' folder.
Maybe there is a package for that too. Note, Slackware has syslinux in /usr/share/syslinux, so if there is a package with 'efi64' folder, then it would likely be under that path.
I had expected Slackware 15.0 to be out by now, but the main developer, Patrick, had issues to deal with in 2018, so things have got held up. I will see if I can chase-up those extra packages, and if there is a 15.0beta.
Regarding syslinux, if you don't need it to be EFI-bootable, just skip the EFI parts. It's not really important. It's ok to skip all mmd
and mcopy
commands. The result should still be MBR-bootable, perfect for qemu, and most hardware should still accept it.
Grub or LILO should work as well, you'll only need to figure out how to install them onto a disk image. Any bootloader that can be configured to load the kernel and initrd should be enough.
The only things that the userspace relies on is label-id, and the root partition being partition #2. Update etc/blktab
if you need some other configuration.
By the way, Buildroot should built host-fakeroot
itself, I don't even think it's configurable. It should be somewhere in output/host/
.
If you are running as root, it's ok to skip it however. The only reason it's there is that mkfs.ext4 -d $dir
picks file ownership from $dir and there are no other means to override that.
Ok. Just to round off this thread, I got it to finish without error.
Searched the Slackware 14.2 packages repo online, only has syslinux 4.07, no efi support. So, I manually installed this package:
...it has /usr/share/syslinux/efi32
and efi64
. Note, PET packages are just tarballs with a checksum appended, so tar -xf syslinux6_modules_efi-6.0.3.pet
would work.
Then, instead of changing minibase-br, created symlinks:
# mkdir /usr/lib/syslinux
# cd /usr/lib/syslinux
# ln -s /usr/share/syslinux bios
# ln -s /usr/share/syslinux/efi32 efi32
# ln -s /usr/share/syslinux/efi64 efi64
Wrote whole.img
to a USB stick, got a proper UEFI compatible bootup, and got to the fluxbox desktop.