sortmerna / sortmerna

SortMeRNA: next-generation sequence filtering and alignment tool
https://sortmerna.readthedocs.io
GNU General Public License v3.0
234 stars 69 forks source link

Sortmerna can be compiled on ARM64 on mac computers? #415

Open linyibin123 opened 5 months ago

linyibin123 commented 5 months ago

Currently sortmerna is targeting the x86-64 architecture and not the ARM64 architecture. Is this means that sortmerna cannot be compiled on ARM64 on mac computers?

biocodz commented 5 months ago

Mac on x86-64 for sure. Currently testing on conda-build and github actions build_osx.yml. I deleted the built artifacts yesterday but if you need it urgently, they can be regenerated I'm curious of ARM myself, so might give it a try when OSX is out of the door.

linyibin123 commented 5 months ago

Thank you very much for your reply.

martin-g commented 4 months ago

The build on ARM64 fails with:

[21/75] Building CXX object src/sortmerna/CMakeFiles/smr_objs.dir/Release/alignment.cpp.o
FAILED: src/sortmerna/CMakeFiles/smr_objs.dir/Release/alignment.cpp.o 
/usr/bin/c++ -DCMAKE_INTDIR=\"Release\" -I/tmp/sortmerna/sortmerna-4.3.7-beta.1/include -I/tmp/sortmerna/sortmerna-4.3.7-beta.1/3rdparty/cmph -I/tmp/sortmerna/sortmerna-4.3.7-beta.1/3rdparty/concurrentqueue -I/tmp/sortmerna/sortmerna-4.3.7-beta.1/3rdparty/alp -isystem /tmp/sortmerna/sortmerna-4.3.7-beta.1/build/3rdparty/rocksdb/dist/include -isystem /tmp/sortmerna/sortmerna-4.3.7-beta.1/build/3rdparty/zlib/dist/include -W -Wextra -Wall -Xlinker -v -O3 -DNDEBUG -std=gnu++17 -MD -MT src/sortmerna/CMakeFiles/smr_objs.dir/Release/alignment.cpp.o -MF src/sortmerna/CMakeFiles/smr_objs.dir/Release/alignment.cpp.o.d -o src/sortmerna/CMakeFiles/smr_objs.dir/Release/alignment.cpp.o -c /tmp/sortmerna/sortmerna-4.3.7-beta.1/src/sortmerna/alignment.cpp
In file included from /tmp/sortmerna/sortmerna-4.3.7-beta.1/include/indexdb.hpp:40,
                 from /tmp/sortmerna/sortmerna-4.3.7-beta.1/include/bitvector.hpp:42,
                 from /tmp/sortmerna/sortmerna-4.3.7-beta.1/include/traverse_bursttrie.hpp:46,
                 from /tmp/sortmerna/sortmerna-4.3.7-beta.1/include/alignment.hpp:42,
                 from /tmp/sortmerna/sortmerna-4.3.7-beta.1/src/sortmerna/alignment.cpp:39:
/tmp/sortmerna/sortmerna-4.3.7-beta.1/include/ssw.h:25:10: fatal error: emmintrin.h: No such file or directory
   25 | #include <emmintrin.h>
      |          ^~~~~~~~~~~~~
compilation terminated.
[23/75] Building CXX object src/sortmerna/CMakeFiles/smr_objs.dir/Release/bitvector.cpp.o
FAILED: src/sortmerna/CMakeFiles/smr_objs.dir/Release/bitvector.cpp.o 
/usr/bin/c++ -DCMAKE_INTDIR=\"Release\" -I/tmp/sortmerna/sortmerna-4.3.7-beta.1/include -I/tmp/sortmerna/sortmerna-4.3.7-beta.1/3rdparty/cmph -I/tmp/sortmerna/sortmerna-4.3.7-beta.1/3rdparty/concurrentqueue -I/tmp/sortmerna/sortmerna-4.3.7-beta.1/3rdparty/alp -isystem /tmp/sortmerna/sortmerna-4.3.7-beta.1/build/3rdparty/rocksdb/dist/include -isystem /tmp/sortmerna/sortmerna-4.3.7-beta.1/build/3rdparty/zlib/dist/include -W -Wextra -Wall -Xlinker -v -O3 -DNDEBUG -std=gnu++17 -MD -MT src/sortmerna/CMakeFiles/smr_objs.dir/Release/bitvector.cpp.o -MF src/sortmerna/CMakeFiles/smr_objs.dir/Release/bitvector.cpp.o.d -o src/sortmerna/CMakeFiles/smr_objs.dir/Release/bitvector.cpp.o -c /tmp/sortmerna/sortmerna-4.3.7-beta.1/src/sortmerna/bitvector.cpp
In file included from /tmp/sortmerna/sortmerna-4.3.7-beta.1/include/indexdb.hpp:40,
                 from /tmp/sortmerna/sortmerna-4.3.7-beta.1/include/bitvector.hpp:42,
                 from /tmp/sortmerna/sortmerna-4.3.7-beta.1/src/sortmerna/bitvector.cpp:39:
/tmp/sortmerna/sortmerna-4.3.7-beta.1/include/ssw.h:25:10: fatal error: emmintrin.h: No such file or directory
   25 | #include <emmintrin.h>
      |          ^~~~~~~~~~~~~
compilation terminated.
[30/75] Building CXX object 3rdparty/alp/CMakeFiles/alp.dir/Release/sls_alp_sim.cpp.o
ninja: build stopped: subcommand failed.
martin-g commented 4 months ago

I am working on adding a Linux ARM64 CI at my fork - https://github.com/martin-g/sortmerna/pull/1 Once ready I will work on a fix for the compilation problem!

biocodz commented 4 months ago

that sounds great!