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]

Re: How to pass gcc extra configs with special character to ct-ng


On Tue, Aug 24, 2010 at 7:58 PM, Yann E. MORIN
<yann.morin.1998@anciens.enib.fr> wrote:
> Chih-Min, All,
>
> On Tuesday 24 August 2010 13:42:06 Chih-Min Chao wrote:
>> I want pass below extra config to gcc-core and gcc
>>
>> --with-specs=%{funwind-tables|
>> fno-unwind-tables|mabi=*|ffreestanding|nostdlib:;:-funwind-tables}
>> %{O2:%{!fno-remove-local-statics: -fremove-local-statics}}
>> %{O*:%{O|O0|O1|O2|Os:;:%{!fno-remove-local-statics:
>> -fremove-local-statics}}}
>>
>> The error will be
>> /home/cmchao/tool/lib/ct-ng-1.8.0/scripts/functions: line 82: printf:
>> `{': invalid format character
>
> Care to test the attached patch, please?

Thank for your quick reply

The patch works
The printf format problem is solved but another occurs

[DEBUG]    ==> Executing:
'/home/cmchao/tool/test/x-ng/targets/src/gcc-4.4.3/configure
--build=i686-build_pc-linux-gnu --host=i686-build_pc-linux-gnu
--target=arm-igs-linux-gnueabi
--prefix=/home/cmchao/tool/test/x-ng/targets/arm-igs-linux-gnueabi/build/gcc-core-static
--with-local-prefix=/home/cmchao/x-tools/arm-igs-linux-gnueabi/arm-igs-linux-gnueabi//sys-root
--disable-multilib --disable-libmudflap
--with-sysroot=/home/cmchao/x-tools/arm-igs-linux-gnueabi/arm-igs-linux-gnueabi//sys-root
--with-newlib --enable-threads=no --disable-shared
--with-pkgversion=crosstool-NG-1.8.0 --with-arch=armv5te
--enable-__cxa_atexit
--with-gmp=/home/cmchao/tool/test/x-ng/targets/arm-igs-linux-gnueabi/build/static
--with-mpfr=/home/cmchao/tool/test/x-ng/targets/arm-igs-linux-gnueabi/build/static
--with-ppl=/home/cmchao/tool/test/x-ng/targets/arm-igs-linux-gnueabi/build/static
--with-cloog=/home/cmchao/tool/test/x-ng/targets/arm-igs-linux-gnueabi/build/static
--enable-target-optspace --disable-nls --enable-symvers=gnu
--enable-languages=c --disable-libssp --disable-lto --disable-libgomp
--disable-decimal-float --disable-libffi --enable-threads
'--with-specs=%{funwind-tables|fno-unwind-tables|mabi=*|ffreestanding|nostdlib:;:-funwind-tables}
%{O2:%{!fno-remove-local-statics: -fremove-local-statics}}
%{O*:%{O|O0|O1|O2|Os:;:%{!fno-remove-local-statics:
-fremove-local-statics}}}''
[ERROR]    configure: error: invalid variable name: '--with-specs
[ERROR]    Build failed in step 'Installing static core C compiler'
[ERROR]    Error happened in
'/home/cmchao/tool/lib/ct-ng-1.8.0/scripts/functions' in function
'CT_DoExecLog' (line unknown, sorry)
[ERROR]          called from
'/home/cmchao/tool/lib/ct-ng-1.8.0/scripts/build/cc/gcc.sh' at line #
187 in function 'do_cc_core'
[ERROR]          called from
'/home/cmchao/tool/lib/ct-ng-1.8.0/scripts/build/cc/gcc.sh' at line #
52 in function 'do_cc_core_pass_1'
[ERROR]          called from
'/home/cmchao/tool/lib/ct-ng-1.8.0/scripts/crosstool-NG.sh' at line #
586 in function 'main'


if i don't quote  --with-spec  or use it in  --with-spec='blah blah'
format, the error will be
[DEBUG]    ==> Executing:
'/home/cmchao/tool/test/x-ng/targets/src/gcc-4.4.3/configure
--build=i686-build_pc-linux-gnu --host=i686-build_pc-linux-gnu
--target=arm-igs-linux-gnueabi
--prefix=/home/cmchao/tool/test/x-ng/targets/arm-igs-linux-gnueabi/build/gcc-core-static
--with-local-prefix=/home/cmchao/x-tools/arm-igs-linux-gnueabi/arm-igs-linux-gnueabi//sys-root
--disable-multilib --disable-libmudflap
--with-sysroot=/home/cmchao/x-tools/arm-igs-linux-gnueabi/arm-igs-linux-gnueabi//sys-root
--with-newlib --enable-threads=no --disable-shared
--with-pkgversion=crosstool-NG-1.8.0 --with-arch=armv5te
--enable-__cxa_atexit
--with-gmp=/home/cmchao/tool/test/x-ng/targets/arm-igs-linux-gnueabi/build/static
--with-mpfr=/home/cmchao/tool/test/x-ng/targets/arm-igs-linux-gnueabi/build/static
--with-ppl=/home/cmchao/tool/test/x-ng/targets/arm-igs-linux-gnueabi/build/static
--with-cloog=/home/cmchao/tool/test/x-ng/targets/arm-igs-linux-gnueabi/build/static
--enable-target-optspace --disable-nls --enable-symvers=gnu
--enable-languages=c --disable-libssp --disable-lto --disable-libgomp
--disable-decimal-float --disable-libffi --enable-threads
--with-specs='%{funwind-tables|fno-unwind-tables|mabi=*|ffreestanding|nostdlib:;:-funwind-tables}
%{O2:%{!fno-remove-local-statics: -fremove-local-statics}}
%{O*:%{O|O0|O1|O2|Os:;:%{!fno-remove-local-statics:
-fremove-local-statics}}}''
[ALL  ]    configure: WARNING: you should use --build, --host, --target
[ALL  ]    configure: WARNING: invalid host type:
%{O2:%{!fno-remove-local-statics:
[ERROR]    configure: error: unrecognized option: -fremove-local-statics}}
[ALL  ]    Try `/home/cmchao/tool/test/x-ng/targets/src/gcc-4.4.3/configure
--help' for more information.
[ERROR]    Build failed in step 'Installing static core C compiler'
[ERROR]    Error happened in
'/home/cmchao/tool/lib/ct-ng-1.8.0/scripts/functions' in function
'CT_DoExecLog' (line unknown, sorry)
[ERROR]          called from
'/home/cmchao/tool/lib/ct-ng-1.8.0/scripts/build/cc/gcc.sh' at line #
187 in function 'do_cc_core'
[ERROR]          called from
'/home/cmchao/tool/lib/ct-ng-1.8.0/scripts/build/cc/gcc.sh' at line #
52 in function 'do_cc_core_pass_1'
[ERROR]          called from
'/home/cmchao/tool/lib/ct-ng-1.8.0/scripts/crosstool-NG.sh' at line #
586 in function 'main'

>
> 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 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]