ncbi-vdb icon indicating copy to clipboard operation
ncbi-vdb copied to clipboard

Error encountered while compiling for Arm platform

Open hyacz opened this issue 2 years ago • 2 comments

I got an error when compiling on arm platform

Consolidate compiler generated dependencies of target ncbi-bam
[  0%] Building C object libs/align/CMakeFiles/ncbi-bam.dir/bam.c.o
In file included from /opt/installer/ncbi-vdb-3.0.0/interfaces/kfs/file-v2.h:35:0,
                 from /opt/installer/ncbi-vdb-3.0.0/interfaces/kfs/file.h:39,
                 from /opt/installer/ncbi-vdb-3.0.0/libs/align/bam.c:32:
/opt/installer/ncbi-vdb-3.0.0/interfaces/kfc/refcount.h:39:10: fatal error: atomic32.h: No such file or directory
 #include <atomic32.h>
          ^~~~~~~~~~~~
compilation terminated.

I guess it should be due to the wrong directory name. On arm, env.cmake includes interfaces/cc/gcc/aarch64 but what actually exists is interfaces/cc/gcc/arm64.

https://github.com/ncbi/ncbi-vdb/blob/34c611317dbe2832cf24ec543a95e9ca7b9eb2e6/build/env.cmake#L68-L71 https://github.com/ncbi/ncbi-vdb/blob/34c611317dbe2832cf24ec543a95e9ca7b9eb2e6/build/env.cmake#L158-L160

I renamed interfaces/cc/gcc/arm64 to interfaces/cc/gcc/aarch64 and everything looks fine.

hyacz avatar Jul 01 '22 03:07 hyacz