I opened the relevant CMakeLists.txt and inserted this line near the beginning:
SET(CMAKE_CXX_COMPILER "/usr/bin/gcc")