CPP be the C Pre-Processor - the program reading your code and replacing header includes with their content and macros with their values
CC the C Compiler - the program understanding the C language, taking a .c source code file and generating a .o object file out of it
CXX the C++ Compiler - the program understanding the C++ language, taking a .cc/.cpp source code file and generating a .o object file out of it
LD the linker - the program taking multiple .o files and libraries .so/.a (e.g. libboost) and generating an executable ELF file out of it - the final binary
then for passing in flags
CFLAGS compilation flags for the C compiler, think -Wall -Wextra -pedantic -O2 -std=c99 to enable warnings, optimize the code and work with C99 source code
CXXFLAGS same for C++, -Wall -Wextra -pedantic -O2 -std=c++14
LDFLAGS linker flags, for more advanced linker tuning
Build systems such as Make, CMake and Gyp (what we use here) pick up these environment variables and use them for compiling and linking your code. If you leave them blank it depends on the build system and your setup what you will get.