[RFC] Change bin2c binary to target tool (was [RFA] Fix bin2c executable generation for cross-generation)

Pierre Muller pierre.muller@ics-cnrs.unistra.fr
Fri Nov 5 07:54:00 GMT 2010



> -----Message d'origine-----
> De : binutils-owner@sourceware.org [mailto:binutils-
> owner@sourceware.org] De la part de Ralf Wildenhues
> Envoyé : jeudi 4 novembre 2010 19:50
> À : Tristan Gingold
> Cc : Pierre Muller; binutils@sourceware.org
> Objet : Re: [RFA] Fix bin2c executable generation for cross-generation
> 
> > On Nov 4, 2010, at 4:48 PM, Pierre Muller wrote:
> >
> > >> The patch below uses -lintl instead of $(LIBINTL)
> > >> for bin2c$(EXEEXT_FOR_BUILD) rule.
> 
> The patch is not right, as was already noted.
> 
> One proper solution would be to let toplevel create a build-$build/intl
> if needed, consider whether --{en,dis}able-libintl should apply both to
> build as well as to host tools, or add an --enable-build-libintl
> switch;
> then rename affected variables before/after sourcing the appropriate
> config.intl files from ../intl and ../build-$build/intl, to something
> like LIBINTL_DEPS_FOR_BUILD etc.  Then we only remain at the problem
> that bin2c.c includes sysdeps.h which leads to inclusion of config.h
> which contains data for the host not the build ...
> 
> Since this is a really trivial build tool that is never installed and
> that shouldn't print any localized stuff except in --help output, how
> about removing i18n for it, and simplifying it to the point that it
> needs not include config.h any more?


  The major point is that I do not even understand why this is
a 'build' tool rather than a 'target' tool.

  Maybe it was used at some point in the past to build 
other target binaries like sysinfo$(EXEEXT_FOR_BUILD)
which is used to create sysroff.c source.

  As it isn't used anymore, it has no use as a build tool,
thus I would rather transform this into a target tool...

  Any opinion on this proposal?

Pierre Muller



More information about the Binutils mailing list