Hello OpenSearch Team,
From the past 2-3 weeks I have been struggling to build the project successfully, and now I have decided to seek help of amazing and talented people here. I have tried different configuration for CMake but all he time the buildJniLib fails with the following errors:
– Found Threads.
– OS: Darwin
– Compiler: Clang 14.0.0
– CXX flags release: -Wall -Wunreachable-code -Wcast-align -O3 -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -fpic -march=native
– CXX flags debug: -Wall -Wunreachable-code -Wcast-align -ggdb -DNDEBUG -std=c++11 -DHAVE_CXX0X -pthread -fpic -march=native
– Found OpenMP_C: -Xpreprocessor -fopenmp
– Found OpenMP_CXX: -Xpreprocessor -fopenmp -I/usr/local/opt/libomp/include
– Found OpenMP: TRUE
– Found OpenMP_C: -Xpreprocessor -fopenmp
– Found OpenMP_CXX: -Xpreprocessor -fopenmp -I/usr/local/opt/libomp/include
– Found OpenMP: TRUE (found version “4.5”)
– Could NOT find MKL (missing: MKL_LIBRARIES)
– Configuring done
– Generating done
– Build files have been written to: /Users/harisalam/Desktop/OpenSearch K-NN/k-NN/jni/googletest-download
[ 11%] Performing update step for ‘googletest’
[ 22%] No patch step for ‘googletest’
[ 33%] No configure step for ‘googletest’
[ 44%] No build step for ‘googletest’
[ 55%] No install step for ‘googletest’
[ 66%] No test step for ‘googletest’
[ 77%] Completed ‘googletest’
[100%] Built target googletest
– Configuring done
– Generating done
– Build files have been written to: /Users/harisalam/Desktop/OpenSearch K-NN/k-NN/jni
> Task :buildJniLib FAILED
[ 2%] Building CXX object external/nmslib/similarity_search/src/CMakeFiles/NonMetricSpaceLib.dir/distcomp_bregman.cc.o
clang: error: the clang compiler does not support ‘-march=native’
make[3]: *** [external/nmslib/similarity_search/src/CMakeFiles/NonMetricSpaceLib.dir/distcomp_bregman.cc.o] Error 1
make[2]: *** [external/nmslib/similarity_search/src/CMakeFiles/NonMetricSpaceLib.dir/all] Error 2
make[1]: *** [CMakeFiles/opensearchknn_nmslib.dir/rule] Error 2
make: *** [opensearchknn_nmslib] Error 2
FAILURE: Build failed with an exception.
- What went wrong:
Execution failed for task ‘:buildJniLib’.
Process ‘command ‘make’’ finished with non-zero exit value 2
- Try:
Run with –stacktrace option to get the stack trace.
Run with –info or –debug option to get more log output.
Run with –scan to get full insights.
- Get more help at https://help.gradle.org
BUILD FAILED in 2s