Follow-up Comment #3, bug #32650 (project avr-libc): Please note that this error occurs when the header is included, regardless of whether a constant or a variable is passed (in my case, it was actually a constant), even to the extent that if no calls are made to the delay functions, and the header is included, it fails.
The attached trivial testcase will produce the following error using GCC 4.5.2: make all Building file: ../Testcase.cpp Invoking: AVR C++ Compiler avr-g++ -I"A:eclipsemhvlib" -Wall -Os -fpack-struct -fshort-enums -ffunction-sections -fdata-sections -funsigned-char -funsigned-bitfields -fno-exceptions -mmcu=atmega1280 -DF_CPU=16000000UL -MMD -MP -MF"Testcase.d" -MT"Testcase.d" -c -o"Testcase.o" "../Testcase.cpp" In file included from ../Testcase.cpp:3:0: c:mhvavrtoolsbin../lib/gcc/avr/4.5.2/../../../../avr/include/util/delay.h: In function 'void _delay_ms(double)': c:mhvavrtoolsbin../lib/gcc/avr/4.5.2/../../../../avr/include/util/delay.h:149:42: error: 'fabs' was not declared in this scope c:mhvavrtoolsbin../lib/gcc/avr/4.5.2/../../../../avr/include/util/delay.h:149:43: error: 'ceil' was not declared in this scope c:mhvavrtoolsbin../lib/gcc/avr/4.5.2/../../../../avr/include/util/delay.h: In function 'void _delay_us(double)': c:mhvavrtoolsbin../lib/gcc/avr/4.5.2/../../../../avr/include/util/delay.h:226:42: error: 'fabs' was not declared in this scope c:mhvavrtoolsbin../lib/gcc/avr/4.5.2/../../../../avr/include/util/delay.h:226:43: error: 'ceil' was not declared in this scope make: *** [Testcase.o] Error 1 (file #22840) _______________________________________________________ Additional Item Attachment: File name: Testcase.cpp Size:0 KB _______________________________________________________ Reply to this item at: <http://savannah.nongnu.org/bugs/?32650> _______________________________________________ Message sent via/by Savannah http://savannah.nongnu.org/ _______________________________________________ AVR-libc-dev mailing list AVR-libc-dev@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-libc-dev