{"action":"closed","issue":{"url":"https://api.github.com/repos/esp8266/Arduino/issues/131","labels_url":"https://api.github.com/repos/esp8266/Arduino/issues/131/labels{/name}","comments_url":"https://api.github.com/repos/esp8266/Arduino/issues/131/comments","events_url":"https://api.github.com/repos/esp8266/Arduino/issues/131/events","html_url":"https://github.com/esp8266/Arduino/issues/131","id":71313559,"number":131,"title":"\"Error compiling.\" while trying to use ArduinoJson lib","user":{"login":"thereforeiam","id":11975722,"avatar_url":"https://avatars.githubusercontent.com/u/11975722?v=3","gravatar_id":"","url":"https://api.github.com/users/thereforeiam","html_url":"https://github.com/thereforeiam","followers_url":"https://api.github.com/users/thereforeiam/followers","following_url":"https://api.github.com/users/thereforeiam/following{/other_user}","gists_url":"https://api.github.com/users/thereforeiam/gists{/gist_id}","starred_url":"https://api.github.com/users/thereforeiam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thereforeiam/subscriptions","organizations_url":"https://api.github.com/users/thereforeiam/orgs","repos_url":"https://api.github.com/users/thereforeiam/repos","events_url":"https://api.github.com/users/thereforeiam/events{/privacy}","received_events_url":"https://api.github.com/users/thereforeiam/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/esp8266/Arduino/labels/staged-for-release","name":"staged-for-release","color":"5319e7"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-04-27T15:14:43Z","updated_at":"2015-05-19T06:51:45Z","closed_at":"2015-05-19T06:51:45Z","body":"I'm trying to use [ArduinoJson] (https://github.com/bblanchon/ArduinoJson) with ESP8266 which seems like a good match :)\r\nHowever when trying to compile a simple example : \r\n\r\n```c\r\n// Copyright Benoit Blanchon 2014\r\n// MIT License\r\n//\r\n// Arduino JSON library\r\n// https://github.com/bblanchon/ArduinoJson\r\n\r\n#include <ArduinoJson.h>\r\n\r\nvoid setup() {\r\n  Serial.begin(9600);\r\n\r\n  StaticJsonBuffer<200> jsonBuffer;\r\n\r\n  char json[] =\r\n      \"{\\\"sensor\\\":\\\"gps\\\",\\\"time\\\":1351824120,\\\"data\\\":[48.756080,2.302038]}\";\r\n\r\n  JsonObject& root = jsonBuffer.parseObject(json);\r\n\r\n  if (!root.success()) {\r\n    Serial.println(\"parseObject() failed\");\r\n    return;\r\n  }\r\n\r\n  const char* sensor = root[\"sensor\"];\r\n  long time = root[\"time\"];\r\n  double latitude = root[\"data\"][0];\r\n  double longitude = root[\"data\"][1];\r\n\r\n  Serial.println(sensor);\r\n  Serial.println(time);\r\n  Serial.println(latitude, 6);\r\n  Serial.println(longitude, 6);\r\n}\r\n\r\nvoid loop() {\r\n  // not used in this example\r\n}\r\n```\r\n\r\nI get the following error message : \r\n```\r\n~/Downloads/Arduino-2.app/Contents/Java/hardware/tools/esp8266/xtensa-lx106-elf/bin/xtensa-lx106-elf-gcc -nostdlib -Wl,--no-check-sections -u call_user_start -Wl,-static -L~/Downloads/Arduino-2.app/Contents/Java/hardware/tools/esp8266/sdk//lib -L~/Downloads/Arduino-2.app/Contents/Java/hardware/tools/esp8266/sdk//ld -Teagle.app.v6.ld -o /var/folders/lb/xjmz955x16jgq0sd2f88wkzc0000gn/T/build2078761220582383494.tmp/JsonParserExample.cpp.elf -Wl,--start-group /var/folders/lb/xjmz955x16jgq0sd2f88wkzc0000gn/T/build2078761220582383494.tmp/JsonParserExample.cpp.o /var/folders/lb/xjmz955x16jgq0sd2f88wkzc0000gn/T/build2078761220582383494.tmp/ArduinoJson/ArduinoJson.cpp.o /var/folders/lb/xjmz955x16jgq0sd2f88wkzc0000gn/T/build2078761220582383494.tmp/core.a -lc -lgcc -lhal -lphy -lnet80211 -llwip -lwpa -lmain -lpp -Wl,--end-group -L/var/folders/lb/xjmz955x16jgq0sd2f88wkzc0000gn/T/build2078761220582383494.tmp \r\n~/Downloads/Arduino-2.app/Contents/Java/hardware/tools/esp8266/xtensa-lx106-elf/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/bin/ld: /var/folders/lb/xjmz955x16jgq0sd2f88wkzc0000gn/T/build2078761220582383494.tmp/JsonParserExample.cpp.elf section `.text' will not fit in region `iram1_0_seg'\r\n~/Downloads/Arduino-2.app/Contents/Java/hardware/tools/esp8266/xtensa-lx106-elf/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib/libc.a(lib_a-mallocr.o):(.literal+0x1c): undefined reference to `_sbrk_r'\r\n~/Downloads/Arduino-2.app/Contents/Java/hardware/tools/esp8266/xtensa-lx106-elf/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib/libc.a(lib_a-mallocr.o): In function `malloc_extend_top':\r\nmallocr.c:(.text+0x5e): undefined reference to `_sbrk_r'\r\nmallocr.c:(.text+0x127): undefined reference to `_sbrk_r'\r\n~/Downloads/Arduino-2.app/Contents/Java/hardware/tools/esp8266/xtensa-lx106-elf/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib/libc.a(lib_a-freer.o): In function `_malloc_trim_r':\r\nmallocr.c:(.text+0x366): undefined reference to `_sbrk_r'\r\nmallocr.c:(.text+0x38f): undefined reference to `_sbrk_r'\r\n~/Downloads/Arduino-2.app/Contents/Java/hardware/tools/esp8266/xtensa-lx106-elf/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib/libc.a(lib_a-freer.o):mallocr.c:(.text+0x3a0): more undefined references to `_sbrk_r' follow\r\ncollect2: error: ld returned 1 exit status\r\nError compiling.\r\n```\r\nI'm using 1.6.1 release."}}