I should have been more precise. In fact, I discovered that I had
both g77 and gfortran installed, so that the first step was to uninstall g77.
With respect to file location:
(a) In config.h GRETL_PREFIX = /usr/local.
(b) The config_dump.txt file generated by "gretl --dump" includes
# Main gretl directory
gretldir = /usr/local/share/gretl/
(c) The effect of cleaning out ~/.gretl2rc appears to be different in
Ubuntu and OpenSUSE. Under Ubuntu, everything is ok when I recompile
gretl after doing this. Under OpenSUSE I need to edit ~/.gretl2rc to
ensure that gretldir is set correctly - alternatively that can be
done from the Tools/Preferences options.
At this point I don't think that the issue is worth any more
effort. Clearly, getting rid of old versions of ~/.gretl2rc is a
good idea. Incidentally that may mean looking in the /root directory
as well as /home/user if at some stage in the past one has run gretl
from the terminal as a superuser. Otherwise, the problems that I
have encountered seem to be unusual and must reflect the history of
several installations of gretl on my OpenSUSE system.
Gordon