mirror of
https://git.intern.spaceteamaachen.de/ALPAKA/sta-core.git
synced 2025-06-10 16:55:58 +00:00
Add printf implementation switch
This commit is contained in:
parent
f940dd9710
commit
46ff94e64d
22
include/sta/printf.hpp
Normal file
22
include/sta/printf.hpp
Normal file
@ -0,0 +1,22 @@
|
||||
/**
|
||||
* @brief Compatibility layer for different `printf` implementations.
|
||||
*/
|
||||
#ifndef STA_PRINTF_HPP
|
||||
#define STA_PRINTF_HPP
|
||||
|
||||
#include <sta/config.hpp>
|
||||
|
||||
#if !defined(STA_PRINTF_USE_STDLIB) && !defined(STA_PRINTF_USE_MPALAND)
|
||||
# error "No printf implementation chosen!"
|
||||
#endif // !STA_PRINTF_USE_STDLIB && !STA_PRINTF_USE_MPALAND
|
||||
|
||||
|
||||
#ifdef STA_PRINTF_USE_STDLIB
|
||||
# include <cstdio>
|
||||
#endif // STA_PRINTF_USE_STDLIB
|
||||
#ifdef STA_PRINTF_USE_MPALAND
|
||||
# include <printf.h>
|
||||
#endif // STA_PRINTF_USE_MPALAND
|
||||
|
||||
|
||||
#endif // STA_PRINTF_HPP
|
Loading…
x
Reference in New Issue
Block a user