soc: intel_s1000: add dummy atexit() for Clang++
Add a dummy atexit() function when compiling C++ source files using Clang++. Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This commit is contained in:
parent
ac4ebe4ffb
commit
60db257e69
2 changed files with 17 additions and 0 deletions
|
@ -1,3 +1,4 @@
|
|||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
zephyr_library_sources_ifdef(CONFIG_CPLUSPLUS cpp_fixes.c)
|
||||
zephyr_library_sources_ifdef(CONFIG_NEWLIB_LIBC newlib_fixes.c)
|
||||
|
|
16
soc/xtensa/intel_s1000/xcc/cpp_fixes.c
Normal file
16
soc/xtensa/intel_s1000/xcc/cpp_fixes.c
Normal file
|
@ -0,0 +1,16 @@
|
|||
/*
|
||||
* Copyright (c) 2019, Intel Corporation.
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#ifdef __clang__
|
||||
|
||||
int atexit(void (*function)(void))
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
#endif /* __clang__ */
|
Loading…
Add table
Add a link
Reference in a new issue