[Top][All Lists]

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

[avr-libc-dev] [bug #36581] avr-libc: pgmspace.h is not ANSI compliant

From: Bernhard
Subject: [avr-libc-dev] [bug #36581] avr-libc: pgmspace.h is not ANSI compliant
Date: Sun, 03 Jun 2012 08:45:19 +0000
User-agent: Mozilla/5.0 (X11; Linux i686; rv:10.0.4) Gecko/20100101 Firefox/10.0.4 Iceweasel/10.0.4


                 Summary: avr-libc: pgmspace.h is not ANSI compliant
                 Project: AVR C Runtime Library
            Submitted by: bewo1
            Submitted on: So 03 Jun 2012 08:45:19 GMT
                Category: Library
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Header files
                  Status: None
        Percent Complete: 0%
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 1.8.0
           Fixed Release: None




I filed this bug report to the Debian project:

The problem is the inline-attribute, that is not part of ANSI-C.

Here, the complete bug report:


the header file pgmspace.h uses the inline-attribute.
This attribute is not part of ANSI C.

My programs are compiled with the option -ansi.
Here is a minimal test program:

> #include <avr/io.h>
> #include <avr/pgmspace.h>
> int main (void)
> {
>       while (1);
>       return (0);
> }

Please compile this with:
$ avr-gcc -mmcu=atmega644p -ansi <file>

Compilation aborts because of the non-ansi include attribute in pgmspace.h

In GCC manual:
there is the predefined macro __STRICT_ANSI__ available, if parameter -ansi is
Please don't use the inline-attribute in case of __STRICT_ANSI__.

In avr-libc manual:
it is described, that this library has to be an ansi-c library.
This is described in chapter 1.2.

If you need more informations, please let me know.

Best regards


Reply to this item at:


  Nachricht gesendet von/durch Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]