This is the mail archive of the crossgcc@sourceware.org mailing list for the crossgcc project.
See the CrossGCC FAQ for lots more information.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
On Fri, Dec 10, 2010 at 10:03 AM, Yann E. MORIN <yann.morin.1998@anciens.enib.fr> wrote: > Bryan, All, > > On Friday 10 December 2010 00:47:13 Bryan Hundven wrote: >> >> On Thu, Dec 9, 2010 at 2:06 PM, Yann E. MORIN >> >> <yann.morin.1998@anciens.enib.fr> wrote: >> >>> On Tuesday 07 December 2010 10:06:57 Bryan Hundven wrote: > [--SNIP--] >> >>>> diff -r 73795525c82e -r 8f7cc140fe23 scripts/crosstool-NG.sh.in >> >>>> --- a/scripts/crosstool-NG.sh.in   ÂMon Dec 06 22:42:07 2010 -0800 >> >>>> +++ b/scripts/crosstool-NG.sh.in   ÂTue Dec 07 00:56:34 2010 -0800 >> >>>> @@ -151,6 +151,16 @@ >> >>>> ÂCT_CC_CORE_EXTRA_CONFIG="${CT_ARCH_CC_CORE_EXTRA_CONFIG} ${CT_CC_CORE_EXTRA_CONFIG}" >> >>>> ÂCT_CC_EXTRA_CONFIG="${CT_ARCH_CC_EXTRA_CONFIG} ${CT_CC_EXTRA_CONFIG}" >> >>>> >> >>>> +# If we are using a gcc snapshot, get the real "version number" straight >> >>>> +# here so we don't have to modify the build scripts. >> >>>> +if [ "${CT_CC_V_4_5_SNAPSHOT}" = "y" -o "${CT_CC_V_4_6_SNAPSHOT}" = "y" ]; then >> >>>> +  Âif [ -n "${CT_CC_SNAPSHOT}" ]; then >> >>>> +    ÂCT_CC_VERSION="${CT_CC_VERSION}${CT_CC_SNAPSHOT}" >> >>>> +  Âelse >> >>>> +    ÂCT_Abort "You forgot to set the gcc snapshot date!" >> >>>> +  Âfi >> >>>> +fi >> >>> >> >>> This should go to the gcc.sh script. I know you needed it to be globally >> >>> available for the strip phase above, but that will no longer be needed. >> >> >> >> ack. >> > >> > Actually, come to think about it, when you use the snapshot, the >> > ${CT_CC_VERSION} - which for a snapshot would be something like: >> > 4.6-20101204 - would not be what gcc-${CT_CC_VERSION} is. >> > >> > Say I used said snapshot, gcc-${CT_CC_VERSION} would be 4.6.0, because >> > that is what is in ${CT_SRC_DIR}/gcc-${CT_CC_VERSION}/gcc/BASE-VER > [--SNIP--] >> >>>> +# When referencing the real gcc version, and not the (possibly) snapshot >> >>>> +# version, use ${CT_CC_REAL_VERSION} instead of the (possibly) snapshot >> >>>> +# version. >> >>>> +CT_CC_REAL_VERSION=$(cat ${CT_SRC_DIR}/gcc-${CT_CC_VERSION}/gcc/BASE-VER) >> >>>> + >> >>>> Â# Now for the job by itself. Go have a coffee! >> >>>> Âif [ "${CT_ONLY_DOWNLOAD}" != "y" -a "${CT_ONLY_EXTRACT}" != "y" ]; then >> >>>>   Â# Because of CT_RESTART, this becomes quite complex > >> And after _actually_ looking at the change you made to internals.sh, >> these are the two that would need ${CT_CC_REAL_VERSION}: >> "libexec/gcc/${CT_TARGET}/${CT_CC_VERSION}/"*         \ >> "libexec/gcc/${CT_TARGET}/${CT_CC_VERSION}/install-tools/"*  \ > > Yes, for now. But I would like to get rid of it. The fact is that will break > if/when we add another compiler (eg. I think about Clang), and CT_CC_VERSION > would not be set in that case. > > So, we have a few possibilities: > - use wildcards, such as: libexec/gcc/${CT_TARGET}/*/* but that would break > Âas well, because it still has 'gcc' in it. > - ask the compiler its name and version, a bit like we have for the C > Âlibrary, eg. ${CT_LIBC} contains the libc name (uClibc, eglibc...), we > Âcould have CT_CC contain the compiler name. Also, like we do for newlib, > Âhave a function that computes and echoes the complete version string, > Âeg. use something like: cc_ver="$(cc_${CT_CC}_version)" > ÂBut that may still be broken, if another compiler installs things in > Âother places. That's moot for now, however, and we can live with that > Âknown layout for now... > - expect each and every components to install-strip. This is not really > Âpossible for some/most of them, and not very convenient as all of them > Âwould have to do conditional install, and this would make the scripts > Â(a little more) ugly. > > Well, I'd vote for #1 above, until we have a reason to do better. What about > you? > > Regards, > Yann E. MORIN. > > -- > .-----------------.--------------------.------------------.--------------------. > | ÂYann E. MORIN Â| Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | > | +33 662 376 056 | Software ÂDesigner | \ / CAMPAIGN   | Â___        | > | +33 223 225 172 `------------.-------: ÂX ÂAGAINST   Â| Â\e/ ÂThere is no Â| > | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL  Â|  v  conspiracy. Â| > '------------------------------^-------^------------------^--------------------' > for _path in "LIST OF PATHS"; do for _file in $(find ${_path} -type f | xargs file | grep 'not stripped' | cut -d: -f1); do ${CT_TARGET}-strip ${_file}; done done -Bryan -- For unsubscribe information see http://sourceware.org/lists.html#faq
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |