- #1
natski
- 267
- 2
Hi all,
I am having difficulty compiling the following code in g95, which is supposed to handle coarrays... The code is:
!
PROGRAM test
implicit none
INTEGER :: a[*]
INTEGER :: m, i
IF ( THIS_IMAGE() == 1 ) THEN
READ(*,*) m
DO i = 1,NUM_IMAGES()
a = m
END DO
END IF
SYNC ALL
END PROGRAM
!
I have been compiling with g95 -o test test.f90 and I get the following compile error:
/tmp/ccKqMbva.o: In function `MAIN_':
test.f90:(.text+0x20): undefined reference to `_g95_this_image'
test.f90:(.text+0x9b): undefined reference to `_g95_num_images'
test.f90:(.text+0xf4): undefined reference to `_g95_store_image'
test.f90:(.text+0x11c): undefined reference to `_g95_sync_all'
I don't understand what the problem is... its almost as if g95 doesn't recognize these supposedly intrinsic functions. Any ideas?
Thanks!
natski
I am having difficulty compiling the following code in g95, which is supposed to handle coarrays... The code is:
!
PROGRAM test
implicit none
INTEGER :: a[*]
INTEGER :: m, i
IF ( THIS_IMAGE() == 1 ) THEN
READ(*,*) m
DO i = 1,NUM_IMAGES()
a = m
END DO
END IF
SYNC ALL
END PROGRAM
!
I have been compiling with g95 -o test test.f90 and I get the following compile error:
/tmp/ccKqMbva.o: In function `MAIN_':
test.f90:(.text+0x20): undefined reference to `_g95_this_image'
test.f90:(.text+0x9b): undefined reference to `_g95_num_images'
test.f90:(.text+0xf4): undefined reference to `_g95_store_image'
test.f90:(.text+0x11c): undefined reference to `_g95_sync_all'
I don't understand what the problem is... its almost as if g95 doesn't recognize these supposedly intrinsic functions. Any ideas?
Thanks!
natski