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

"nitropad-nv41: neither CONFIG_COREBOOT nor CONFIG_LINUXBOOT is set?" #1798

Closed
3 tasks done
boredsquirrel opened this issue Sep 19, 2024 · 9 comments
Closed
3 tasks done

Comments

@boredsquirrel
Copy link

boredsquirrel commented Sep 19, 2024

Context of the Build

1. What board are you trying to build?
nitropad-nv41 from dasharo/heads

2. What repository:branch are you using to build from?

  • dasharo/heads:Master
  • dasharo/heads:rel_novacustom_nv4x_adl_v0.9.1
  • dasharo/heads:novacustom_laptops

3. What version of coreboot are you trying to build

Dasharo@0af2459

dasharo heads for a Clevo NV41MZ (11th gen)

4. In building the rom where did you get the blobs?

  • not applicable yet

5. If using the automated tools to get the blobs did you run the relevant scripts in the blobs directory

  • not applicable yet

6. What operating system are you using

  • Fedora 40 Podman/Distrobox container image
  • git-2.46.1-1.fc40.x86_64
  • make-4.4.1-6.fc40.x86_64

Please describe the problem

Describe the bug

on either branch:

make BOARD=nitropad-nv41
Makefile:208: *** "nitropad-nv41: neither CONFIG_COREBOOT nor CONFIG_LINUXBOOT is set?".  End.

I also tried setting that variable

export CONFIG_COREBOOT="/path/to/heads/config/coreboot-nitropad-nv41.config"

CONFIG_COREBOOT="/path/to/heads/config/coreboot-nitropad-nv41.config"

make BOARD=nitropad-nv41 CONFIG_COREBOOT="/path/to/heads/config/coreboot-nitropad-nv41.config"

Still the same error

