COMPILATION ERROR ARM/Neoverse-N1/aarch64 - HELP!!!
**Describe the bug**
**compile error**
**[ 44%] Building CXX object CMakeFiles/xmrig.dir/src/backend/cpu/CpuWorker.cpp.o**
In file included from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/home/ubuntu/xmrig/src/crypto/randomx/randomx.h:160:1: error: template with C linkage
  160 | template<typename T>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
In file included from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:48:
/home/ubuntu/xmrig/src/crypto/astrobwt/AstroBWT.h:37:1: error: template with C linkage
   37 | template<Algorithm::Id ALGO>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
In file included from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:48:
/home/ubuntu/xmrig/src/crypto/astrobwt/AstroBWT.h:40:1: error: template specialization with C linkage
   40 | template<>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:71:1: error: template with C linkage
   71 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:109:1: error: template with C linkage
  109 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:132:1: error: template with C linkage
  132 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:156:1: error: template with C linkage
  156 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:236:1: error: template with C linkage
  236 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:244:1: error: template with C linkage
  244 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:379:1: error: template with C linkage
  379 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:398:1: error: template with C linkage
  398 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:442:1: error: template with C linkage
  442 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:471:1: error: template specialization with C linkage
  471 | template<>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:493:1: error: template with C linkage
  493 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:511:1: error: template with C linkage
  511 | template<size_t N>
      | ^~~~~~~~
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:1: note: ‘extern "C"’ linkage started here
   33 | extern "C" {
      | ^~~~~~~~~~
/home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:550:1: error: expected ‘}’ at end of input
  550 | } // namespace xmrig
      | ^
In file included from /home/ubuntu/xmrig/src/crypto/randomx/intrin_portable.h:385,
                 from /home/ubuntu/xmrig/src/crypto/randomx/randomx.h:35,
                 from /home/ubuntu/xmrig/src/backend/cpu/CpuWorker.cpp:43:
/usr/lib/gcc/aarch64-linux-gnu/9/include/arm_acle.h:33:12: note: to match this ‘{’
   33 | extern "C" {
      |            ^
make[2]: *** [CMakeFiles/xmrig.dir/build.make:1233: CMakeFiles/xmrig.dir/src/backend/cpu/CpuWorker.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:140: CMakeFiles/xmrig.dir/all] Error 2
make: *** [Makefile:84: all] Error 2

**I try to compile on a machine with the following specifications:**
Architecture:  aarch64
CPU op-mode(s): 32-bit, 64-bit
Vendor ID: ARM
Model name: Neoverse-N1

**I appreciate the help, many thanks**

