Can't build anything on VIM3L and 4.9 kernel

#I’m tring to build with 4.9.y kernel on VIM3L as in config:
lun 26 dic 2022, 11:51:01, CET

io@Dell:~/Scrivania/fenix$ NO_GIT_UPDATE=1 make
[i] FENIX (scripts/create_image.sh) BUILD: /home/io/Scrivania/fenix/build | DL: /home/io/Scrivania/fenix/downloads | sudo: sudo -E

BUILD_TYPE                    :   develop
DOWNLOAD_MIRROR               :   default
NO_CCACHE                     :        no
COMPRESS_IMAGE                :        no
INSTALL_TYPE_RAW              :        no
CLONE_FULL_COMMIT_LOG         :        no
FORCE_BUILD_KERNEL_DEB        :        no
SKIP_ROOTFS_CACHE_DOWNLOAD    :        no
FORCE_CREATE_ROOTFS_CACHE     :        no
CREATE_ROOTFS_CACHE_ONLY      :        no
NO_APT_CACHER                 :       yes
SKIP_HEADER_DEB               :        no


***********************PARAMETERS************************

but after a lot of error ,can finish to build, and into kernel, now I have spi port but cannot see on image, cos not compiled, as this errors appear:
host pc is ubuntu Jammy
and theese are errors:

***********************PARAMETERS************************
Fenix Version:         1.3
Khadas Board:          VIM3L
Uboot Version:         2015.01
Uboot Configuration:   kvim3l_defconfig
Uboot Branch:          khadas-vims-v2015.01
Linux Version:         4.9
Linux Configuration:   kvims_defconfig
Linux DTB:             arch/arm64/boot/dts/amlogic/kvim3l_linux.dtb
Linux Branch:          khadas-vims-4.9.y
Distribution:          Ubuntu
Distribution Release:  jammy
Distribution Type:     server
Distribution Arch:     arm64
Install Type:          EMMC
Final Image:           vim3l-ubuntu-22.04-server-linux-4.9-fenix-1.3-221226-emmc-develop.img
*********************************************************


/usr/include/libfdt_env.h:27:30: error: conflicting types for ‘fdt64_t’; have ‘uint64_t’ {aka ‘long unsigned int’}
   27 | typedef uint64_t FDT_BITWISE fdt64_t;
      |                              ^~~~~~~
In file included from <command-line>:
./../include/libfdt_env.h:19:16: note: previous declaration of ‘fdt64_t’ with type ‘fdt64_t’ {aka ‘long long unsigned int’}
   19 | typedef __be64 fdt64_t;
      |                ^~~~~~~
In file included from ./../include/libfdt_env.h:12,
                 from <command-line>:
/usr/include/libfdt_env.h:47:24: error: expected ‘)’ before ‘x’
   47 | static inline uint32_t fdt32_to_cpu(fdt32_t x)
      |                        ^~~~~~~~~~~~
./../include/compiler.h:66:16: error: expected ‘)’ before ‘&’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                ^
./../include/compiler.h:66:30: error: expected ‘)’ before ‘>>’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                              ^~
./../include/compiler.h:66:37: error: expected ‘)’ before ‘|’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                                     ^
/usr/include/libfdt_env.h:51:23: error: expected ‘)’ before ‘x’
   51 | static inline fdt32_t cpu_to_fdt32(uint32_t x)
      |                       ^~~~~~~~~~~~
./../include/compiler.h:66:16: error: expected ‘)’ before ‘&’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                ^
./../include/compiler.h:66:30: error: expected ‘)’ before ‘>>’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                              ^~
./../include/compiler.h:66:37: error: expected ‘)’ before ‘|’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                                     ^
/usr/include/libfdt_env.h:56:24: error: expected ‘)’ before ‘x’
   56 | static inline uint64_t fdt64_to_cpu(fdt64_t x)
      |                        ^~~~~~~~~~~~
./../include/compiler.h:71:16: error: expected ‘)’ before ‘&’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                ^
./../include/compiler.h:71:43: error: expected ‘)’ before ‘>>’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                                           ^~
./../include/compiler.h:71:50: error: expected ‘)’ before ‘|’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                                                  ^
/usr/include/libfdt_env.h:60:23: error: expected ‘)’ before ‘x’
   60 | static inline fdt64_t cpu_to_fdt64(uint64_t x)
      |                       ^~~~~~~~~~~~
