mirror of https://github.com/milvus-io/milvus.git
Merge branch 'update_build' into 'branch-0.4.0'
MS-442 update build stage See merge request megasearch/milvus!460 Former-commit-id: fdd7ec98815f4986e20c953c14675108bd9930a2pull/191/head
commit
4612c09fd1
|
@ -10,12 +10,14 @@ PROFILING="OFF"
|
||||||
BUILD_FAISS_WITH_MKL="OFF"
|
BUILD_FAISS_WITH_MKL="OFF"
|
||||||
USE_JFROG_CACHE="OFF"
|
USE_JFROG_CACHE="OFF"
|
||||||
KNOWHERE_BUILD_DIR="`pwd`/src/core/cmake_build"
|
KNOWHERE_BUILD_DIR="`pwd`/src/core/cmake_build"
|
||||||
|
KNOWHERE_OPTIONS="-t ${BUILD_TYPE}"
|
||||||
|
|
||||||
while getopts "p:d:t:k:uhrcgmj" arg
|
while getopts "p:d:t:k:uhrcgmj" arg
|
||||||
do
|
do
|
||||||
case $arg in
|
case $arg in
|
||||||
t)
|
t)
|
||||||
BUILD_TYPE=$OPTARG # BUILD_TYPE
|
BUILD_TYPE=$OPTARG # BUILD_TYPE
|
||||||
|
KNOWHERE_OPTIONS="-t ${BUILD_TYPE}"
|
||||||
;;
|
;;
|
||||||
u)
|
u)
|
||||||
echo "Build and run unittest cases" ;
|
echo "Build and run unittest cases" ;
|
||||||
|
@ -47,6 +49,7 @@ do
|
||||||
;;
|
;;
|
||||||
j)
|
j)
|
||||||
USE_JFROG_CACHE="ON"
|
USE_JFROG_CACHE="ON"
|
||||||
|
KNOWHERE_OPTIONS="${KNOWHERE_OPTIONS} -j"
|
||||||
;;
|
;;
|
||||||
h) # help
|
h) # help
|
||||||
echo "
|
echo "
|
||||||
|
@ -80,6 +83,10 @@ if [[ ! -d cmake_build ]]; then
|
||||||
MAKE_CLEAN="ON"
|
MAKE_CLEAN="ON"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
pushd `pwd`/src/core
|
||||||
|
./build.sh ${KNOWHERE_OPTIONS}
|
||||||
|
popd
|
||||||
|
|
||||||
cd cmake_build
|
cd cmake_build
|
||||||
git
|
git
|
||||||
CUDA_COMPILER=/usr/local/cuda/bin/nvcc
|
CUDA_COMPILER=/usr/local/cuda/bin/nvcc
|
||||||
|
|
|
@ -309,7 +309,7 @@ else()
|
||||||
# set(FAISS_SOURCE_URL "https://github.com/facebookresearch/faiss/archive/${FAISS_VERSION}.tar.gz")
|
# set(FAISS_SOURCE_URL "https://github.com/facebookresearch/faiss/archive/${FAISS_VERSION}.tar.gz")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set(FAISS_MD5 "a589663865a8558205533c8ac414278c")
|
#set(FAISS_MD5 "a589663865a8558205533c8ac414278c")
|
||||||
|
|
||||||
if(DEFINED ENV{MILVUS_KNOWHERE_URL})
|
if(DEFINED ENV{MILVUS_KNOWHERE_URL})
|
||||||
set(KNOWHERE_SOURCE_URL "$ENV{MILVUS_KNOWHERE_URL}")
|
set(KNOWHERE_SOURCE_URL "$ENV{MILVUS_KNOWHERE_URL}")
|
||||||
|
|
|
@ -260,7 +260,8 @@ else()
|
||||||
# set(FAISS_SOURCE_URL "${CMAKE_SOURCE_DIR}/thirdparty/faiss-1.5.3")
|
# set(FAISS_SOURCE_URL "${CMAKE_SOURCE_DIR}/thirdparty/faiss-1.5.3")
|
||||||
message(STATUS ${FAISS_SOURCE_URL})
|
message(STATUS ${FAISS_SOURCE_URL})
|
||||||
endif()
|
endif()
|
||||||
set(FAISS_MD5 "a589663865a8558205533c8ac414278c")
|
# set(FAISS_MD5 "a589663865a8558205533c8ac414278c")
|
||||||
|
#set(FAISS_MD5 "31167ecbd1903fec600dc4ac00b9be9e")
|
||||||
|
|
||||||
if(DEFINED ENV{KNOWHERE_ARROW_URL})
|
if(DEFINED ENV{KNOWHERE_ARROW_URL})
|
||||||
set(ARROW_SOURCE_URL "$ENV{KNOWHERE_ARROW_URL}")
|
set(ARROW_SOURCE_URL "$ENV{KNOWHERE_ARROW_URL}")
|
||||||
|
@ -924,7 +925,7 @@ macro(build_faiss)
|
||||||
if(USE_JFROG_CACHE STREQUAL "ON")
|
if(USE_JFROG_CACHE STREQUAL "ON")
|
||||||
# Check_Last_Modify("${CMAKE_SOURCE_DIR}/thirdparty/faiss_cache_check_lists.txt" "${CMAKE_SOURCE_DIR}" FAISS_LAST_MODIFIED_COMMIT_ID)
|
# Check_Last_Modify("${CMAKE_SOURCE_DIR}/thirdparty/faiss_cache_check_lists.txt" "${CMAKE_SOURCE_DIR}" FAISS_LAST_MODIFIED_COMMIT_ID)
|
||||||
string(MD5 FAISS_COMBINE_MD5 "${FAISS_MD5}${LAPACK_MD5}${OPENBLAS_MD5}")
|
string(MD5 FAISS_COMBINE_MD5 "${FAISS_MD5}${LAPACK_MD5}${OPENBLAS_MD5}")
|
||||||
string(MD5 FAISS_COMBINE_MD5 "${FAISS_LAST_MODIFIED_COMMIT_ID}${LAPACK_MD5}${OPENBLAS_MD5}")
|
# string(MD5 FAISS_COMBINE_MD5 "${FAISS_LAST_MODIFIED_COMMIT_ID}${LAPACK_MD5}${OPENBLAS_MD5}")
|
||||||
set(FAISS_CACHE_PACKAGE_NAME "faiss_${FAISS_COMBINE_MD5}.tar.gz")
|
set(FAISS_CACHE_PACKAGE_NAME "faiss_${FAISS_COMBINE_MD5}.tar.gz")
|
||||||
set(FAISS_CACHE_URL "${JFROG_ARTFACTORY_CACHE_URL}/${FAISS_CACHE_PACKAGE_NAME}")
|
set(FAISS_CACHE_URL "${JFROG_ARTFACTORY_CACHE_URL}/${FAISS_CACHE_PACKAGE_NAME}")
|
||||||
set(FAISS_CACHE_PACKAGE_PATH "${THIRDPARTY_PACKAGE_CACHE}/${FAISS_CACHE_PACKAGE_NAME}")
|
set(FAISS_CACHE_PACKAGE_PATH "${THIRDPARTY_PACKAGE_CACHE}/${FAISS_CACHE_PACKAGE_NAME}")
|
||||||
|
|
|
@ -0,0 +1,13 @@
|
||||||
|
# source
|
||||||
|
src/
|
||||||
|
include/
|
||||||
|
|
||||||
|
# third party
|
||||||
|
thirdparty/
|
||||||
|
|
||||||
|
# cmake
|
||||||
|
cmake/
|
||||||
|
CMakeLists.txt
|
||||||
|
|
||||||
|
# script
|
||||||
|
build.sh
|
Loading…
Reference in New Issue