PATCH for libiberty when NOT using --enable-shared

Manfred Hollstein manfred@s-direktnet.de
Thu May 21 09:00:00 GMT 1998


On Thu, 21 May 1998, 15:49:37, manfred@s-direktnet.de wrote:

 > On Wed, 20 May 1998, 22:46:46, law@hurl.cygnus.com wrote:
 > 
 >  > 
 >  >   In message < 13666.61012.380280.28439@slsvhmt >you write:
 >  >   > # We default to --with-shared on platforms where -fpic is meaningless.
 >  >   > # Well, we don't yet, but we will.
 >  >   > if false && [ "${host}" = "${target}" ] && [ x${enable_shared} = x ]; then
 >  >   >   case "${target}" in
 >  >   >     alpha*-dec-osf*)	enable_shared=yes ;;
 >  >   >     alpha*-*-linux*)	enable_shared=yes ;;
 >  >   >     mips-sgi-irix5*)	enable_shared=yes ;;
 >  >   >     *)			enable_shared=no ;;
 >  >   >   esac
 >  >   > fi
 >  >   > 
 >  >   > case "${enable_shared}" in
 >  >   >   yes) shared=yes ;;
 >  >   >   no) shared=no ;;
 >  >   >   "") shared=no ;;
 >  >   >   *) shared=yes ;;
 >  >   > esac
 >  >   > 
 >  >   > As you can see, in the last case statement ${enable_shared} is used,
 >  >   > without even being touched before, hence its value is undefined
 >  >   > ( == "" ) and shared is set to "no"! This is what my patch does.
 >  > Is it the case that the toplevel configure.in isn't run anymore
 >  > when configuring libiberty?  If so, then that would explain the
 >  > change in behavior.
 >  > 
 >  > If that is indeed the case, then your patch is correct and should
 >  > be installed.
 > 
 > AFAIK, it's no longer run, but if it would, it wouldn't change anything,
 > because it sets "shared" while libiberty's config.table looks at
 > "enable_shared". I'll check in soon.

I've just checked in my patch after having verified once again, I
wasn't talking something wrong.

manfred



More information about the Gcc-bugs mailing list