[HIPIFY][cmake] Make CMakeLists.txt compatible with default cmake 3.5.2 for Ubuntu 16.04
+ Update README.md accordingly
This commit is contained in:
@@ -1,8 +1,4 @@
|
||||
if (CUDA_VERSION VERSION_GREATER "9.2")
|
||||
cmake_minimum_required(VERSION 3.12.3)
|
||||
else()
|
||||
cmake_minimum_required(VERSION 3.7.2)
|
||||
endif()
|
||||
cmake_minimum_required(VERSION 3.5.2)
|
||||
|
||||
project(hipify-clang)
|
||||
|
||||
@@ -58,7 +54,7 @@ target_link_libraries(hipify-clang PRIVATE
|
||||
LLVMOption
|
||||
LLVMCore)
|
||||
|
||||
if (LLVM_PACKAGE_VERSION VERSION_GREATER_EQUAL "7")
|
||||
if (LLVM_PACKAGE_VERSION VERSION_GREATER "6.0.1")
|
||||
target_link_libraries(hipify-clang PRIVATE clangToolingInclusions)
|
||||
endif()
|
||||
|
||||
@@ -72,7 +68,7 @@ else()
|
||||
set(StdCpp "-std=c++")
|
||||
endif()
|
||||
|
||||
if (LLVM_PACKAGE_VERSION VERSION_GREATER_EQUAL "10.0")
|
||||
if (LLVM_PACKAGE_VERSION VERSION_GREATER "9.0")
|
||||
string(APPEND StdCpp "14")
|
||||
# MSVC starting from 1900 (VS 2015) supports only the following c++ std values: c++14|c++17|c++latest
|
||||
elseif (MSVC)
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
In most cases, you can get a suitable version of LLVM+CLANG with your package manager.
|
||||
|
||||
Failing that or having multiple versions of LLVM, you can [download a release archive](http://releases.llvm.org/), build or install it, and set
|
||||
[CMAKE_PREFIX_PATH](https://cmake.org/cmake/help/v3.12/variable/CMAKE_PREFIX_PATH.html) so `cmake` can find it; for instance: `-DCMAKE_PREFIX_PATH=f:\LLVM\9.0.0\dist`
|
||||
[CMAKE_PREFIX_PATH](https://cmake.org/cmake/help/v3.5/variable/CMAKE_PREFIX_PATH.html) so `cmake` can find it; for instance: `-DCMAKE_PREFIX_PATH=f:\LLVM\9.0.0\dist`
|
||||
|
||||
## <a name="build-and-install"></a> Build and install
|
||||
|
||||
@@ -196,7 +196,7 @@ Ubuntu 16-18: LLVM 8.0.0 - 9.0.0, CUDA 8.0 - 10.1, cudnn-5.1.10 - cudnn-7.6.4.38
|
||||
|
||||
Build system for the above configurations:
|
||||
|
||||
Python 2.7 (min), cmake 3.12.3 (min), GNU C/C++ 5.4.0 (min).
|
||||
Python 2.7 (min), cmake 3.5.2 (min), GNU C/C++ 5.4.0 (min).
|
||||
|
||||
Here is an example of building `hipify-clang` with testing support on `Ubuntu 16.04`:
|
||||
|
||||
@@ -345,7 +345,7 @@ LLVM 7.0.0 - 9.0.0, CUDA 7.5 - 10.1, cudnn-7.0.5.15 - cudnn-7.6.4.38
|
||||
|
||||
Build system for the above configurations:
|
||||
|
||||
Python 3.6 - 3.7.4, cmake 3.12.3 - 3.15.5, Visual Studio 2017 (15.5.2) - 2019 (16.3.4).
|
||||
Python 3.6 - 3.7.4, cmake 3.5.2 - 3.15.5, Visual Studio 2017 (15.5.2) - 2019 (16.3.4).
|
||||
|
||||
Here is an example of building `hipify-clang` with testing support on `Windows 10` by `Visual Studio 16 2019`:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user