mirror of
https://github.com/CNugteren/CLBlast.git
synced 2024-08-27 15:27:01 +02:00
Fixes for Visual Studio
This commit is contained in:
parent
9bccc2544a
commit
748df9bf75
|
@ -53,14 +53,14 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL Intel)
|
||||||
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 14.0)
|
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 14.0)
|
||||||
message(FATAL_ERROR "ICC version must be at least 14.0")
|
message(FATAL_ERROR "ICC version must be at least 14.0")
|
||||||
endif()
|
endif()
|
||||||
elseif(CMAKE_CXX_COMPILER_ID STREQUAL MSVC)
|
elseif(MSVC)
|
||||||
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 18.0)
|
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 18.0)
|
||||||
message(FATAL_ERROR "MS Visual Studio version must be at least 18.0")
|
message(FATAL_ERROR "MS Visual Studio version must be at least 18.0")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# C++ compiler settings
|
# C++ compiler settings
|
||||||
if(CMAKE_CXX_COMPILER_ID STREQUAL MSVC)
|
if(MSVC)
|
||||||
set(FLAGS "/Ox")
|
set(FLAGS "/Ox")
|
||||||
set(FLAGS "${FLAGS} /wd4715")
|
set(FLAGS "${FLAGS} /wd4715")
|
||||||
else()
|
else()
|
||||||
|
@ -80,7 +80,7 @@ endif()
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${FLAGS}")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${FLAGS}")
|
||||||
|
|
||||||
# C compiler settings (for the sample)
|
# C compiler settings (for the sample)
|
||||||
if(CMAKE_CXX_COMPILER_ID STREQUAL MSVC)
|
if(MSVC)
|
||||||
set(CFLAGS "/Ox")
|
set(CFLAGS "/Ox")
|
||||||
else()
|
else()
|
||||||
set(CFLAGS "-O3 -std=c99")
|
set(CFLAGS "-O3 -std=c99")
|
||||||
|
|
|
@ -60,7 +60,7 @@ Furthermore, to build the (optional) correctness and performance tests, another
|
||||||
- BLIS
|
- BLIS
|
||||||
- Accelerate
|
- Accelerate
|
||||||
|
|
||||||
An example of an out-of-source build (starting from the root of the CLBlast folder):
|
An example of an out-of-source build using a command-line compiler and make (starting from the root of the CLBlast folder):
|
||||||
|
|
||||||
mkdir build
|
mkdir build
|
||||||
cd build
|
cd build
|
||||||
|
@ -68,6 +68,12 @@ An example of an out-of-source build (starting from the root of the CLBlast fold
|
||||||
make
|
make
|
||||||
sudo make install
|
sudo make install
|
||||||
|
|
||||||
|
When using Visual Studio, the project-files can be generated as follows:
|
||||||
|
|
||||||
|
mkdir build
|
||||||
|
cd build
|
||||||
|
cmake -G "Visual Studio 14 Win64" ..
|
||||||
|
|
||||||
A custom installation folder can be specified when calling CMake:
|
A custom installation folder can be specified when calling CMake:
|
||||||
|
|
||||||
cmake -DCMAKE_INSTALL_PREFIX=/path/to/install/directory ..
|
cmake -DCMAKE_INSTALL_PREFIX=/path/to/install/directory ..
|
||||||
|
|
Loading…
Reference in a new issue