Dealing with compile errors in building packages in OpenWrt buildroot

I am hoping for some gentle advice as I build my first package in OpenWrt in Ubuntu 20.04 under WSL 2. Actually, this is an Entware package to be run on an x86_64 NAS.
Entware packages are built in OpenWrt.

The toolchain appears to build fine.
The compile process currently fails here:

touch /home/entwarebuilder/Entware/build_dir/target-x86_64_glibc-2.27/veracrypt-1.0/.built_check
CFLAGS="-O2 -pipe -fomit-frame-pointer -fno-caller-saves -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result   -I/home/entwarebuilder/Entware/staging_dir/toolchain-x86_64_gcc-8.4.0_glibc-2.27/include " CXXFLAGS="-O2 -pipe -fomit-frame-pointer -fno-caller-saves -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result   -I/home/entwarebuilder/Entware/staging_dir/toolchain-x86_64_gcc-8.4.0_glibc-2.27/include " LDFLAGS="-Wl,--dynamic-linker=/opt/lib/ld-linux-x86-64.so.2 -Wl,-rpath=/opt/lib -L/home/entwarebuilder/Entware/staging_dir/toolchain-x86_64_gcc-8.4.0_glibc-2.27/lib " make -j1 -C /home/entwarebuilder/Entware/build_dir/target-x86_64_glibc-2.27/veracrypt-1.0/src AR="x86_64-openwrt-linux-gnu-gcc-ar" AS="x86_64-openwrt-linux-gnu-gcc -c -O2 -pipe -fomit-frame-pointer -fno-caller-saves -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result " LD=x86_64-openwrt-linux-gnu-ld NM="x86_64-openwrt-linux-gnu-gcc-nm" CC="x86_64-openwrt-linux-gnu-gcc" GCC="x86_64-openwrt-linux-gnu-gcc" CXX="x86_64-openwrt-linux-gnu-g++" RANLIB="x86_64-openwrt-linux-gnu-gcc-ranlib" STRIP=x86_64-openwrt-linux-gnu-strip OBJCOPY=x86_64-openwrt-linux-gnu-objcopy OBJDUMP=x86_64-openwrt-linux-gnu-objdump SIZE=x86_64-openwrt-linux-gnu-size CROSS="x86_64-openwrt-linux-gnu-" ARCH="x86_64" NOGUI=1 WXSTATIC=1;
make[3]: Entering directory '/home/entwarebuilder/Entware/build_dir/target-x86_64_glibc-2.27/veracrypt-1.0/src'
make[4]: Entering directory '/home/entwarebuilder/Entware/build_dir/target-x86_64_glibc-2.27/veracrypt-1.0/src/Volume'
Assembling Aes_x64.asm
x86_64-openwrt-linux-gnu-gcc: error: elf64: No such file or directory
x86_64-openwrt-linux-gnu-gcc: error: unrecognized command line option '-f'
make[4]: *** [/home/entwarebuilder/Entware/build_dir/target-x86_64_glibc-2.27/veracrypt-1.0/src/Build/Include/Makefile.inc:44: ../Crypto/Aes_x64.o] Error 1

I understand that the compiler is looking for an elf64 file. I don't understand why it can't, and what I can do to have it look in the right directories for it.

I'm always happy to provide missing info that is necessary for figuring this out.

Many thanks

Unfortunately you need to ask the Entware community for help as "pure" OpenWrt is only supported and I'm not sure why you're trying to build at least 7y old software.

Veracrypt, the software I am trying package, is being actively maintained. The version I am working with is from September of 2021.
What about it that makes you think it is 7 years old?

The compile errors I am having seem to be openWrt related. the packages referred to are x86_64-openwrt-linux-gnu-gcc, x86_64-openwrt-linux-gnu-g++ etc.

Which I why I am casting myself on the kindness of knowledgeable strangers for help.

Because the latest version of Veracrypt 1.0 branch (I assume the directory name reflects on version) was released in 2015 ...and glibc version in 2017. https://sourceware.org/glibc/wiki/Release/2.27

Ah, sorry. no.
The 1.0 is the version number appended by the BuildRoot to my entware/OpenWrt package.

I am working with the source of 1.25.4 from December of 2021.