title: GFortran and CodeBlocks issue with Modules and Multiple Files
body: <p>I am working with GFortran and CodeBlocks but I'm having an issue about Modules and Multiple files.
  i keep getting this error:</p>
  
  <pre><code>Fatal Error: Can't open module file 'mesh.mod' for reading at (1): No such file or directory
  </code></pre>
  
  <p>For some reason, GFortran is not building the 'mesh.mod' file.
  This problem does not occur when I put all the code in a single .f90 file.</p>
  
  <p>Bellow is an example of code that this error happens.</p>
  
  <p>main.f90</p>
  
  <pre><code>MODULE MESH
  IMPLICIT NONE
  INTEGER :: IMAX,JMAX,NMAX
  REAL(8), ALLOCATABLE :: XD(:),YD(:),FX(:,:),FY(:,:)
  REAL(8) :: PI,E,DX,DY,H,L,RHO,MU
  PARAMETER (PI = ACOS(-1.D0))
  PARAMETER (E = 2.718)
  END MODULE MESH
  !**************************************************************
  
  program Cavity
  Use Mesh
  implicit none
  Real(8), Allocatable :: func(:)
  Real(8) :: Der,DfDx
  integer :: i
  
  IMAX=10
  DX=1./10
  
  Allocate(xd(IMAX),func(IMAX))
  
  Do i=1,IMAX
     xd(i)=i*DX
  End Do
  
  Do i=1,IMAX
  func(i) = xd(i)**2
  End Do
  
  Der=Dfdx(func,2)
  Write(*,*) Der
  
  End program Cavity
  </code></pre>
  
  <p>Derivatives.f90</p>
  
  <pre><code>Real(8) Function DfDx(f,i)
          Use Mesh
          implicit none
          Real(8) :: f(1:Imax)
          integer :: i
  
             DfDx=(f(i+1)-f(i-1))/(2d0*dx)
  
          return
  end function DfDx
  </code></pre>
  
  <p>When I use console command line compilation instead of CodeBlocks interface I already solved this problem (<a href="https://stackoverflow.com/questions/17537495/compiling-multiple-files-with-modules">Compiling Multiple Files with modules</a>) but I'm still getting this problem with CodeBlocks.</p>
  
  <p>Does anyone know how to solve this issue?</p>