# Is there any Fortran compiler works on freebsd 8.1 amd64?



## gchnhn (Nov 6, 2010)

I installed g95, gcc42 via pkg_add -r g95; pkg_add -r gcc42. Then I wrote a hello world program in fortran90 form.

```
hello.f90
program hello
write(*,*) 'hello world'
end
```
I type g95 hello.f90, it says

```
[g@g /usr/home/g]$ g95 hello.f90
ld: cannot find -lf95
```
and gcc it says

```
[g@g /usr/home/g]$ gcc hello.f90
gcc: hello.f90: Fortran compiler not installed on this system
```
So, what should i do to compile fortran90 programs on my computer?


----------



## expl (Nov 6, 2010)

Try to add "-L/usr/local/lib" for g95.


----------



## gchnhn (Nov 7, 2010)

expl said:
			
		

> Try to add "-L/usr/local/lib" for g95.



Thanks,I have changed to Fedoraï¼ŒBut I still miss the simplicity and tidiness of FreeBSD.


----------



## dead_rabbit (Oct 1, 2011)

expl said:
			
		

> Try to add "-L/usr/local/lib" for g95.



That works


----------

