Issue compiling Device Tree Overlays

Hi,

Starting from this thread, I now need to compile a device tree overlay to enable the M2M device for the i.MX8QM. I followed the steps in this guide, but getting these errors:

make
make -C /home/alex/toradex/cc_tools/kernel/linux-toradex/ M=/home/alex/toradex/cc_tools/dto/device-tree-overlays/overlays
make[1]: Entering directory '/home/alex/toradex/cc_tools/kernel/linux-toradex'
awk: fatal: cannot open file `include/generated/asm-offsets.h' for reading (No such file or directory)
  DTC     /home/alex/toradex/cc_tools/dto/device-tree-overlays/overlays/apalis-imx6_atmel-mxt_overlay.dtbo
/bin/sh: 1: ./scripts/dtc/dtc: not found
make[2]: *** [/home/alex/toradex/cc_tools/dto/device-tree-overlays/overlays/Makefile:111: /home/alex/toradex/cc_tools/dto/device-tree-overlays/overlays/apalis-imx6_atmel-mxt_overlay.dtbo] Error 127
make[1]: *** [Makefile:1734: /home/alex/toradex/cc_tools/dto/device-tree-overlays/overlays] Error 2
make[1]: Leaving directory '/home/alex/toradex/cc_tools/kernel/linux-toradex'
make: *** [Makefile:114: all] Error 2

This can be marked as solved. The Linux kernel had to be compiled first.