{"action":"created","issue":{"url":"https://api.github.com/repos/arduino-cmake/arduino-cmake/issues/67","repository_url":"https://api.github.com/repos/arduino-cmake/arduino-cmake","labels_url":"https://api.github.com/repos/arduino-cmake/arduino-cmake/issues/67/labels{/name}","comments_url":"https://api.github.com/repos/arduino-cmake/arduino-cmake/issues/67/comments","events_url":"https://api.github.com/repos/arduino-cmake/arduino-cmake/issues/67/events","html_url":"https://github.com/arduino-cmake/arduino-cmake/issues/67","id":292252908,"node_id":"MDU6SXNzdWUyOTIyNTI5MDg=","number":67,"title":"A simple project, when compiled using arduino-cmake, does not fit on the board. ","user":{"login":"kigster","id":259982,"node_id":"MDQ6VXNlcjI1OTk4Mg==","avatar_url":"https://avatars0.githubusercontent.com/u/259982?v=4","gravatar_id":"","url":"https://api.github.com/users/kigster","html_url":"https://github.com/kigster","followers_url":"https://api.github.com/users/kigster/followers","following_url":"https://api.github.com/users/kigster/following{/other_user}","gists_url":"https://api.github.com/users/kigster/gists{/gist_id}","starred_url":"https://api.github.com/users/kigster/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kigster/subscriptions","organizations_url":"https://api.github.com/users/kigster/orgs","repos_url":"https://api.github.com/users/kigster/repos","events_url":"https://api.github.com/users/kigster/events{/privacy}","received_events_url":"https://api.github.com/users/kigster/received_events","type":"User","site_admin":false},"labels":[{"id":700830208,"node_id":"MDU6TGFiZWw3MDA4MzAyMDg=","url":"https://api.github.com/repos/arduino-cmake/arduino-cmake/labels/kind/bug","name":"kind/bug","color":"ee0701","default":false},{"id":700832546,"node_id":"MDU6TGFiZWw3MDA4MzI1NDY=","url":"https://api.github.com/repos/arduino-cmake/arduino-cmake/labels/state/information_needed","name":"state/information_needed","color":"0052cc","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":13,"created_at":"2018-01-29T00:07:32Z","updated_at":"2018-07-13T08:06:55Z","closed_at":null,"author_association":"NONE","body":"I have been working on a project, which I [extracted into a standalone repo](https://github.com/kigster/arduino-cmake-oversized-image).  It's based of the `arduino-cmake` repo and follows the same structure.\r\n\r\nInside is the `NeoCube.cpp` — a piece of logic controlling NeoPixels using the `WS2812FX` effects library.  The library does mention that it's big, and even has a `#define` that says:\r\n\r\n```c++\r\n#define REDUCED_MODES 1 // sketch is too big for Arduino w/32k flash, so invoke reduced modes\r\n```\r\n\r\nRegardless, when this sketch is compiled using Arduino IDE, the image size ends up being about 80% of the maximum 32Kb. Here is the last few lines of Arduino IDE compile log showing the size of the image:\r\n\r\n```bash\r\nCompiling library \"Adafruit_NeoPixel\"\r\nUsing previously compiled file: /var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/libraries/Adafruit_NeoPixel/esp8266.c.o\r\nUsing previously compiled file: /var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/libraries/Adafruit_NeoPixel/Adafruit_NeoPixel.cpp.o\r\nCompiling core...\r\nUsing precompiled core\r\nLinking everything together...\r\n\"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-gcc\" -w -Os -g -flto -fuse-linker-plugin -Wl,--gc-sections -mmcu=atmega328p  -o \"/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/NeoCircle.ino.elf\" \"/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/sketch/NeoCircle.ino.cpp.o\" \"/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/sketch/WS2812FX.cpp.o\" \"/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/libraries/Adafruit_NeoPixel/esp8266.c.o\" \"/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/libraries/Adafruit_NeoPixel/Adafruit_NeoPixel.cpp.o\" \"/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/../arduino_cache_345435/core/core_arduino_avr_pro_cpu_16MHzatmega328_51f02b7210b938436b779d1c032618e1.a\" \"-L/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156\" -lm\r\n\"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-objcopy\" -O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0  \"/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/NeoCircle.ino.elf\" \"/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/NeoCircle.ino.eep\"\r\n\"/Applications/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-objcopy\" -O ihex -R .eeprom  \"/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/NeoCircle.ino.elf\" \"/var/folders/tn/x23sslwx27q12kq5npk70qs80000gn/T/arduino_build_171156/NeoCircle.ino.hex\"\r\nUsing library Adafruit_NeoPixel at version 1.1.5 in folder: /Users/kig/workspace/oss/arduino/sketches/libraries/Adafruit_NeoPixel \r\nSketch uses 26524 bytes (86%) of program storage space. Maximum is 30720 bytes.\r\nGlobal variables use 918 bytes (44%) of dynamic memory, leaving 1130 bytes for local variables. Maximum is 2048 bytes.\r\n```\r\n\r\nHowever, when compiled using `arduino-cmake`, the image suddently grows to 124% of the available RAM\r\n\r\n```\r\n ↪   ~/workspace/oss/arduino/sketches/NeoCube-AC/build     cmake ..\r\n-- ARDUINO Boards:\r\n--                   menu:\r\n--                    yun: Arduino Y\r\n--                    uno: Arduino/Genuino Uno\r\n--              diecimila: Arduino Duemilanove or Diecimila\r\n--                   nano: Arduino Nano\r\n--                   mega: Arduino/Genuino Mega or Mega 2560\r\n--                megaADK: Arduino Mega ADK\r\n--               leonardo: Arduino Leonardo\r\n--            leonardoeth: Arduino Leonardo ETH\r\n--                  micro: Arduino/Genuino Micro\r\n--                esplora: Arduino Esplora\r\n--                   mini: Arduino Mini\r\n--               ethernet: Arduino Ethernet\r\n--                    fio: Arduino Fio\r\n--                     bt: Arduino BT\r\n--             LilyPadUSB: LilyPad Arduino USB\r\n--                lilypad: LilyPad Arduino\r\n--                    pro: Arduino Pro or Pro Mini\r\n--               atmegang: Arduino NG or older\r\n--           robotControl: Arduino Robot Control\r\n--             robotMotor: Arduino Robot Motor\r\n--                  gemma: Arduino Gemma\r\n--     circuitplay32u4cat: Adafruit Circuit Playground\r\n--                yunmini: Arduino Y\r\n--                chiwawa: Arduino Industrial 101\r\n--                    one: Linino One\r\n--                unowifi: Arduino Uno WiFi\r\n--\r\n-- ARDUINO Programmers:\r\n--            avrisp: AVR ISP\r\n--        avrispmkii: AVRISP mkII\r\n--        usbtinyisp: USBtinyISP\r\n--        arduinoisp: ArduinoISP\r\n--     arduinoisporg: ArduinoISP.org\r\n--            usbasp: USBasp\r\n--          parallel: Parallel Programmer\r\n--      arduinoasisp: Arduino as ISP\r\n--          usbGemma: Arduino Gemma\r\n--         buspirate: BusPirate as ISP\r\n--            stk500: Atmel STK500 development board\r\n--          jtag3isp: Atmel JTAGICE3 (ISP mode)\r\n--             jtag3: Atmel JTAGICE3 (JTAG mode)\r\n--         atmel_ice: Atmel-ICE (AVR)\r\n--\r\n-- Generating WS2812FX\r\n-- Generating Adafruit_NeoPixel\r\n-- Generating NeoCube\r\n-- Configuring done\r\n-- Generating done\r\n-- Build files have been written to: /Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/build\r\n± kig @ kiggie-pro (master U:8 ?:2 ✗) 2.5.0  ✔︎                                                ⏰  15:52:40\r\n  ↪   ~/workspace/oss/arduino/sketches/NeoCube-AC/build     make\r\n[  2%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/CDC.cpp.obj\r\n[  5%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/HardwareSerial.cpp.obj\r\n[  8%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/HardwareSerial0.cpp.obj\r\n[ 10%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/HardwareSerial1.cpp.obj\r\n[ 13%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/HardwareSerial2.cpp.obj\r\n[ 16%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/HardwareSerial3.cpp.obj\r\n[ 18%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/IPAddress.cpp.obj\r\n[ 21%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/PluggableUSB.cpp.obj\r\n[ 24%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/Print.cpp.obj\r\n[ 27%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/Stream.cpp.obj\r\n[ 29%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/Tone.cpp.obj\r\n[ 32%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/USBCore.cpp.obj\r\n[ 35%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/WMath.cpp.obj\r\n[ 37%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/WString.cpp.obj\r\n[ 40%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/abi.cpp.obj\r\n[ 43%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/main.cpp.obj\r\n[ 45%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/new.cpp.obj\r\n[ 48%] Building C object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/WInterrupts.c.obj\r\n[ 51%] Building C object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/hooks.c.obj\r\n[ 54%] Building C object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/wiring.c.obj\r\n[ 56%] Building C object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/wiring_analog.c.obj\r\n[ 59%] Building C object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/wiring_digital.c.obj\r\n[ 62%] Building C object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/wiring_pulse.c.obj\r\n[ 64%] Building C object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/wiring_shift.c.obj\r\n[ 67%] Building ASM object src/CMakeFiles/pro.16MHzatmega328_CORE.dir/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/wiring_pulse.S.obj\r\n[ 70%] Linking CXX static library libpro.16MHzatmega328_CORE.a\r\n[ 70%] Built target pro.16MHzatmega328_CORE\r\n[ 72%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_Adafruit_NeoPixel.dir/libraries/Adafruit_NeoPixel/Adafruit_NeoPixel.cpp.obj\r\n[ 75%] Building C object src/CMakeFiles/pro.16MHzatmega328_Adafruit_NeoPixel.dir/libraries/Adafruit_NeoPixel/esp8266.c.obj\r\n[ 78%] Linking CXX static library libpro.16MHzatmega328_Adafruit_NeoPixel.a\r\n[ 78%] Built target pro.16MHzatmega328_Adafruit_NeoPixel\r\n[ 81%] Building CXX object src/CMakeFiles/pro.16MHzatmega328_WS2812FX.dir/libraries/WS2812FX/WS2812FX.cpp.obj\r\nIn file included from /Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.cpp:54:0:\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:424:30: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11\r\n     uint8_t _segment_index = 0;\r\n                              ^\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:425:29: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11\r\n     uint8_t _num_segments = 1;\r\n                             ^\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:429:5: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11\r\n     };\r\n     ^\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:429:5: warning: extended initializer lists only available with -std=c++11 or -std=gnu++11\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.cpp: In member function 'void WS2812FX::resetSegments()':\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.cpp:257:39: warning: extended initializer lists only available with -std=c++11 or -std=gnu++11\r\n   setSegment(0, 0, 7, FX_MODE_STATIC, {DEFAULT_COLOR}, DEFAULT_SPEED, false);\r\n                                       ^\r\n[ 83%] Linking CXX static library libpro.16MHzatmega328_WS2812FX.a\r\n[ 83%] Built target pro.16MHzatmega328_WS2812FX\r\n[ 86%] Building CXX object src/CMakeFiles/Adafruit_NeoPixel.dir/libraries/Adafruit_NeoPixel/Adafruit_NeoPixel.cpp.obj\r\n[ 89%] Linking CXX static library libAdafruit_NeoPixel.a\r\n[ 89%] Built target Adafruit_NeoPixel\r\n[ 91%] Building CXX object src/CMakeFiles/WS2812FX.dir/libraries/WS2812FX/WS2812FX.cpp.obj\r\nIn file included from /Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.cpp:54:0:\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:424:30: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11\r\n     uint8_t _segment_index = 0;\r\n                              ^\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:425:29: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11\r\n     uint8_t _num_segments = 1;\r\n                             ^\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:429:5: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11\r\n     };\r\n     ^\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:429:5: warning: extended initializer lists only available with -std=c++11 or -std=gnu++11\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.cpp: In member function 'void WS2812FX::resetSegments()':\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.cpp:257:39: warning: extended initializer lists only available with -std=c++11 or -std=gnu++11\r\n   setSegment(0, 0, 7, FX_MODE_STATIC, {DEFAULT_COLOR}, DEFAULT_SPEED, false);\r\n                                       ^\r\n[ 94%] Linking CXX static library libWS2812FX.a\r\n[ 94%] Built target WS2812FX\r\nScanning dependencies of target NeoCube\r\n[ 97%] Building CXX object src/CMakeFiles/NeoCube.dir/NeoCube.cpp.obj\r\nIn file included from /Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/NeoCube.cpp:3:0:\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:424:30: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11\r\n     uint8_t _segment_index = 0;\r\n                              ^\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:425:29: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11\r\n     uint8_t _num_segments = 1;\r\n                             ^\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:429:5: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11\r\n     };\r\n     ^\r\n/Users/kig/workspace/oss/arduino/sketches/NeoCube-AC/src/libraries/WS2812FX/WS2812FX.h:429:5: warning: extended initializer lists only available with -std=c++11 or -std=gnu++11\r\n[100%] Linking CXX executable NeoCube.elf\r\nGenerating EEP image\r\nGenerating HEX image\r\nCalculating image size\r\nFirmware Size:  [Program: 40788 bytes (124.5%) ]  [Data: 980 bytes (47.9%) ] on atmega328p\r\nEEPROM Size:  [Program: 0 bytes (0.0%) ]  [Data: 0 bytes (0.0%) ] on atmega328p\r\n\r\n```\r\n\r\nThis prevents me from using Arduino-CMake for this project, but I wonder what else does this affect?\r\n\r\nThanks so much!\r\n"},"comment":{"url":"https://api.github.com/repos/arduino-cmake/arduino-cmake/issues/comments/404759433","html_url":"https://github.com/arduino-cmake/arduino-cmake/issues/67#issuecomment-404759433","issue_url":"https://api.github.com/repos/arduino-cmake/arduino-cmake/issues/67","id":404759433,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNDc1OTQzMw==","user":{"login":"MrPointer","id":10564482,"node_id":"MDQ6VXNlcjEwNTY0NDgy","avatar_url":"https://avatars1.githubusercontent.com/u/10564482?v=4","gravatar_id":"","url":"https://api.github.com/users/MrPointer","html_url":"https://github.com/MrPointer","followers_url":"https://api.github.com/users/MrPointer/followers","following_url":"https://api.github.com/users/MrPointer/following{/other_user}","gists_url":"https://api.github.com/users/MrPointer/gists{/gist_id}","starred_url":"https://api.github.com/users/MrPointer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MrPointer/subscriptions","organizations_url":"https://api.github.com/users/MrPointer/orgs","repos_url":"https://api.github.com/users/MrPointer/repos","events_url":"https://api.github.com/users/MrPointer/events{/privacy}","received_events_url":"https://api.github.com/users/MrPointer/received_events","type":"User","site_admin":false},"created_at":"2018-07-13T08:06:54Z","updated_at":"2018-07-13T08:06:54Z","author_association":"NONE","body":"@kigster @lanouettea \r\nActually the new version is yet to be hosted on GitHub, and moreover - **It will reside under a new repository**. Why am I doing this? A few reasons:\r\n1. There are way too many forks out there for this project, people are easily lost between them, so there's no need for another one.\r\n2. In fact, the new project is not even a fork of an older one - It's a **complete fresh start**. \r\nThis is because the older project (This one), as good as it got, is still a mess, and, more importantly, doesn't have the ability to address several critical issues that users complained about during the course of time due to its' core architecture.\r\n3. It's time to move on and upgrade yourself. \r\nThis projects guarantees to support Arduino **0.19!!!** This is insane! Nobody uses such old versions, and I'm really skeptical anyone uses a version older than 1.6, which came out in 2016.\r\nBesides, the project also guarantees to support CMake 2.8, which is also very old and doesn't support many good features added by later version of CMake. So requiring a minimum of CMake 3.8, when even the apt package manager offers later versions, is totally fine.\r\n\r\nAs to your questions - Yes, I'd be happy to have you on-board and help me with some beta testings! 😄 \r\nI will PM each of you when I'll have a functioning enough version."}}
{"actor":{"display_login":"MrPointer"}}