./../include/compiler.h:71:16: error: expected ‘)’ before ‘&’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                ^
./../include/compiler.h:71:43: error: expected ‘)’ before ‘>>’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                                           ^~
./../include/compiler.h:71:50: error: expected ‘)’ before ‘|’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                                                  ^
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:122:21: error: redefinition of ‘fdt_offset_ptr_w’
  122 | static inline void *fdt_offset_ptr_w(void *fdt, int offset, int checklen)
      |                     ^~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:131:21: note: previous definition of ‘fdt_offset_ptr_w’ with type ‘void *(void *, int,  int)’
  131 | static inline void *fdt_offset_ptr_w(void *fdt, int offset, int checklen)
      |                     ^~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:259:1: error: redefinition of ‘fdt_set_magic’
  259 | fdt_set_hdr_(magic);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_magic’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:214:1: note: in expansion of macro ‘__fdt_set_hdr’
  214 | __fdt_set_hdr(magic);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:260:1: error: redefinition of ‘fdt_set_totalsize’
  260 | fdt_set_hdr_(totalsize);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_totalsize’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:215:1: note: in expansion of macro ‘__fdt_set_hdr’
  215 | __fdt_set_hdr(totalsize);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:261:1: error: redefinition of ‘fdt_set_off_dt_struct’
  261 | fdt_set_hdr_(off_dt_struct);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_off_dt_struct’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:216:1: note: in expansion of macro ‘__fdt_set_hdr’
  216 | __fdt_set_hdr(off_dt_struct);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:262:1: error: redefinition of ‘fdt_set_off_dt_strings’
  262 | fdt_set_hdr_(off_dt_strings);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_off_dt_strings’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:217:1: note: in expansion of macro ‘__fdt_set_hdr’
  217 | __fdt_set_hdr(off_dt_strings);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:263:1: error: redefinition of ‘fdt_set_off_mem_rsvmap’
  263 | fdt_set_hdr_(off_mem_rsvmap);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_off_mem_rsvmap’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:218:1: note: in expansion of macro ‘__fdt_set_hdr’
  218 | __fdt_set_hdr(off_mem_rsvmap);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:264:1: error: redefinition of ‘fdt_set_version’
  264 | fdt_set_hdr_(version);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_version’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:219:1: note: in expansion of macro ‘__fdt_set_hdr’
  219 | __fdt_set_hdr(version);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:265:1: error: redefinition of ‘fdt_set_last_comp_version’
  265 | fdt_set_hdr_(last_comp_version);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_last_comp_version’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:220:1: note: in expansion of macro ‘__fdt_set_hdr’
  220 | __fdt_set_hdr(last_comp_version);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:266:1: error: redefinition of ‘fdt_set_boot_cpuid_phys’
  266 | fdt_set_hdr_(boot_cpuid_phys);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_boot_cpuid_phys’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:221:1: note: in expansion of macro ‘__fdt_set_hdr’
  221 | __fdt_set_hdr(boot_cpuid_phys);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:267:1: error: redefinition of ‘fdt_set_size_dt_strings’
  267 | fdt_set_hdr_(size_dt_strings);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_size_dt_strings’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:222:1: note: in expansion of macro ‘__fdt_set_hdr’
  222 | __fdt_set_hdr(size_dt_strings);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:268:1: error: redefinition of ‘fdt_set_size_dt_struct’
  268 | fdt_set_hdr_(size_dt_struct);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_size_dt_struct’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:223:1: note: in expansion of macro ‘__fdt_set_hdr’
  223 | __fdt_set_hdr(size_dt_struct);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:346:13: error: conflicting types for ‘fdt_get_string’; have ‘const char *(const void *, int,  int *)’
  346 | const char *fdt_get_string(const void *fdt, int stroffset, int *lenp);
      |             ^~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:987:5: note: previous declaration of ‘fdt_get_string’ with type ‘int(const void *, int,  const char *, const char **)’
  987 | int fdt_get_string(const void *fdt, int node, const char *property,
      |     ^~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:391:24: error: static declaration of ‘fdt_get_max_phandle’ follows non-static declaration
  391 | static inline uint32_t fdt_get_max_phandle(const void *fdt)
      |                        ^~~~~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:292:10: note: previous declaration of ‘fdt_get_max_phandle’ with type ‘uint32_t(const void *)’ {aka ‘unsigned int(const void *)’}
  292 | uint32_t fdt_get_max_phandle(const void *fdt);
      |          ^~~~~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:708:36: error: redefinition of ‘fdt_get_property_w’
  708 | static inline struct fdt_property *fdt_get_property_w(void *fdt, int nodeoffset,
      |                                    ^~~~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:562:36: note: previous definition of ‘fdt_get_property_w’ with type ‘struct fdt_property *(void *, int,  const char *, int *)’
  562 | static inline struct fdt_property *fdt_get_property_w(void *fdt, int nodeoffset,
      |                                    ^~~~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:768:21: error: redefinition of ‘fdt_getprop_namelen_w’
  768 | static inline void *fdt_getprop_namelen_w(void *fdt, int nodeoffset,
      |                     ^~~~~~~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:617:21: note: previous definition of ‘fdt_getprop_namelen_w’ with type ‘void *(void *, int,  const char *, int,  int *)’
  617 | static inline void *fdt_getprop_namelen_w(void *fdt, int nodeoffset,
      |                     ^~~~~~~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:807:21: error: redefinition of ‘fdt_getprop_w’
  807 | static inline void *fdt_getprop_w(void *fdt, int nodeoffset,
      |                     ^~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:654:21: note: previous definition of ‘fdt_getprop_w’ with type ‘void *(void *, int,  const char *, int *)’
  654 | static inline void *fdt_getprop_w(void *fdt, int nodeoffset,
      |                     ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1310:19: error: redefinition of ‘fdt_setprop_inplace_u32’
 1310 | static inline int fdt_setprop_inplace_u32(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1132:19: note: previous definition of ‘fdt_setprop_inplace_u32’ with type ‘int(void *, int,  const char *, uint32_t)’ {aka ‘int(void *, int,  const char *, unsigned int)’}
 1132 | static inline int fdt_setprop_inplace_u32(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1345:19: error: redefinition of ‘fdt_setprop_inplace_u64’
 1345 | static inline int fdt_setprop_inplace_u64(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1167:19: note: previous definition of ‘fdt_setprop_inplace_u64’ with type ‘int(void *, int,  const char *, uint64_t)’ {aka ‘int(void *, int,  const char *, long unsigned int)’}
 1167 | static inline int fdt_setprop_inplace_u64(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1362:19: error: redefinition of ‘fdt_setprop_inplace_cell’
 1362 | static inline int fdt_setprop_inplace_cell(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1179:19: note: previous definition of ‘fdt_setprop_inplace_cell’ with type ‘int(void *, int,  const char *, uint32_t)’ {aka ‘int(void *, int,  const char *, unsigned int)’}
 1179 | static inline int fdt_setprop_inplace_cell(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1466:19: error: redefinition of ‘fdt_property_u32’
 1466 | static inline int fdt_property_u32(void *fdt, const char *name, uint32_t val)
      |                   ^~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1245:19: note: previous definition of ‘fdt_property_u32’ with type ‘int(void *, const char *, uint32_t)’ {aka ‘int(void *, const char *, unsigned int)’}
 1245 | static inline int fdt_property_u32(void *fdt, const char *name, uint32_t val)
      |                   ^~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1471:19: error: redefinition of ‘fdt_property_u64’
 1471 | static inline int fdt_property_u64(void *fdt, const char *name, uint64_t val)
      |                   ^~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1250:19: note: previous definition of ‘fdt_property_u64’ with type ‘int(void *, const char *, uint64_t)’ {aka ‘int(void *, const char *, long unsigned int)’}
 1250 | static inline int fdt_property_u64(void *fdt, const char *name, uint64_t val)
      |                   ^~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1478:19: error: redefinition of ‘fdt_property_cell’
 1478 | static inline int fdt_property_cell(void *fdt, const char *name, uint32_t val)
      |                   ^~~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1255:19: note: previous definition of ‘fdt_property_cell’ with type ‘int(void *, const char *, uint32_t)’ {aka ‘int(void *, const char *, unsigned int)’}
 1255 | static inline int fdt_property_cell(void *fdt, const char *name, uint32_t val)
      |                   ^~~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1677:19: error: redefinition of ‘fdt_setprop_u32’
 1677 | static inline int fdt_setprop_u32(void *fdt, int nodeoffset, const char *name,
      |                   ^~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1405:19: note: previous definition of ‘fdt_setprop_u32’ with type ‘int(void *, int,  const char *, uint32_t)’ {aka ‘int(void *, int,  const char *, unsigned int)’}
 1405 | static inline int fdt_setprop_u32(void *fdt, int nodeoffset, const char *name,
      |                   ^~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1712:19: error: redefinition of ‘fdt_setprop_u64’
 1712 | static inline int fdt_setprop_u64(void *fdt, int nodeoffset, const char *name,
      |                   ^~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1440:19: note: previous definition of ‘fdt_setprop_u64’ with type ‘int(void *, int,  const char *, uint64_t)’ {aka ‘int(void *, int,  const char *, long unsigned int)’}
 1440 | static inline int fdt_setprop_u64(void *fdt, int nodeoffset, const char *name,
      |                   ^~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1730:19: error: redefinition of ‘fdt_setprop_cell’
 1730 | static inline int fdt_setprop_cell(void *fdt, int nodeoffset, const char *name,
      |                   ^~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1452:19: note: previous definition of ‘fdt_setprop_cell’ with type ‘int(void *, int,  const char *, uint32_t)’ {aka ‘int(void *, int,  const char *, unsigned int)’}
 1452 | static inline int fdt_setprop_cell(void *fdt, int nodeoffset, const char *name,
      |                   ^~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1855:19: error: redefinition of ‘fdt_appendprop_u32’
 1855 | static inline int fdt_appendprop_u32(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1547:19: note: previous definition of ‘fdt_appendprop_u32’ with type ‘int(void *, int,  const char *, uint32_t)’ {aka ‘int(void *, int,  const char *, unsigned int)’}
 1547 | static inline int fdt_appendprop_u32(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1890:19: error: redefinition of ‘fdt_appendprop_u64’
 1890 | static inline int fdt_appendprop_u64(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1582:19: note: previous definition of ‘fdt_appendprop_u64’ with type ‘int(void *, int,  const char *, uint64_t)’ {aka ‘int(void *, int,  const char *, long unsigned int)’}
 1582 | static inline int fdt_appendprop_u64(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/aisimage.c:10:
/usr/include/libfdt.h:1908:19: error: redefinition of ‘fdt_appendprop_cell’
 1908 | static inline int fdt_appendprop_cell(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/aisimage.c:8:
../tools/../include/libfdt.h:1594:19: note: previous definition of ‘fdt_appendprop_cell’ with type ‘int(void *, int,  const char *, uint32_t)’ {aka ‘int(void *, int,  const char *, unsigned int)’}
 1594 | static inline int fdt_appendprop_cell(void *fdt, int nodeoffset,
      |                   ^~~~~~~~~~~~~~~~~~~
In file included from ../tools/../include/libfdt.h:54,
                 from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/atmelimage.c:8:
/usr/include/libfdt_env.h:27:30: error: conflicting types for ‘fdt64_t’; have ‘uint64_t’ {aka ‘long unsigned int’}
   27 | typedef uint64_t FDT_BITWISE fdt64_t;
      |                              ^~~~~~~
In file included from <command-line>:
./../include/libfdt_env.h:19:16: note: previous declaration of ‘fdt64_t’ with type ‘fdt64_t’ {aka ‘long long unsigned int’}
   19 | typedef __be64 fdt64_t;
      |                ^~~~~~~
In file included from ./../include/libfdt_env.h:12,
                 from <command-line>:
/usr/include/libfdt_env.h:47:24: error: expected ‘)’ before ‘x’
   47 | static inline uint32_t fdt32_to_cpu(fdt32_t x)
      |                        ^~~~~~~~~~~~
./../include/compiler.h:66:16: error: expected ‘)’ before ‘&’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                ^
./../include/compiler.h:66:30: error: expected ‘)’ before ‘>>’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                              ^~
./../include/compiler.h:66:37: error: expected ‘)’ before ‘|’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                                     ^
/usr/include/libfdt_env.h:51:23: error: expected ‘)’ before ‘x’
   51 | static inline fdt32_t cpu_to_fdt32(uint32_t x)
      |                       ^~~~~~~~~~~~
./../include/compiler.h:66:16: error: expected ‘)’ before ‘&’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                ^
./../include/compiler.h:66:30: error: expected ‘)’ before ‘>>’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                              ^~
./../include/compiler.h:66:37: error: expected ‘)’ before ‘|’ token
   66 |         ((((x) & 0xff000000) >> 24) | \
      |                                     ^
/usr/include/libfdt_env.h:56:24: error: expected ‘)’ before ‘x’
   56 | static inline uint64_t fdt64_to_cpu(fdt64_t x)
      |                        ^~~~~~~~~~~~
./../include/compiler.h:71:16: error: expected ‘)’ before ‘&’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                ^
./../include/compiler.h:71:43: error: expected ‘)’ before ‘>>’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                                           ^~
./../include/compiler.h:71:50: error: expected ‘)’ before ‘|’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                                                  ^
/usr/include/libfdt_env.h:60:23: error: expected ‘)’ before ‘x’
   60 | static inline fdt64_t cpu_to_fdt64(uint64_t x)
      |                       ^~~~~~~~~~~~
./../include/compiler.h:71:16: error: expected ‘)’ before ‘&’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                ^
./../include/compiler.h:71:43: error: expected ‘)’ before ‘>>’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                                           ^~
./../include/compiler.h:71:50: error: expected ‘)’ before ‘|’ token
   71 |         ((((x) & 0xff00000000000000##sfx) >> 56) | \
      |                                                  ^
In file included from ../include/image.h:49,
                 from ../tools/atmelimage.c:11:
/usr/include/libfdt.h:122:21: error: redefinition of ‘fdt_offset_ptr_w’
  122 | static inline void *fdt_offset_ptr_w(void *fdt, int offset, int checklen)
      |                     ^~~~~~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/atmelimage.c:8:
../tools/../include/libfdt.h:131:21: note: previous definition of ‘fdt_offset_ptr_w’ with type ‘void *(void *, int,  int)’
  131 | static inline void *fdt_offset_ptr_w(void *fdt, int offset, int checklen)
      |                     ^~~~~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/atmelimage.c:11:
/usr/include/libfdt.h:259:1: error: redefinition of ‘fdt_set_magic’
  259 | fdt_set_hdr_(magic);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/atmelimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_magic’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:214:1: note: in expansion of macro ‘__fdt_set_hdr’
  214 | __fdt_set_hdr(magic);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/atmelimage.c:11:
/usr/include/libfdt.h:260:1: error: redefinition of ‘fdt_set_totalsize’
  260 | fdt_set_hdr_(totalsize);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/atmelimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_totalsize’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~
../tools/../include/libfdt.h:215:1: note: in expansion of macro ‘__fdt_set_hdr’
  215 | __fdt_set_hdr(totalsize);
      | ^~~~~~~~~~~~~
In file included from ../include/image.h:49,
                 from ../tools/atmelimage.c:11:
/usr/include/libfdt.h:261:1: error: redefinition of ‘fdt_set_off_dt_struct’
  261 | fdt_set_hdr_(off_dt_struct);
      | ^~~~~~~~~~~~
In file included from ../tools/fdt_host.h:11,
                 from ../tools/imagetool.h:22,
                 from ../tools/atmelimage.c:8:
../tools/../include/libfdt.h:209:28: note: previous definition of ‘fdt_set_off_dt_struct’ with type ‘void(void *, uint32_t)’ {aka ‘void(void *, unsigned int)’}
  209 |         static inline void fdt_set_##name(void *fdt, uint32_t val) \
      |                            ^~~~~~~~

P.S.: error list is truncated, this message was too long, with all errors

Hello @pappicio

Have you change the source code ? I checked on my side build without issues.

No. My host PC Is on Ubuntu jammy, for the rest, tested just downloading Fenix sources with wget and compile them, nothing more, and have all thoose errors (not in docker)
Today I’ll try with Ubuntu 20.04 on virtual machine.

with ubuntu 20.04 in vm all built well!
thanks! (and I can see also spi port and more dtbo that with newer version of images disappear!)