The Makefile at that place:

 199   │ # Bring in all of the module definitions;
 200   │ # these are the external pieces that will be downloaded and built
 201   │ # as part of creating the Heads firmware image.
 202   │ include modules/*
 203   │ 
 204   │ define bins =
 205   │ $(foreach m,$1,$(call prefix,$(build)/$($m_dir)/,$($m_output)))
 206   │ endef
 207   │ define libs =
 208   │ $(foreach m,$1,$(call prefix,$(build)/$($m_dir)/,$($m_libraries)))
 209   │ endef

@mkopec

@boredsquirrel
Copy link
Author

uhm why should I install a random zip file from Mega?

@tlaurion
Copy link
Collaborator

tlaurion commented Sep 19, 2024

@boredsquirrel I understand you are trying to build Heads the old way. The new way is already documented on both heads-wiki (https://osresearch.net) and https://github.com/linuxboot/heads?tab=readme-ov-file#building-heads

You should have landed here: https://github.com/linuxboot/heads?tab=readme-ov-file#pull-docker-hub-image-to-prepare-reproducible-roms-as-circleci-in-one-call

TLDR, one call operation to build nv41 Heads master rom after git clone of the repo with docker installed :
docker run -e DISPLAY=$DISPLAY --network host --rm -ti -v $(pwd):$(pwd) -w $(pwd) tlaurion/heads-dev-env:latest -- make BOARD=nitropad-nv41

This is since May 02 2024, where Nix reproducible buildstack was merged with this PR #1661

Since then, you can use prepared reproducible docker image to produce reproducible ROM for linuxboot/heads (here), where other Heads distro will have their own build recipes to follow.

Please reopen this issue if you consider it was closed too quickly. I have no clue why you say you have to dowload randmim zip file from Mega either.


Cannot reproduce. Closing.

user@heads-tests-deb12-nix:~/heads$ docker run -e DISPLAY=$DISPLAY --network host --rm -ti -v $(pwd):$(pwd) -w $(pwd) tlaurion/heads-dev-env:latest -- make BOARD=nitropad-nv41
----------------------------------------------------------------------
!!!!!! BUILD SYSTEM INFO !!!!!!
System CPUS: 12
System Available Memory: 14999 GB
System Load Average: 0.03
----------------------------------------------------------------------
Used **CPUS**: 12
Used **LOADAVG**: 18
Used **AVAILABLE_MEM_GB**: 14998 GB
----------------------------------------------------------------------
**MAKE_JOBS**: -j12 --load-average=18 

Variables available for override (use 'make VAR_NAME=value'):
**CPUS** (default: number of processors, e.g., 'make CPUS=4')
**LOADAVG** (default: 1.5 times CPUS, e.g., 'make LOADAVG=54')
**AVAILABLE_MEM_GB** (default: memory available on the system in GB, e.g., 'make AVAILABLE_MEM_GB=4')
**MEM_PER_JOB_GB** (default: 1GB per job, e.g., 'make MEM_PER_JOB_GB=2')
----------------------------------------------------------------------
!!!!!! Build starts !!!!!!
if [ ! -e "/home/user/heads/build/x86/coreboot-dasharo/.canary" ]; then git clone https://github.com/dasharo/coreboot "/home/user/heads/build/x86/coreboot-dasharo"; git -C "/home/user/heads/build/x86/coreboot-dasharo" reset --hard 3a9aa3a4692f3dd49732f5b4e3ec54be385f0969; echo -n 'https://github.com/dasharo/coreboot|3a9aa3a4692f3dd49732f5b4e3ec54be385f0969' > "/home/user/heads/build/x86/coreboot-dasharo/.canary"; elif [ "$(cat "/home/user/heads/build/x86/coreboot-dasharo/.canary")" != 'https://github.com/dasharo/coreboot|3a9aa3a4692f3dd49732f5b4e3ec54be385f0969' ]; then echo "Switching coreboot-dasharo to https://github.com/dasharo/coreboot at 3a9aa3a4692f3dd49732f5b4e3ec54be385f0969" && git -C "/home/user/heads/build/x86/coreboot-dasharo" reset --hard HEAD^ && echo "git fetch https://github.com/dasharo/coreboot 3a9aa3a4692f3dd49732f5b4e3ec54be385f0969 --recurse-submodules=no" && git -C "/home/user/heads/build/x86/coreboot-dasharo" fetch https://github.com/dasharo/coreboot 3a9aa3a4692f3dd49732f5b4e3ec54be385f0969 --recurse-submodules=no && echo "git reset --hard 3a9aa3a4692f3dd49732f5b4e3ec54be385f0969" && git -C "/home/user/heads/build/x86/coreboot-dasharo" reset --hard 3a9aa3a4692f3dd49732f5b4e3ec54be385f0969 && echo "git clean" && git -C "/home/user/heads/build/x86/coreboot-dasharo" clean -df && git -C "/home/user/heads/build/x86/coreboot-dasharo" clean -dffx payloads util/cbmem && echo "git submodule sync" && git -C "/home/user/heads/build/x86/coreboot-dasharo" submodule sync && echo "git submodule update" && git -C "/home/user/heads/build/x86/coreboot-dasharo" submodule update --init --checkout && echo -n 'https://github.com/dasharo/coreboot|3a9aa3a4692f3dd49732f5b4e3ec54be385f0969' > "/home/user/heads/build/x86/coreboot-dasharo/.canary"; fi
Switching coreboot-dasharo to https://github.com/dasharo/coreboot at 3a9aa3a4692f3dd49732f5b4e3ec54be385f0969
^Cmake: *** [Makefile:562: /home/user/heads/build/x86/coreboot-dasharo/.canary] Interrupt

@boredsquirrel
Copy link
Author

thanks!

@boredsquirrel

This comment was marked as off-topic.

@mkopec

This comment was marked as off-topic.

@boredsquirrel
Copy link
Author

boredsquirrel commented Sep 19, 2024

I am trying to follow the instructions with podman on Fedora 40:

$ git clone https://github.com/Dasharo/heads.git
$ git switch rel_novacustom_nv4x_adl_v0.9.1
$ git pull

$ podman run -e DISPLAY=$DISPLAY --network host --rm -ti -v $(pwd):$(pwd) -w $(pwd) tlaurion/heads-dev-env:latest -- make BOARD=nitropad-nv41

make: stat: Makefile: Permission denied
make: *** No targets specified and no makefile found.  Stop.

Likely some incompatibility between podman and docker args? I tried bash and fish, and I moved the heads repo to home, to avoid having uppercase characters in the path.

The makefile and board configs are there.
Btw, that branch is newer than the "novacustom_laptops" one, so I used that, is that correct?

@tlaurion
Copy link
Collaborator

I am trying to follow the instructions with podman on Fedora 40:

$ git clone https://github.com/Dasharo/heads.git
$ git switch rel_novacustom_nv4x_adl_v0.9.1
$ git pull

$ podman run -e DISPLAY=$DISPLAY --network host --rm -ti -v $(pwd):$(pwd) -w $(pwd) tlaurion/heads-dev-env:latest -- make BOARD=nitropad-nv41

make: stat: Makefile: Permission denied
make: *** No targets specified and no makefile found.  Stop.

Likely some incompatibility between podman and docker args? I tried bash and fish, and I moved the heads repo to home, to avoid having uppercase characters in the path.

The makefile and board configs are there. Btw, that branch is newer than the "novacustom_laptops" one, so I used that, is that correct?

This is upstream Heads, not Dasharo.
To build for nv41:

git clone https://github.com/linuxboot/heads
cd heads
docker run -e DISPLAY=$DISPLAY --network host --rm -ti -v $(pwd):$(pwd) -w $(pwd) tlaurion/heads-dev-env:latest -- make BOARD=nitropad-nv41

Do not try to mix build instructions from forks: build from forks instructions.

@boredsquirrel
Copy link
Author

boredsquirrel commented Sep 20, 2024

thanks for your help!

still the exact same error, again with podman

make: stat: Makefile: Permission denied
make: *** No targets specified and no makefile found.  Stop.

@tlaurion
Copy link
Collaborator

tlaurion commented Sep 21, 2024

thanks for your help!

still the exact same error, again with podman

make: stat: Makefile: Permission denied
make: *** No targets specified and no makefile found.  Stop.

Remove dir. Clone again. Have docker. No podman. Try again. Give commands and errors. Otherwise: can't reproduce, also not mind reader.

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

No branches or pull requests

4 participants
@tlaurion @mkopec @boredsquirrel and others