Commit 4a4c73fd authored by Mathieu Faverge's avatar Mathieu Faverge

Fix issues reported by @sylvand

parent 49e064cd
...@@ -98,7 +98,7 @@ MACRO(GENERATE_PKGCONFIG_FILE) ...@@ -98,7 +98,7 @@ MACRO(GENERATE_PKGCONFIG_FILE)
set(CUDABLAS_PKGCONFIG_LIBS_PRIVATE "") set(CUDABLAS_PKGCONFIG_LIBS_PRIVATE "")
# A list of packages required by this package # A list of packages required by this package
set(CHAMELEON_PKGCONFIG_REQUIRED "") set(CHAMELEON_PKGCONFIG_REQUIRED "hqr")
set(COREBLAS_PKGCONFIG_REQUIRED "") set(COREBLAS_PKGCONFIG_REQUIRED "")
set(CUDABLAS_PKGCONFIG_REQUIRED "") set(CUDABLAS_PKGCONFIG_REQUIRED "")
......
...@@ -22,7 +22,9 @@ ...@@ -22,7 +22,9 @@
# @date 17-10-2014 # @date 17-10-2014
# #
### ###
if (CHAMELEON_SIMULATION)
message(ERROR "example directory should not be included when simulation is enabled")
endif()
add_subdirectory(basic_zposv) add_subdirectory(basic_zposv)
......
...@@ -66,37 +66,27 @@ elseif(CHAMELEON_SCHED_QUARK) ...@@ -66,37 +66,27 @@ elseif(CHAMELEON_SCHED_QUARK)
link_directories(${QUARK_LIBRARY_DIRS}) link_directories(${QUARK_LIBRARY_DIRS})
endif() endif()
if(NOT CHAMELEON_SIMULATION) if(CHAMELEON_USE_CUDA)
list(APPEND libs_for_examples
if(CHAMELEON_USE_CUDA) cudablas)
list(APPEND libs_for_examples endif()
cudablas) if(CHAMELEON_USE_CUDA)
endif() link_directories(${CUDA_LIBRARY_DIRS})
if(CHAMELEON_USE_CUDA) endif()
link_directories(${CUDA_LIBRARY_DIRS})
endif()
list(APPEND libs_for_examples
coreblas
${LAPACKE_LIBRARIES}
${CBLAS_LIBRARIES}
${LAPACK_SEQ_LIBRARIES}
${BLAS_SEQ_LIBRARIES}
${EXTRA_LIBRARIES}
)
link_directories(${LAPACKE_LIBRARY_DIRS})
link_directories(${LAPACK_LIBRARY_DIRS})
link_directories(${CBLAS_LIBRARY_DIRS})
link_directories(${BLAS_LIBRARY_DIRS})
else()
list(APPEND libs_for_examples list(APPEND libs_for_examples
${EXTRA_LIBRARIES} coreblas
) ${LAPACKE_LIBRARIES}
${CBLAS_LIBRARIES}
${LAPACK_SEQ_LIBRARIES}
${BLAS_SEQ_LIBRARIES}
${EXTRA_LIBRARIES}
)
endif() link_directories(${LAPACKE_LIBRARY_DIRS})
link_directories(${LAPACK_LIBRARY_DIRS})
link_directories(${CBLAS_LIBRARY_DIRS})
link_directories(${BLAS_LIBRARY_DIRS})
# message(STATUS "libs timings: ${libs_for_examples}") # message(STATUS "libs timings: ${libs_for_examples}")
foreach(_example ${EXAMPLES}) foreach(_example ${EXAMPLES})
...@@ -105,7 +95,7 @@ foreach(_example ${EXAMPLES}) ...@@ -105,7 +95,7 @@ foreach(_example ${EXAMPLES})
set_property(TARGET ${_name_exe} PROPERTY LINKER_LANGUAGE Fortran) set_property(TARGET ${_name_exe} PROPERTY LINKER_LANGUAGE Fortran)
target_link_libraries(${_name_exe} ${libs_for_examples}) target_link_libraries(${_name_exe} ${libs_for_examples})
install(TARGETS ${_name_exe} install(TARGETS ${_name_exe}
DESTINATION lib/chameleon/example/basic_zposv) DESTINATION bin/example/basic_zposv )
endforeach() endforeach()
#-------- Tests --------- #-------- Tests ---------
......
...@@ -19,8 +19,6 @@ ...@@ -19,8 +19,6 @@
# @date 2014-10-13 # @date 2014-10-13
# #
### ###
include_directories(${CMAKE_CURRENT_BINARY_DIR}) include_directories(${CMAKE_CURRENT_BINARY_DIR})
include_directories(${CMAKE_CURRENT_SOURCE_DIR}) include_directories(${CMAKE_CURRENT_SOURCE_DIR})
...@@ -94,14 +92,14 @@ foreach(_ltm ${LTM_SOURCES}) ...@@ -94,14 +92,14 @@ foreach(_ltm ${LTM_SOURCES})
set_property(TARGET ${_name_exe} PROPERTY LINKER_LANGUAGE Fortran) set_property(TARGET ${_name_exe} PROPERTY LINKER_LANGUAGE Fortran)
target_link_libraries(${_name_exe} ${libs_for_ltm}) target_link_libraries(${_name_exe} ${libs_for_ltm})
install(TARGETS ${_name_exe} install(TARGETS ${_name_exe}
DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/chameleon/example/lapack_to_morse) DESTINATION bin/example/lapack_to_morse)
endforeach() endforeach()
add_executable(step0 step0.c) add_executable(step0 step0.c)
set_property(TARGET step0 PROPERTY LINKER_LANGUAGE Fortran) set_property(TARGET step0 PROPERTY LINKER_LANGUAGE Fortran)
target_link_libraries(step0 ${libs_for_step0}) target_link_libraries(step0 ${libs_for_step0})
install(TARGETS step0 install(TARGETS step0
DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/chameleon/example/lapack_to_morse) DESTINATION bin/example/lapack_to_morse)
#-------- Tests --------- #-------- Tests ---------
include(CTestLists.cmake) include(CTestLists.cmake)
......
...@@ -65,7 +65,7 @@ foreach(_ooc ${OOC_SOURCES}) ...@@ -65,7 +65,7 @@ foreach(_ooc ${OOC_SOURCES})
endif() endif()
target_link_libraries(${_name_exe} ${libs_for_ooc}) target_link_libraries(${_name_exe} ${libs_for_ooc})
install(TARGETS ${_name_exe} install(TARGETS ${_name_exe}
DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/chameleon/example/out_of_core) DESTINATION bin/example/out_of_core)
endforeach() endforeach()
#-------- Tests --------- #-------- Tests ---------
......
...@@ -25,7 +25,9 @@ ...@@ -25,7 +25,9 @@
# @date 13-07-2012 # @date 13-07-2012
# #
### ###
if (CHAMELEON_SIMULATION)
message(ERROR "testing directory should not be included when simulation is enabled")
endif()
# Check for subdirectories # Check for subdirectories
# ------------------------ # ------------------------
...@@ -106,32 +108,28 @@ list(APPEND libs_for_tests ...@@ -106,32 +108,28 @@ list(APPEND libs_for_tests
chameleon chameleon
) )
if(NOT CHAMELEON_SIMULATION) if(CHAMELEON_USE_CUDA)
list(APPEND libs_for_tests
if(CHAMELEON_USE_CUDA) cudablas)
list(APPEND libs_for_tests endif()
cudablas) if(CHAMELEON_USE_CUDA)
endif() link_directories(${CUDA_LIBRARY_DIRS})
if(CHAMELEON_USE_CUDA) endif()
link_directories(${CUDA_LIBRARY_DIRS})
endif()
list(APPEND libs_for_tests
coreblas
${LAPACKE_LIBRARIES}
${TMG_LIBRARIES}
${LAPACK_LIBRARIES}
${CBLAS_LIBRARIES}
${BLAS_LIBRARIES}
)
link_directories(${LAPACKE_LIBRARY_DIRS}) list(APPEND libs_for_tests
link_directories(${TMG_LIBRARY_DIRS}) coreblas
link_directories(${LAPACK_LIBRARY_DIRS}) ${LAPACKE_LIBRARIES}
link_directories(${CBLAS_LIBRARY_DIRS}) ${TMG_LIBRARIES}
link_directories(${BLAS_LIBRARY_DIRS}) ${LAPACK_LIBRARIES}
${CBLAS_LIBRARIES}
${BLAS_LIBRARIES}
)
endif() link_directories(${LAPACKE_LIBRARY_DIRS})
link_directories(${TMG_LIBRARY_DIRS})
link_directories(${LAPACK_LIBRARY_DIRS})
link_directories(${CBLAS_LIBRARY_DIRS})
link_directories(${BLAS_LIBRARY_DIRS})
list(APPEND libs_for_tests list(APPEND libs_for_tests
hqr hqr
...@@ -166,41 +164,20 @@ foreach(_precision ${CHAMELEON_PRECISION} ) ...@@ -166,41 +164,20 @@ foreach(_precision ${CHAMELEON_PRECISION} )
target_link_libraries(${_precision}testing ${libs_for_tests}) target_link_libraries(${_precision}testing ${libs_for_tests})
install(TARGETS ${_precision}testing install(TARGETS ${_precision}testing
DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/chameleon/testing) DESTINATION bin/testing)
endforeach() endforeach()
# Copy python scripts to use test drivers # Copy python scripts to use test drivers
# --------------------------------------- # ---------------------------------------
if(CHAMELEON_SCHED_STARPU) # Copy launcher
# Copy launcher add_custom_target(testing_launcher ALL
add_custom_target(testing_launcher_starpu ALL COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/chameleon_testing.py
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/chameleon_testing.py ${CMAKE_CURRENT_BINARY_DIR}/chameleon_testing.py)
${CMAKE_CURRENT_BINARY_DIR}/chameleon_testing.py)
# install file # install file
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/chameleon_testing.py install(FILES ${CMAKE_CURRENT_BINARY_DIR}/chameleon_testing.py
DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/chameleon/testing) DESTINATION bin/testing )
endif()
if(CHAMELEON_SCHED_PARSEC)
# Copy launcher
add_custom_target(testing_launcher_parsec ALL
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/chameleon_testing.py
${CMAKE_CURRENT_BINARY_DIR}/chameleon_testing.py)
# install file
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/chameleon_testing.py
DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/chameleon/testing)
endif()
if(CHAMELEON_SCHED_QUARK)
# Copy launcher
add_custom_target(testing_launcher_quark ALL
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/chameleon_testing.py
${CMAKE_CURRENT_BINARY_DIR}/chameleon_testing.py)
# install file
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/chameleon_testing.py
DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/chameleon/testing)
endif()
#-------- Tests --------- #-------- Tests ---------
include(CTestLists.cmake) include(CTestLists.cmake)
......
...@@ -167,28 +167,32 @@ if(CHAMELEON_PREC_S) ...@@ -167,28 +167,32 @@ if(CHAMELEON_PREC_S)
add_executable(morse_xlintsts ${ALINTST} ${SLINTST} ${SCLNTST}) add_executable(morse_xlintsts ${ALINTST} ${SLINTST} ${SCLNTST})
set_property(TARGET morse_xlintsts PROPERTY LINKER_LANGUAGE Fortran) set_property(TARGET morse_xlintsts PROPERTY LINKER_LANGUAGE Fortran)
target_link_libraries(morse_xlintsts ${libs_for_tests}) target_link_libraries(morse_xlintsts ${libs_for_tests})
install(TARGETS morse_xlintsts DESTINATION ${CMAKE_INSTALL_PREFIX}/testing/lin) install(TARGETS morse_xlintsts
DESTINATION bin/testing/lin)
endif() endif()
if(CHAMELEON_PREC_S) if(CHAMELEON_PREC_S)
add_executable(morse_xlintstd ${ALINTST} ${DLINTST} ${DZLNTST}) add_executable(morse_xlintstd ${ALINTST} ${DLINTST} ${DZLNTST})
set_property(TARGET morse_xlintstd PROPERTY LINKER_LANGUAGE Fortran) set_property(TARGET morse_xlintstd PROPERTY LINKER_LANGUAGE Fortran)
target_link_libraries(morse_xlintstd ${libs_for_tests}) target_link_libraries(morse_xlintstd ${libs_for_tests})
install(TARGETS morse_xlintstd DESTINATION ${CMAKE_INSTALL_PREFIX}/testing/lin) install(TARGETS morse_xlintstd
DESTINATION bin/testing/lin)
endif() endif()
if(CHAMELEON_PREC_C) if(CHAMELEON_PREC_C)
add_executable(morse_xlintstc ${ALINTST} ${CLINTST} ${SCLNTST}) add_executable(morse_xlintstc ${ALINTST} ${CLINTST} ${SCLNTST})
set_property(TARGET morse_xlintstc PROPERTY LINKER_LANGUAGE Fortran) set_property(TARGET morse_xlintstc PROPERTY LINKER_LANGUAGE Fortran)
target_link_libraries(morse_xlintstc ${libs_for_tests}) target_link_libraries(morse_xlintstc ${libs_for_tests})
install(TARGETS morse_xlintstc DESTINATION ${CMAKE_INSTALL_PREFIX}/testing/lin) install(TARGETS morse_xlintstc
DESTINATION bin/testing/lin)
endif() endif()
if(CHAMELEON_PREC_Z) if(CHAMELEON_PREC_Z)
add_executable(morse_xlintstz ${ALINTST} ${ZLINTST} ${DZLNTST}) add_executable(morse_xlintstz ${ALINTST} ${ZLINTST} ${DZLNTST})
set_property(TARGET morse_xlintstz PROPERTY LINKER_LANGUAGE Fortran) set_property(TARGET morse_xlintstz PROPERTY LINKER_LANGUAGE Fortran)
target_link_libraries(morse_xlintstz ${libs_for_tests}) target_link_libraries(morse_xlintstz ${libs_for_tests})
install(TARGETS morse_xlintstz DESTINATION ${CMAKE_INSTALL_PREFIX}/testing/lin) install(TARGETS morse_xlintstz
DESTINATION bin/testing/lin)
endif() endif()
# Copy launcher # Copy launcher
......
...@@ -216,7 +216,7 @@ foreach(_timing ${TIMINGS}) ...@@ -216,7 +216,7 @@ foreach(_timing ${TIMINGS})
set_property(TARGET ${_name_exe} PROPERTY LINKER_LANGUAGE Fortran) set_property(TARGET ${_name_exe} PROPERTY LINKER_LANGUAGE Fortran)
target_link_libraries(${_name_exe} ${libs_for_timings}) target_link_libraries(${_name_exe} ${libs_for_timings})
install(TARGETS ${_name_exe} install(TARGETS ${_name_exe}
DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/chameleon/timing) DESTINATION bin/timing)
endforeach() endforeach()
#-------- Tests --------- #-------- Tests ---------
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment