Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x230-maximized boards: build against coreboot 4.13 #949

Closed
wants to merge 1 commit into from

Conversation

tlaurion
Copy link
Collaborator

@tlaurion tlaurion commented Jan 2, 2021

Smaller step to #944 since t430 hypothesized to not boot. x230 only here.

@bwachter
Copy link

bwachter commented Jan 4, 2021

After spending way too long on this because parallel builds are broken I didn't get past the kernel compilation step:

$ make BOARD=x230-maximized build=/tmp/heads
[...]
make[2]: Leaving directory '/tmp/heads/coreboot-4.13'
2021-01-04 13:35:08+00:00 CONFIG coreboot
/tmp/heads/make-4.2.1/make \
        -C "/tmp/heads/linux-4.14.62" \
        INSTALL_HDR_PATH="/home/bwachter/git/misc/heads/install" \
        O="linux-4.14.62/linux-x230" \
        KCONFIG_CONFIG="/home/bwachter/git/misc/heads/config/linux-x230.config" \
        headers_install
make[2]: Entering directory '/tmp/heads/linux-4.14.62'
make[3]: Entering directory '/tmp/heads/linux-4.14.62/linux-4.14.62/linux-x230'
  CHK     include/generated/uapi/linux/version.h
make[4]: *** No targets specified and no makefile found.  Stop.
make[3]: *** [/tmp/heads/linux-4.14.62/Makefile:463: scripts_basic] Error 2
make[3]: Leaving directory '/tmp/heads/linux-4.14.62/linux-4.14.62/linux-x230'
make[2]: *** [Makefile:146: sub-make] Error 2
make[2]: Leaving directory '/tmp/heads/linux-4.14.62'
make[1]: *** [modules/linux:47: /home/bwachter/git/misc/heads/install/include/linux/limits.h] Error 2
make[1]: Leaving directory '/home/bwachter/git/misc/heads'
make: *** [Makefile:648: all] Error 2

@tlaurion
Copy link
Collaborator Author

tlaurion commented Jan 4, 2021

@bwachter can you elaborate? CI builds are building with
make BOARD=x230-maximized CPUS=4 V=1 without error as of right now, where #935 seems to be a thing, where I was't able to reproduce.

@tlaurion
Copy link
Collaborator Author

tlaurion commented Jan 4, 2021

