Avoid unused CMake variable warnings when building examples.

Change-Id: Ic613f25cc770a90dd2f2dd4a230883f6ff2a759e
Merge topic 'disable_unused_vars_warnings' into next

0f18d072 Avoid unused CMake variable warnings when building examples.