Emulate std::to_string on platforms that do not provide it

Inspired by NFD commit ce81230b09583f9aec98a97653a047aa54fa2bef

This commit also fixes an important typo in the name of the macro
defined by the check_vector_const_iterators configure check.

Change-Id: I1b18066474145720570b5ecd6109b3f76eb262e8
Refs: #2743
diff --git a/src/name-component.cpp b/src/name-component.cpp
index 9226eb4..ac0f5f1 100644
--- a/src/name-component.cpp
+++ b/src/name-component.cpp
@@ -366,7 +366,7 @@
 {
   if (digest->size() != crypto::SHA256_DIGEST_SIZE)
     BOOST_THROW_EXCEPTION(Error("Cannot create ImplicitSha256DigestComponent (input digest must be " +
-                                std::to_string(crypto::SHA256_DIGEST_SIZE) + " octets)"));
+                                to_string(crypto::SHA256_DIGEST_SIZE) + " octets)"));
 
   return Block(tlv::ImplicitSha256DigestComponent, digest);
 }
@@ -375,8 +375,8 @@
 Component::fromImplicitSha256Digest(const uint8_t* digest, size_t digestSize)
 {
   if (digestSize != crypto::SHA256_DIGEST_SIZE)
-    BOOST_THROW_EXCEPTION(Error("Cannot create ImplicitSha256DigestComponent (input digest must be "
-                                + std::to_string(crypto::SHA256_DIGEST_SIZE) + " octets)"));
+    BOOST_THROW_EXCEPTION(Error("Cannot create ImplicitSha256DigestComponent (input digest must be " +
+                                to_string(crypto::SHA256_DIGEST_SIZE) + " octets)"));
 
   return makeBinaryBlock(tlv::ImplicitSha256DigestComponent, digest, digestSize);
 }