@bwachter CircleCI building each commit is on debian-10. What is your host OS?
(Note that #950 should be merged, which stops CIs builds to randomly fails because of some gnu mirrors having bad https certs right now)

@tlaurion
Copy link
Collaborator Author

tlaurion commented Jan 4, 2021

@bwachter never specified build= before either.

@tlaurion
Copy link
Collaborator Author

tlaurion commented Jan 4, 2021

Rebasing on top of #950 for CI build (click green mark on next commit to go see live build and download produced artifacts). Lost too many days waiting for GNU to ban some non-compliant mirrors.

@bwachter
Copy link

bwachter commented Jan 5, 2021

I was trying to set MAKE_JOBS, as CPUS should get set in the Makefile, but I assume it's also not being propagated - when invoking make with CPUS set it does seem to work. That should be fixed (or at least documented), it's rather unexpected that -j doesn't work, no sensible amount of parallel tasks started automatically, and nothing mentioned in build instructions.

Still running into the same error building the Linux kernel, though. Full build log for make BOARD=x230-maximized CPUS=64 build=/tmp/heads on suse tumbleweed attached.

heads-build.log

@tlaurion
Copy link
Collaborator Author

tlaurion commented Jan 5, 2021

@bwachter i'm sorry, I do not use tumbleweed, which is a rolling release and you will probably hit problems no one else met.
What I see from the log you posted is that the Heads Makefile stops after installing linux kernel headers, while BOARD seems not to be passed.

From the OP
make[3]: *** [/tmp/heads/linux-4.14.62/Makefile:463: scripts_basic] Error 2

Which is

scripts_basic:
        $(Q)$(MAKE) $(build)=scripts/basic
        $(Q)rm -f .tmp_quiet_recordmcount

To me, it seems that you passing build=/tmp is confusing the build environment. Could you retry without it? Or clone Heads under /tmp completely, so that you build in RAM if that is what you intend to do? Or use debian-10 docker image as in CircleCI to build Heads? Can you confirm that you have the host tools equivalents as in working CircleCI recipe for tumbleweed? (Where i'm pretty sure build toolset is more recent and will result in incompatibilities other then make and gawk which are compiled for host as of right now because of fedora and debian host tools build differences.... This is why we try to get away of having to troubleshoot all host OSes and have a docker image based on guix, or coreboot-sdk docker image, to not run over build problems in the goal of having reproducibility without bumping our heads constantly at each OS release with problems like this, where tumbleweed will definitely create problems for reproducibility, if not basic building issues, without trying to compile in rom and mess around env variables further more).

cd /tmp/heads
git clone https://github.com/osresearch/heads
cd heads
make BOARD=x230-maximized CPUS=64

report back

@bwachter
Copy link

bwachter commented Jan 5, 2021

On a leap 15.1 I have it failing late at the blobs (which is expected, as I didn't put anything there yet). Difference is make 4.2.1 vs make 4.3. I pretty much never run into toolchain issues on tumbleweed, and if I do it's generally rather obvious issues with the compiler or libraries. I'd recommend adding at least occasional builds on other distributions to CI and fix up the build system to behave better - that kind of very specific toolchain dependency tends to become a big burden and ties projects to outdated distributions for building eventually.

@tlaurion
Copy link
Collaborator Author

tlaurion commented Jan 5, 2021

Needs #954 related changes

@tlaurion tlaurion changed the title x230-maximized boards: build against coreboot 4.13 (BRICKS T430) x230-maximized boards: build against coreboot 4.13 Jan 6, 2021
@tlaurion tlaurion changed the title (BRICKS T430) x230-maximized boards: build against coreboot 4.13 x230-maximized boards: build against coreboot 4.13 Jan 6, 2021
@tlaurion
Copy link
Collaborator Author

tlaurion commented Jan 17, 2021

@bwachter I can't build in memory like you do with build=/tmp/heads

Please retry and report by doing:
make BOARD=x230-maximized CPUS=64 V=1 and post back results.

Note the successful CI build recipe:
1- build requirements
2- Blobs placed in searched blobs dirs prior of coreboot module being built
3- make call to build with 4 CPUS having debugging trace.

From the log you pasted, my eyes see no error to work on. My best hypothesis is that building in memory doesn't seem to be a passed argument, where I can't replicate easily (CIs won't accept to take that much memory).
Your build:

  • Sees mismatch in gawk version, compiles locally.
  • Sees mismatch in make, compiles locally.
    Then fails at kernel install step, which is one of the first step on global makefile.

@tlaurion
Copy link
Collaborator Author

tlaurion commented Feb 9, 2021

Considering the comments here are linked to buildsystem errors that can be mitigated per instructions, and not specific to this x230 board being bumped to coreboot 4.13, unless opposition, I will merge this PR in the following days.

@tlaurion
Copy link
Collaborator Author

tlaurion commented Feb 9, 2021

make BOARD=x230-maximized CPUS=64 build=/tmp/heads

@bwachter : this issue should be filed into another issue called : "Cannot build in memory" and/or "Cannot build in Tumbleweed".

Successfull builds are happening https://circleci.com/gh/osresearch/heads at each merged commit on top of debian-10 docker image following CircleCI file provided in tree.

@MrChromebox
Copy link
Contributor

@tlaurion thx for testing. Will have to try and figure out why Qubes 4.0.4 hangs with coreboot 4.11+ on Librem 13/15s then (no issue on Mini v1/v2/L14)

@tlaurion
Copy link
Collaborator Author

tlaurion commented Aug 9, 2021

Superseded by #1015

@tlaurion tlaurion closed this Aug 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants