Building own image, Compute module 3

What is correct machine type for compute module 3? I tried to build fincm3 but I received error like below

Build Configuration:
BB_VERSION           = "1.52.0"
BUILD_SYS            = "x86_64-linux"
NATIVELSBSTRING      = "ubuntu-18.04"
TARGET_SYS           = "arm-poky-linux-gnueabi"
MACHINE              = "fincm3"
DISTRO               = "balena-os"
DISTRO_VERSION       = "2.98.17"
TUNE_FEATURES        = "arm vfp cortexa7 neon vfpv4 thumb callconvention-hard"
TARGET_FPU           = "hard"
meta
meta-poky            = "HEAD:43cfa130d9e72cec421dd1530858926b7445752d"
meta-oe
meta-filesystems
meta-networking
meta-python          = "HEAD:e886fc0cbac89998f675b70679d0cce6bcebfb7f"
meta-raspberrypi     = "HEAD:378d4b6e7ba64b6a9a701457cc3780fa896ba5dc"
meta-balena-common
meta-balena-honister = "HEAD:42c71bfea112ba44e59488fe93284a583654622f"
meta-balena-raspberrypi = "master:610b77f1ce944fe1729dd7d3160c76913215b1d0"
meta-rust            = "HEAD:d4384db8c3f0aa01732627f92fc3d446359bf743"

Initialising tasks: 100% |#########################################################################################################################################################################################################################| Time: 0:00:01
Sstate summary: Wanted 1832 Local 1798 Network 0 Missed 34 Current 0 (98% match, 0% complete)
NOTE: Executing Tasks
WARNING: linux-raspberrypi-1_5.10.95+gitAUTOINC+e1979ceb17_a538fd26f8-r0 do_kernel_resin_checkconfig: Checking for CONFIG_NF_TABLES_SET=m in the kernel configs failed for nf_tables.
WARNING: linux-raspberrypi-1_5.10.95+gitAUTOINC+e1979ceb17_a538fd26f8-r0 do_kernel_resin_checkconfig: Checking for CONFIG_DM_CRYPT=y in the kernel configs failed for dmcrypt.
WARNING: linux-raspberrypi-1_5.10.95+gitAUTOINC+e1979ceb17_a538fd26f8-r0 do_kernel_resin_checkconfig: Checking for CONFIG_FB_TFT_FBTFT_DEVICE=m in the kernel configs failed for fbtft.
WARNING: linux-raspberrypi-1_5.10.95+gitAUTOINC+e1979ceb17_a538fd26f8-r0 do_kernel_resin_checkconfig: Checking for CONFIG_FB_FLEX=m in the kernel configs failed for fbtft.
ERROR: kernel-modules-headers-1.0-r0 do_package: Fatal errors occurred in subprocesses:
Command '['arm-poky-linux-gnueabi-objcopy', '--only-keep-debug', '/home/user_compile/poky/balena-raspberrypi/build/tmp/work/fincm3-poky-linux-gnueabi/kernel-modules-headers/1.0-r0/package/usr/src/kernel-hdrs/scripts/gcc-plugins/arm_ssp_per_task_plugin.so', '/home/user_compile/poky/balena-raspberrypi/build/tmp/work/fincm3-poky-linux-gnueabi/kernel-modules-headers/1.0-r0/package/usr/src/kernel-hdrs/scripts/gcc-plugins/.debug/arm_ssp_per_task_plugin.so']' returned non-zero exit status 1.
Subprocess output:arm-poky-linux-gnueabi-objcopy: /home/user_compile/poky/balena-raspberrypi/build/tmp/work/fincm3-poky-linux-gnueabi/kernel-modules-headers/1.0-r0/package/usr/src/kernel-hdrs/scripts/gcc-plugins/arm_ssp_per_task_plugin.so: file format not recognized

ERROR: Logfile of failure stored in: /home/user_compile/poky/balena-raspberrypi/build/tmp/work/fincm3-poky-linux-gnueabi/kernel-modules-headers/1.0-r0/temp/log.do_package.11264
ERROR: Task (/home/user_compile/poky/balena-raspberrypi/build/../layers/meta-balena/meta-balena-common/recipes-devtools/kernel-modules-headers/kernel-modules-headers.bb:do_package) failed with exit code '1'
NOTE: Tasks Summary: Attempted 4337 tasks of which 4212 didn't need to be rerun and 1 failed.

Summary: 1 task failed:
  /home/user_compile/poky/balena-raspberrypi/build/../layers/meta-balena/meta-balena-common/recipes-devtools/kernel-modules-headers/kernel-modules-headers.bb:do_package
Summary: There were 4 WARNING messages shown.
Summary: There was 1 ERROR message shown, returning a non-zero exit code.
[000000826][LOG]Build for fincm3 failed. Check failed log in build/tmp/log/cooker/fincm3 .
[000000826][LOG]If build for fincm3 succeeded, final image should have been generated here:
[000000826][LOG]   build/tmp/deploy/images/fincm3/balena-image-fincm3.balenaos-img
[000000826][LOG]Done.


Hi, what Linux distribution are you using to build? Have you tried the balena-build.sh script which uses a container and will isolate the build process from host dependencies (see balena-yocto-scripts/balena-build.sh at master · balena-os/balena-yocto-scripts · GitHub)?

The fincm3 is based on the CM3, so it’s a good reference to use. It’s likely that you will have to add a new device type if your carrier board differs from the balenaFin though.