build-unit-test-docker: Add fmtlib

An open-source formatting library for C++. It can be used as a
safe and fast alternative to (s)printf and iostreams.

This will be used by future projects in openbmc

Change-Id: Icacfbf7a41836c6c90581240a65266eaa4249e9a
Signed-off-by: William A. Kennington III <wak@google.com>
diff --git a/build-unit-test-docker.sh b/build-unit-test-docker.sh
index d698d3e..a76f8dd 100755
--- a/build-unit-test-docker.sh
+++ b/build-unit-test-docker.sh
@@ -92,6 +92,7 @@
   [boost]=1.69.0
   [cereal]=v1.2.2
   [CLI11]=v1.7.1
+  [fmt]=5.3.0
   # Snapshot from 2019-03-10
   [function2]=e3695b4b4fa3c672e25c6462d7900f8d2417a417
   # Snapshot from 2018-12-17
@@ -263,6 +264,15 @@
 make -j$(nproc) && \
 make install
 
+FROM openbmc-base as openbmc-fmt
+RUN curl -L https://github.com/fmtlib/fmt/archive/${PKG_REV['fmt']}.tar.gz | tar -xz && \
+cd fmt-* && \
+mkdir build && \
+cd build && \
+cmake ${CMAKE_FLAGS[@]} -DFMT_DOC=OFF -DFMT_TEST=OFF .. && \
+make -j$(nproc) && \
+make install
+
 FROM openbmc-base as openbmc-json
 RUN mkdir ${PREFIX}/include/nlohmann/ && \
 curl -L -o ${PREFIX}/include/nlohmann/json.hpp https://github.com/nlohmann/json/releases/download/${PKG_REV['json']}/json.hpp