[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#644990: NEWS.Debian.gz: s/$arch/<triplet>



Sedat Dilek wrote:
> On Fri, Oct 14, 2011 at 9:44 PM, Jonathan Nieder <jrnieder@gmail.com> wrote:

>> It means that you might want to pass those flags to the compiler.
>> The compiler doesn't examine any environment variables, so your
>> "export CFLAGS" incantation isn't going to do that, depending on the
>> build system.
>
> You mean something like "make CC='gcc ...'" ?
> What exactly do I need to pass?

I mean

	gcc -B... -I... -o hello-world hello-world.c

Beyond that, it's going to depend on the build system of the project
you're working on, no?  That's why a wrapper like

	#!/bin/sh
	exec /path/to/gcc -B... -I... "$@"

can save trouble.

>> When building a compiler, there is a bootstrap step, meaning there are
>> multiple compilers to pass the flags to.  I thought there was already
>> a bug report about making this easier (#637232) which unfortunately no
>> one seems to be working on.
>
> Unfortunately.

Actually, you seem to have been working on it. :)  Thanks for your
experiments.

[...]
> With my 2 workarounds I can use my gcc-4.7 binaries OOTB. No
> wrapper-script etc. (so I prefer my way).

You mean with the symlinks?  But won't you need symlinks for every library
in /lib/<arch> and /usr/lib/<arch>, including:

 - libz
 - libbz2
 - libncurses
 - libpng
 - gcj libs
 - libflac
 - libgl
 - libice
 - libsm
 - libx11
 - libxau
 - ...
 - libarchive
 - libasound
 - libavcodec
 - libc
 etc

?  I fear I'm missing something.

>> But what does this have to do with the "<triplet>" text in libc6-dev's
>> NEWS.Debian.gz?
>
> I wanted to point out that building with -B and -I options might not
> be enough to really use your generated new binaries.

Ok, so it sounds like the text really was unclear.  The _intent_ was
that to use a compiler named "foo", you might want to try

	foo -B... -I... ...

or some equivalent command.  For example, during the gcc build, you
might want to configure the build system to use

	xgcc -B... -I... ...

After a new gcc is built, you might want to configure other projects
to invoke

	gcc -B... -I... ...

The text is not meant to be a recipe that works in all cases (since
libc6 is just a C library, not a reference manual for all compilers
and build systems ever written), but just a heads up about a change
that can affect people.

Thanks for noticing.  Any ideas about how to make it clearer?



Reply to: