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

Error Compiling (Porting to Thinkpad T430) #442

Closed
flawedworld opened this issue Sep 3, 2018 · 13 comments
Closed

Error Compiling (Porting to Thinkpad T430) #442

flawedworld opened this issue Sep 3, 2018 · 13 comments

Comments

@flawedworld
Copy link
Contributor

So I've been trying to get this running on my T430, but have hit a brick wall. To me it looks like a compiler error. But am not sure.


make -C "/home/user/dev/heads/build/coreboot-4.7/t430" -C /home/user/dev/heads/build/coreboot-4.7 obj=/home/user/dev/heads/build/coreboot-4.7/t430 DOTCONFIG=../../config/coreboot-t430.config BUILD_TIMELESS=1 CFLAGS_x86_32=-fdebug-prefix-map=/home/user/dev/heads=heads -gno-record-gcc-switches CFLAGS_x86_64=-fdebug-prefix-map=/home/user/dev/heads=heads -gno-record-gcc-switches
make[1]: Entering directory '/home/user/dev/heads/build/coreboot-4.7'
GEN generated/bootblock.ld
CP bootblock/arch/x86/bootblock.ld
LINK cbfs/fallback/bootblock.debug
OBJCOPY cbfs/fallback/bootblock.elf
OBJCOPY bootblock.raw.bin
CC romstage/lib/tlcl.o
src/lib/tlcl.c:196:10: error: no previous prototype for 'tlcl_define_space' [-Werror=missing-prototypes]
uint32_t tlcl_define_space(uint32_t index, uint32_t perm, uint32_t size)
^~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[1]: *** [Makefile:337: t430/romstage/lib/tlcl.o] Error 1
make[1]: Leaving directory '/home/user/dev/heads/build/coreboot-4.7'
make: *** [Makefile:356: /home/user/dev/heads/build/coreboot-4.7/t430/.build] Error 1

My qubes config is copy paste from the x230, so is my linux config, im using my own coreboot config (It's been setup as in the wiki). Attached is these files. I'm using 'make BOARD=t430 CPUS=4' to build. Thanks in advance.
config files.zip

@tlaurion
Copy link
Collaborator

tlaurion commented Sep 3, 2018

Updates given through slack channel on this issue:
rminnich [11:23 AM]

coreboot problem
seems it needs CONFIG_TPM2 or CONFIG_TPM1
See if they are in your .config

@zaolin [11:39 AM]

MAINBOARD_HAS_TPM1 or MAINBOARD_HAS_TPM2 in the mainboard kconfig including MAINBOARD_HAS_{LPC,SPI,I2C}_TPM

@rminnich
Copy link

rminnich commented Sep 3, 2018

do you see either CONFIG_TPM1 or CONFIG_TPM2 in .config?

@flawedworld
Copy link
Contributor Author

The laptop is equipped with TPM 1.2

CONFIG_TPM of any sort was not in the .config

I added CONFIG_TPM1=y

The following was present:

CONFIG_MAINBOARD_HAS_LPC_TPM=y

I continue to get the error with CONFIG_TPM1=y

Am going to experiment with TPM2 related flags.

@flawedworld
Copy link
Contributor Author

Ok, so if I go to config.h in the T430 folder in the coreboot-4.7 folder (AKA the build folder for coreboot) and change CONFIG_TPM 0 to CONFIG_TPM 1 it compiles perfectly. from then on. I now have another error, which I'll paste from my dev machine in a second

@rminnich
Copy link

rminnich commented Sep 3, 2018

@rminnich
Copy link

rminnich commented Sep 3, 2018

if you change .config at all, you really need to run
make oldconfig
just to be sure it will stick.

@flawedworld
Copy link
Contributor Author

Got it! So thats been sorted, I now have this new error

make -C "/home/user/dev/heads/build/coreboot-4.7/t430" -C /home/user/dev/heads/build/coreboot-4.7 obj=/home/user/dev/heads/build/coreboot-4.7/t430 DOTCONFIG=../../config/coreboot-t430.config BUILD_TIMELESS=1 CFLAGS_x86_32=-fdebug-prefix-map=/home/user/dev/heads=heads -gno-record-gcc-switches CFLAGS_x86_64=-fdebug-prefix-map=/home/user/dev/heads=heads -gno-record-gcc-switches make[1]: Entering directory '/home/user/dev/heads/build/coreboot-4.7' GEN generated/bootblock.ld CP bootblock/arch/x86/bootblock.ld LINK cbfs/fallback/bootblock.debug OBJCOPY cbfs/fallback/bootblock.elf OBJCOPY bootblock.raw.bin CREATE t430/mainboard/lenovo/t430/cbfs-file.3Za2Sv.out (from ./../../config/coreboot-t430.config) make[1]: *** No rule to make target 'bzImage', needed by 't430/coreboot.pre'. Stop. make[1]: Leaving directory '/home/user/dev/heads/build/coreboot-4.7' make: *** [Makefile:356: /home/user/dev/heads/build/coreboot-4.7/t430/.build] Error 1

So what do?

@zaolin
Copy link
Contributor

zaolin commented Sep 3, 2018

Yo please use the coreboot master instead of version 4.7 which is not working....

@zaolin
Copy link
Contributor

zaolin commented Sep 3, 2018

Then heads needs to be updated at least to 4.8.1 but to be honest even if you try reproducible builds. Don't use coreboot release version. Just use a tag you can update.

@flawedworld
Copy link
Contributor Author

UPDATE: I have (or at least it seems to be) the same error as I last mentioned

@zaolin Coreboot 4.8.1 did not help

make[1]: *** No rule to make target 'bzImage', needed by 't430/coreboot.pre'. Stop.
make[1]: Leaving directory '/home/user/dev/heads/build/coreboot-4.8.1'
make: *** [Makefile:356: /home/user/dev/heads/build/coreboot-4.8.1/t430/.build] Error 1

So close yet so far :/

@tlaurion @rminnich @zaolin Any ideas?

@flawedworld
Copy link
Contributor Author

All sorted had to shift some files around

@paulmenzel
Copy link
Contributor

paulmenzel commented Sep 4, 2018 via email

@flawedworld
Copy link
Contributor Author

@paulmenzel I am currently trying to debug the rom, as I keep getting artifacts, I forked the project and will do a pull request when I sort it.

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

5 participants