gengenrtl needs to link with libintl
Zack Weinberg
zack@codesourcery.com
Tue Oct 30 09:15:00 GMT 2001
On Tue, Oct 30, 2001 at 11:58:40AM -0500, John David Anglin wrote:
> The following error occurs under hppa1.1-hp-hpux10.20 when configured as
> follows:
>
> ../configure --host=hppa1.1-hp-hpux10.20 --with-gnu-as --enable-shared --enable-threads --enable-debug=no
>
> gcc -DIN_GCC -g -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wtraditional -pedantic -Wno-long-long -DHAVE_CONFIG_H -DGENERATOR_FILE -o gengenrtl \
> gengenrtl.o ` case "obstack.o" in ?*) echo obstack.o ;; esac ` ` case "" in ?*) echo ;; esac ` ` case "" in ?*) echo ;; esac ` ` case "" in ?*) echo ;; esac `
> /usr/ccs/bin/ld: Unsatisfied symbols:
> gettext (code)
> collect2: ld returned 1 exit status
gengenrtl (and all other build-time programs) cannot be linked with
libintl until we have the ability to build a second copy of it for the
build!=host case. This is the same problem we have with libiberty.
Until then, we need to find out where the references to gettext are
coming from, and suppress them. (Which does mean that e.g. rtl.o
cannot emit error messages.)
As a wild guess, your problem is this chunk of obstack.o:
/* Define the error handler. */
#ifndef _
# ifdef HAVE_LIBINTL_H
# include <libintl.h>
# ifndef _
# define _(Str) gettext (Str)
# endif
# else
# define _(Str) (Str)
# endif
#endif
static void
print_and_abort ()
{
fputs (_("memory exhausted\n"), stderr);
exit (obstack_exit_failure);
}
You may be able to fix this by adding "-D_(x)=x" (with the quotes) to
the build rule for obstack.o. That's not a permanent solution but it
should get you back to bootstrap land.
zw
More information about the Gcc-bugs
mailing list