Skip to content

Commit

Permalink
去掉cmake中编译openblas (#11)
Browse files Browse the repository at this point in the history
  • Loading branch information
xcnick authored May 17, 2022
1 parent e07be10 commit 7d7915a
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 39 deletions.
25 changes: 0 additions & 25 deletions cmake/External/openblas.cmake

This file was deleted.

18 changes: 6 additions & 12 deletions cmake/third_party.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -117,16 +117,10 @@ set(BLAS "Open" CACHE STRING "Selected BLAS library")
set_property(CACHE BLAS PROPERTY STRINGS "Atlas;Open;MKL")

if(BLAS STREQUAL "Open" OR BLAS STREQUAL "open")
#find_package(OpenBLAS REQUIRED)
# ---[ OpenBlas
include(cmake/External/openblas.cmake)
list(APPEND Latte_INCLUDE_DIRS PRIVATE ${OPENBLAS_INCLUDE_DIRS})
list(APPEND Latte_LINKER_LIBS PRIVATE ${OPENBLAS_LIBRARIES})
# list(APPEND Latte_INCLUDE_DIRS PUBLIC ${OpenBLAS_INCLUDE_DIR})
# list(APPEND Latte_LINKER_LIBS PUBLIC ${OpenBLAS_LIB})
set(BLA_VENDOR OpenBLAS)
elseif(BLAS STREQUAL "MKL" OR BLAS STREQUAL "mkl")
#find_package(MKL REQUIRED)
list(APPEND Latte_INCLUDE_DIRS PRIVATE ${MKL_INCLUDE_DIR})
list(APPEND Latte_LINKER_LIBS PRIVATE ${MKL_LIBRARIES})
list(APPEND Latte_DEFINITIONS PRIVATE -DUSE_MKL)
endif()
set(BLA_VENDOR MKL)
endif()

find_package(BLAS REQUIRED)
list(APPEND Latte_LINKER_LIBS PUBLIC ${BLAS_LIBRARIES})
3 changes: 2 additions & 1 deletion docker/dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
apt-get update && apt-get install -y --no-install-recommends \
git \
wget \
ca-certificates && \
ca-certificates \
libopenblas-dev && \
rm -rf /var/lib/apt/lists/*

RUN wget https://github.com/Kitware/CMake/releases/download/v3.22.1/cmake-3.22.1-linux-x86_64.tar.gz \
Expand Down
3 changes: 2 additions & 1 deletion docker/dockerfile_ci
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
apt-get update && apt-get install -y --no-install-recommends \
git \
wget \
ca-certificates && \
ca-certificates \
libopenblas-dev && \
rm -rf /var/lib/apt/lists/*

RUN wget https://github.com/Kitware/CMake/releases/download/v3.22.1/cmake-3.22.1-linux-x86_64.tar.gz \
Expand Down

0 comments on commit 7d7915a

Please sign in to comment.