X11 and Open Motif libraries
As noted OSX uses .dylib and not .so for shared libraries.

For motif I would install this as a port via macports and get the openmotif port. Note that macports will install a newer version of X11 from a  as well so this will take time.

then you will need a fortran compiler - note that Apple's gcc does not have Fortran as far as I understand so you will have to install that via macports as well - either a new gcc for possibly gfortran - I don't know the details.