sys: printk: Fix LOG2 printk support in cpp code
sys: printk: Fix LOG2 printk support in cpp code

This commit fixes the issue with a compilation of the sample that
uses printk function from cpp code when LOG2 is used and printk
is handled by logging subsystem.

Signed-off-by: Radoslaw Koppel <c53bdb246a28d48215f045abdb12a236ca111a4d@nordicsemi.no>

zephyrproject-rtos/zephyr,zephyrproject-rtos/zephyr,galak/zephyr,galak/zephyr,galak/zephyr,galak/zephyr,finikorg/zephyr,galak/zephyr,finikorg/zephyr,zephyrproject-rtos/zephyr,zephyrproject-rtos/zephyr,finikorg/zephyr,zephyrproject-rtos/zephyr,finikorg/zephyr,finikorg/zephyr