Skip to main content
SAman.1
Associate III
Nov 25, 2020 09:51 UTC
Solved

Build image linux-stm32mp-5.4.56-r0

Hello totgehet,

i wanted to build a Kernelmodule for my Projekt so i started to install the SDK and wrote a simple Programm to see if i can make a Programm in the userspace. This works fine. My next step was to Building and deploying the Linux kernel. For that I followed the installation https://wiki.st.com/stm32mpu/wiki/STM32MP1_Developer_Package. But when I want to Compile and install on a build directory I get this error from the makefil:

make ARCH=arm uImage vmlinux dtbs LOADADDR=0xC2000040 O="$PWD/../build"

make[1]: Entering directory '/opt/st/stm32mp1/3.1-openstlinux-5.4-dunfell-mp1-20-11-12/stm32mp1-openstlinux-5-4-dunfell-mp1-20-11-12/sources/arm-ostl-linux-gnueabi/linux-stm32mp-5.4.56-r0/build'

 GEN    Makefile

scripts/kconfig/conf --syncconfig Kconfig

 GEN    Makefile

 SYSHDR arch/arm/include/generated/uapi/asm/unistd-common.h

 SYSHDR arch/arm/include/generated/uapi/asm/unistd-oabi.h

 SYSHDR arch/arm/include/generated/uapi/asm/unistd-eabi.h

 HOSTCC scripts/dtc/dtc.o

 HOSTCC scripts/dtc/flattree.o

 HOSTCC scripts/dtc/fstree.o

 HOSTCC scripts/dtc/data.o

 HOSTCC scripts/dtc/livetree.o

 HOSTCC scripts/dtc/treesource.o

 HOSTCC scripts/dtc/srcpos.o

 HOSTCC scripts/dtc/checks.o

 HOSTCC scripts/dtc/util.o

 LEX     scripts/dtc/dtc-lexer.lex.c

 YACC   scripts/dtc/dtc-parser.tab.[ch]

 HOSTCC scripts/dtc/dtc-lexer.lex.o

 HOSTCC scripts/dtc/dtc-parser.tab.o

 HOSTCC scripts/dtc/yamltree.o

 HOSTLD scripts/dtc/dtc

 HOSTCC scripts/genksyms/genksyms.o

 YACC   scripts/genksyms/parse.tab.[ch]

 HOSTCC scripts/genksyms/parse.tab.o

 LEX    scripts/genksyms/lex.lex.c

 HOSTCC scripts/genksyms/lex.lex.o

 HOSTLD scripts/genksyms/genksyms

 HOSTCC scripts/kallsyms

 HOSTCC scripts/conmakehash

 HOSTCC scripts/sortextable

 HOSTCC scripts/asn1_compiler

 HOSTCC scripts/sign-file

/opt/st/stm32mp1/3.1-openstlinux-5.4-dunfell-mp1-20-11-12/stm32mp1-openstlinux-5-4-dunfell-mp1-20-11-12/sources/arm-ostl-linux-gnueabi/linux-stm32mp-5.4.56-r0/linux-5.4.56/scripts/sign-file.c:25:10: fatal error: openssl/opensslv.h: No such file or directory

  25 | #include <openssl/opensslv.h>

     |         ^~~~~~~~~~~~~~~~~~~~

compilation terminated.

make[2]: *** [scripts/Makefile.host:107: scripts/sign-file] Error 1

make[1]: *** [/opt/st/stm32mp1/3.1-openstlinux-5.4-dunfell-mp1-20-11-12/stm32mp1-openstlinux-5-4-dunfell-mp1-20-11-12/sources/arm-ostl-linux-gnueabi/linux-stm32mp-5.4.56-r0/linux-5.4.56/Makefile:1100: scripts] Error 2

make[1]: Leaving directory '/opt/st/stm32mp1/3.1-openstlinux-5.4-dunfell-mp1-20-11-12/stm32mp1-openstlinux-5-4-dunfell-mp1-20-11-12/sources/arm-ostl-linux-gnueabi/linux-stm32mp-5.4.56-r0/build'

I checked my SDK and I saw that the Headerfile is available. This is why I have no idea how to fix the build. I hope someone can help me Thanks so far.

This topic has been closed for replies.
JYune
JYuneBest answer
Associate II
Nov 25, 2020 10:09 UTC

It seems like you need OpenSSL development package on your PC. Try this:

$ sudo apt-get install libssl-dev

3 replies

JYune
JYuneBest answer
Associate II
Nov 25, 2020 10:09 UTC

It seems like you need OpenSSL development package on your PC. Try this:

$ sudo apt-get install libssl-dev

SAman.1
SAman.1Author
Associate III
Nov 25, 2020 13:03 UTC

Thanks now its working i already compiled a simple kernel module.

Olivier GALLIEN
ST Technical Moderator
Nov 25, 2020 10:39 UTC

Hi @SAman.1​ ,

Thanks @JYune​ you are right

To be complete pay attention to install all extra package as per listed here :

https://wiki.st.com/stm32mpu/wiki/PC_prerequisites#Install_extra_packages

Olivier

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.