Skip to content

Commit c70d46c

Browse files
committed
Run iso-fortran-binding tests if dev mode enabled
- Run ISO_Fortran_binding tests if OPENCOARRAYS_DEVELOPER (no matter what) - Also disable tests when not x86_64 - See #523 (comment)
1 parent 50434c1 commit c70d46c

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ string(REGEX REPLACE "-rc[0-9]+$"
8383
"${OpenCoarraysVersion}")
8484

8585
project(opencoarrays VERSION "${OPENCOARRAYS_CMAKE_PROJECT_VERSION}" LANGUAGES C Fortran)
86+
8687
message( STATUS "Building OpenCoarrays version: ${full_git_describe}" )
8788
set(OpenCoarrays_dist_string "OpenCoarrays-${full_git_describe}")
8889
message( STATUS "Building for target architecture: ${CMAKE_SYSTEM_PROCESSOR}" )
@@ -842,7 +843,9 @@ include(cmake/AddInstallationScriptTest.cmake )
842843
add_installation_script_test(installation-scripts.sh src/tests/installation/)
843844

844845
# Test ISO_Fortran_binding library
845-
if( "${CMAKE_C_COMPILER_ID}" STREQUAL "GNU" )
846+
if( (( "${CMAKE_C_COMPILER_ID}" STREQUAL "GNU" ) AND ( "${CMAKE_SYSTEM_PROCESSOR}" STREQUAL "x86_64" ))
847+
OR ( CAF_RUN_DEVELOPER_TESTS OR $ENV{OPENCOARRAYS_DEVELOPER} ) )
848+
# See https://github.com/sourceryinstitute/OpenCoarrays/issues/523#issuecomment-401613209
846849
add_test(NAME ISO_Fortran_binding_tests COMMAND "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/ISO_Fortran_binding_tests")
847850
endif()
848851

src/tests/unit/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ if (${opencoarrays_aware_compiler})
1616
else()
1717
add_subdirectory(extensions)
1818
endif()
19-
if( "${CMAKE_C_COMPILER_ID}" STREQUAL "GNU" )
19+
if( "${CMAKE_C_COMPILER_ID}" STREQUAL "GNU" OR
20+
(CAF_RUN_DEVELOPER_TESTS OR $ENV{OPENCOARRAYS_DEVELOPER}))
2021
add_subdirectory(iso-fortran-binding)
2122
endif()

0 commit comments

Comments
 (0)