Hey everyone,
I’m trying to impliment httpClient classes for Spark core and I seem to be getting errors that I just don’t know how to fix. These are the errors.
In file included from …/inc/spark_wiring.h:30:0,
from …/inc/spark_wiring_tcpclient.h:29,
from HttpClient.h:5,
from HttpClient.cpp:1:
…/…/core-common-lib/SPARK_Firmware_Driver/inc/config.h:12:2: warning: #warning “Defaulting to Release Build” [-Wcpp]
In file included from …/inc/spark_wiring.h:30:0,
from …/inc/application.h:31,
from helio_functions.h:3,
from helio_functions.cpp:1:
…/…/core-common-lib/SPARK_Firmware_Driver/inc/config.h:12:2: warning: #warning “Defaulting to Release Build” [-Wcpp]
In file included from …/inc/spark_wiring.h:30:0,
from …/inc/application.h:31,
from helio_weather.cpp:2:
…/…/core-common-lib/SPARK_Firmware_Driver/inc/config.h:12:2: warning: #warning “Defaulting to Release Build” [-Wcpp]
jsmn.cpp: In function ‘jsmntok_t* jsmn_alloc_token(jsmn_parser*, jsmntok_t*, size_t)’:
jsmn.cpp:11:25: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
In file included from …/inc/spark_wiring.h:30:0,
from …/inc/spark_wiring_tcpclient.h:29,
from HttpClient.h:5,
from openweathermap.h:10,
from openweathermap.cpp:1:
…/…/core-common-lib/SPARK_Firmware_Driver/inc/config.h:12:2: warning: #warning “Defaulting to Release Build” [-Wcpp]
HttpClient.o: In function HttpClient::request(http_request_t&, http_response_t&, http_header_t*, char const*)': /spark/compile_server/shared/workspace/worker_1/core-firmware/build/HttpClient.cpp:257: undefined reference to
String::operator=(String&&)'
openweathermap.o: In function weather_response_t': /spark/compile_server/shared/workspace/worker_1/core-firmware/build/openweathermap.h:13: undefined reference to
String::String(String&&)'
openweathermap.o: In function operator=': /spark/compile_server/shared/workspace/worker_1/core-firmware/build/openweathermap.h:13: undefined reference to
String::operator=(String&&)'
collect2: error: ld returned 1 exit status
make: *** [5441239b133a7097ee2f6244f0921d70626f04fa965833cbfe52996499e7.elf] Error 1
It tells me on line 257 of HttpClient there is a unrefined reference, but I checked and the code seems fine to me. It would be great if someone could help me in the right direction. Here is were I received the HttpClient class code.
Thank you!