How do I get gcc to not treat warnings as errors ??

Started by jpepe333 August 3, 2007
Hello,

I'm using the Eclipse / Yagarto / gcc toolchain (as distributed by
Atmel with their Evaluation Kit) to build a target,
and generate a .bin file for a AT91SAM7X256-EK (evaluation board).

The following is the console output dialogue:

make -C nutapp/httpd USE_UROM=yes USE_MMC=yes all
make: Entering directory `/cygdrive/c/SAM Studio
0.2/workspace/NutOS/nutapp/httpd'

make -C ../.././nutbld/lib/.. install

make[1]: Entering directory `/cygdrive/c/SAM Studio
0.2/workspace/NutOS/nutbld'

make -C arch install
make[2]: Entering directory `/cygdrive/c/SAM Studio
0.2/workspace/NutOS/nutbld/arch'

arm-elf-gcc -MD -c -mcpu=arm7tdmi -Os -mthumb-interwork -fomit-frame-
pointer -Wall -Werror -Wstrict-prototypes -Wa,-
ahlms=arm/dev/ostimer_at91.lst -DUSE_UROM -DUSE_MMC -DAT91SAM7X_EK -
DAT91SAM7X_EK -I../.././nutbld/include -I../.././nut/include -
I'C:\SAM Studio 0.2\workspace/../yagarto/arm-elf/include' -I'C:\SAM
Studio 0.2\workspace/../yagarto/lib/gcc/arm-
elf/4.1.1/include' ../.././nut/arch/arm/dev/ostimer_at91.c -o
arm/dev/ostimer_at91.o

cc1.exe: warnings being treated as errors

../.././nut/arch/arm/dev/ostimer_at91.c:246:
warning: 'At91GetPllClock' defined but not used

make[2]: *** [arm/dev/ostimer_at91.o] Error 1
make[2]: Leaving directory `/cygdrive/c/SAM Studio
0.2/workspace/NutOS/nutbld/arch'

make[1]: *** [install] Error 2
make[1]: Leaving directory `/cygdrive/c/SAM Studio
0.2/workspace/NutOS/nutbld'

make: Leaving directory `/cygdrive/c/SAM Studio
0.2/workspace/NutOS/nutapp/httpd'

make: *** [MAKE_LIBS] Error 2

Can anyone tell me how to turn off the 'warnings being treated as
errors' option ?

Thanks,

Joe
jpepe333 wrote:
> Hello,
>

Hi,

> arm-elf-gcc -MD -c -mcpu=arm7tdmi -Os -mthumb-interwork -fomit-frame-
> pointer -Wall -Werror -Wstrict-prototypes -Wa,-
> ahlms=arm/dev/ostimer_at91.lst -DUSE_UROM -DUSE_MMC -DAT91SAM7X_EK -
> DAT91SAM7X_EK -I../.././nutbld/include -I../.././nut/include -
> I'C:\SAM Studio 0.2\workspace/../yagarto/arm-elf/include' -I'C:\SAM
> Studio 0.2\workspace/../yagarto/lib/gcc/arm-
> elf/4.1.1/include' ../.././nut/arch/arm/dev/ostimer_at91.c -o
> arm/dev/ostimer_at91.o
>
> cc1.exe: warnings being treated as errors
>
> ../.././nut/arch/arm/dev/ostimer_at91.c:246:
> warning: 'At91GetPllClock' defined but not used
>
> make[2]: *** [arm/dev/ostimer_at91.o] Error 1
> make[2]: Leaving directory `/cygdrive/c/SAM Studio
> 0.2/workspace/NutOS/nutbld/arch'
>
> make[1]: *** [install] Error 2
> make[1]: Leaving directory `/cygdrive/c/SAM Studio
> 0.2/workspace/NutOS/nutbld'
>
> make: Leaving directory `/cygdrive/c/SAM Studio
> 0.2/workspace/NutOS/nutapp/httpd'
>
> make: *** [MAKE_LIBS] Error 2
>
> Can anyone tell me how to turn off the 'warnings being treated as
> errors' option ?
>

It is the "-Werror" option.

Regards
Caglar AKYUZ