CCG3 firmware example code cannot build with PSoC Creator 4.2. Since CCG3 firmware have included pre-build library which is built under PSoC Creator 3.3 DP1's GCC compiler and MDK compiler. Which is not same as PSoC Creator 4.2. You can install CCGx SDK on your computer. The installer will install PSoC Creator 3.3 DP1 for you.