diff options
author | K. Richard Pixley <rich@cygnus> | 1992-02-07 00:33:49 +0000 |
---|---|---|
committer | K. Richard Pixley <rich@cygnus> | 1992-02-07 00:33:49 +0000 |
commit | 424f02027213e8e4ed386bca4d7973022e63dac6 (patch) | |
tree | 17cece6e208ef00badc1b68bb8d5065af4e8e818 | |
parent | ee17fd3437829dcc4a8b65e8c4b49ff249d4d964 (diff) | |
download | gdb-424f02027213e8e4ed386bca4d7973022e63dac6.zip gdb-424f02027213e8e4ed386bca4d7973022e63dac6.tar.gz gdb-424f02027213e8e4ed386bca4d7973022e63dac6.tar.bz2 |
Fix so that "guested" configure scripts work when using -srcdir.
-rwxr-xr-x | configure | 18 |
1 files changed, 12 insertions, 6 deletions
@@ -680,16 +680,22 @@ ${progname}" ${arguments} " POPDIR=${PWD} cd ${configdir} -### figure out what to do with srcdir +### figure out what to do with srcdir & guest configure case "${srcdir}" in - ".") ;; # do nothing. We're building in place. - /*) srcdiroption="-srcdir=${srcdir}/${configdir}" ;; # absolute path - *) srcdiroption="-srcdir=../${srcdir}/${configdir}" ;; # otherwise relative + ".") newsrcdir=${srcdir} ;; # no -srcdir option. We're building in place. + /*) # absolute path + newsrcdir=${srcdir}/${configdir} + srcdiroption="-srcdir=${newsrcdir}" + ;; + *) # otherwise relative + newsrcdir=../${srcdir}/${configdir} + srcdiroption="-srcdir=${newsrcdir}" + ;; esac ### The recursion line is here. - if [ -f configure ] ; then - recprog=`pwd`/configure + if [ -f ${newsrcdir}/configure ] ; then + recprog=${newsrcdir}/configure else recprog=${progname} fi |