Files
rocm-systems/samples/2_Cookbook/19_cmake_lang/CMakeLists.txt
T
ROCm CI Service Account 7cc53f992f SWDEV-402381 - Add hipCheckErrors for HIP API calls in samples (#375)
Change-Id: I335d7e780362fc59fd2d90939b4c8b8a7231ffc7
2023-07-20 10:22:17 +05:30

18 sor
531 B
CMake

# The test must be with CMake 3.18 or above which supports LINK_LANGUAGE that is necessary for
# Fortran build.
cmake_minimum_required(VERSION 3.18.0)
project(cmake_lang_test CXX Fortran)
find_package(hip REQUIRED)
add_executable(test_fortran TestFortran.F90)
add_executable(test_cpp MatrixTranspose.cpp)
target_link_libraries(test_cpp PUBLIC hip::device)
target_include_directories(test_cpp PRIVATE ../../common)
# Assuming to build a C/C++-to-Fortran library binding.
target_link_libraries(test_fortran PUBLIC hip::device)