mirror of
https://github.com/Kitware/CMake.git
synced 2026-05-12 17:19:05 -05:00
FindOpenACC: Provide a Fortran snippet that compiles with gfortran
The original Fortran snippet would fail to compile with the error
message of:
```
return 0;
1
Error: Alternate RETURN statement at (1) is only allowed within a SUBROUTINE
```
We solve this by removing the early termination logic.
This commit is contained in:
@@ -60,9 +60,7 @@ int main(){
|
|||||||
set(OpenACC_Fortran_TEST_SOURCE
|
set(OpenACC_Fortran_TEST_SOURCE
|
||||||
"
|
"
|
||||||
program test
|
program test
|
||||||
#ifdef _OPENACC
|
#ifndef _OPENACC
|
||||||
return 0;
|
|
||||||
#else
|
|
||||||
breaks_on_purpose
|
breaks_on_purpose
|
||||||
#endif
|
#endif
|
||||||
endprogram test
|
endprogram test
|
||||||
|
|||||||
Reference in New Issue
Block a user