public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "artemeas at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug target/49764] [gcc-avr] Compiling for Arduino is not working Date: Sun, 17 Jul 2011 00:30:00 -0000 [thread overview] Message-ID: <bug-49764-4-rfei5eJ5nn@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-49764-4@http.gcc.gnu.org/bugzilla/> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49764 --- Comment #11 from _artem_ <artemeas at gmail dot com> 2011-07-17 00:30:11 UTC --- ok... sorry. it seams to be a avr-g++ bug or arduino bug. Or avr-g++ has changed something in 4.6.1 so const declarations changed. (Then it's arduino teams job to fix the headers) Ok now I know that the command line is: avr-g++ -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=22 1.cpp 1.cpp (as you asked): extern const int __attribute__((progmem)) p[]; it gives: 1.cpp:1:45: error: variable 'p' must be const in order to be put into read-only section by means of '__attribute__((progmem))' when I add before the "extern ..." something like: const int p[]; it gives me: 1.cpp:1:11: error: uninitialized const 'p' [-fpermissive] 1.cpp:1:13: error: storage size of 'p' isn't known 1.cpp:2:45: error: variable 'p' must be const in order to be put into read-only section by means of '__attribute__((progmem))' So I have now no idea if it's arduino's headers, or avr-g++ is guilty. p.s. here is the thread I started on arduino forum (maybe it'll be usefull for you...): http://arduino.cc/forum/index.php/topic,66710.0.html
next prev parent reply other threads:[~2011-07-17 0:30 UTC|newest] Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top 2011-07-16 16:44 [Bug target/49764] New: " artemeas at gmail dot com 2011-07-16 16:47 ` [Bug target/49764] " artemeas at gmail dot com 2011-07-16 17:26 ` redi at gcc dot gnu.org 2011-07-16 17:34 ` redi at gcc dot gnu.org 2011-07-16 17:57 ` artemeas at gmail dot com 2011-07-16 18:10 ` redi at gcc dot gnu.org 2011-07-16 18:13 ` redi at gcc dot gnu.org 2011-07-16 19:06 ` artemeas at gmail dot com 2011-07-16 19:36 ` redi at gcc dot gnu.org 2011-07-16 19:55 ` artemeas at gmail dot com 2011-07-16 20:26 ` redi at gcc dot gnu.org 2011-07-17 0:30 ` artemeas at gmail dot com [this message] 2011-07-17 9:55 ` redi at gcc dot gnu.org 2011-07-17 9:57 ` redi at gcc dot gnu.org 2011-07-17 10:03 ` redi at gcc dot gnu.org 2011-07-23 18:42 ` gjl at gcc dot gnu.org 2011-07-23 19:27 ` gjl at gcc dot gnu.org 2011-07-23 19:30 ` gjl at gcc dot gnu.org 2011-07-25 10:24 ` [Bug target/49764] [avr-g++] Rejects attribute progmem gjl at gcc dot gnu.org 2011-07-26 19:34 ` artemeas at gmail dot com 2011-07-27 1:19 ` redi at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-49764-4-rfei5eJ5nn@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).