Hallo,
ich entwickle im Moment ein Kernel-Modul für ein Yocto-Linux mit
Kernel-Version 3.8.0-00074-g68c58e0. Das Yocto läuft auf einem
Evaluation Board (SoCrates von EBV) mit einem Altera Cyclone V SoC FPGA.
Ich möchte das Modul direkt auf dem Yocto Linux kompilieren. Das
Makefile sieht wie folgt aus:
1 | obj-m := gpio_interrupt.o
|
2 |
|
3 | SRC := $(shell pwd)
|
4 |
|
5 | KERNEL_SRC=/lib/modules/3.8.0-00074-g68c58e0
|
6 |
|
7 |
|
8 | # Check this is a Linux platform
|
9 | ifdef WINDIR
|
10 | # Building on Windows
|
11 | $(error This example is intended to be built on a Linux platform, not on Windows
|
12 | endif
|
13 | ifdef windir
|
14 | # Building on Windows
|
15 | $(error This example is intended to be built on a Linux platform, not on Windows
|
16 | endif
|
17 |
|
18 | ifeq ($(KERNEL_SRC),)
|
19 | ERR_TEXT=Have you untarred your kernel source tree? Please set KERNEL_SRC to the
|
20 | $(error $(ERR_TEXT))
|
21 | endif
|
Die Ausgabe auf #make all:
1 | root@socrates:/home/training/Button3.8# make all
|
2 | make -C /lib/modules/3.8.0-00074-g68c58e0 M=/home/training/Button3.8
|
3 | make[1]: Entering directory `/lib/modules/3.8.0-00074-g68c58e0'
|
4 | make[1]: *** No targets specified and no makefile found. Stop.
|
5 | make[1]: Leaving directory `/lib/modules/3.8.0-00074-g68c58e0'
|
6 | make: *** [all] Error 2
|
7 | root@socrates:/home/training/Button3.8#
|
Hat jemand eine Ahnung, was ich da falsch mache?
Wie setze ich die "Kernel_SRC" richtig?
Viele Grüße