mirror of
https://github.com/bytecodealliance/wasm-micro-runtime.git
synced 2024-11-26 15:32:05 +00:00
Corrects Zephyr include files for current versions of Zephyr (#2881)
This fixes bug #2880. Zephyr 3.2 made changes to how headers are reference (see [release notes](https://docs.zephyrproject.org/latest/releases/release-notes-3.2.html)). Work item [49578](https://github.com/zephyrproject-rtos/zephyr/issues/49578) deprecated the old headers names. The current WAMR codebase references these old headers, thus causing compile errors with current versions of Zephyr. This update adds #ifdefs around the header names. With this change, compiling with Zephyr 3.2.0 and above will use the new header files. Prior versions will use the existing code.
This commit is contained in:
parent
a58e596995
commit
df83aef101
|
@ -6,8 +6,14 @@
|
|||
#include "app_manager.h"
|
||||
#include "bh_platform.h"
|
||||
#include <autoconf.h>
|
||||
|
||||
#if KERNEL_VERSION_NUMBER < 0x030200 /* version 3.2.0 */
|
||||
#include <zephyr.h>
|
||||
#include <kernel.h>
|
||||
#else
|
||||
#include <zephyr/kernel.h>
|
||||
#endif
|
||||
|
||||
#if 0
|
||||
#include <sigverify.h>
|
||||
#endif
|
||||
|
|
|
@ -10,8 +10,12 @@
|
|||
#include <string.h>
|
||||
#include "drivers/spi.h"
|
||||
|
||||
#include "zephyr.h"
|
||||
#include "kernel.h"
|
||||
#if KERNEL_VERSION_NUMBER < 0x030200 /* version 3.2.0 */
|
||||
#include <zephyr.h>
|
||||
#include <kernel.h>
|
||||
#else
|
||||
#include <zephyr/kernel.h>
|
||||
#endif
|
||||
|
||||
#if USE_XPT2046
|
||||
|
||||
|
|
|
@ -7,7 +7,12 @@
|
|||
#define ZEPHYR_DRIVERS_DISPLAY_DISPLAY_ILI9340_H_
|
||||
#include "board_config.h"
|
||||
#include <autoconf.h>
|
||||
|
||||
#if KERNEL_VERSION_NUMBER < 0x030200 /* version 3.2.0 */
|
||||
#include <zephyr.h>
|
||||
#else
|
||||
#include <zephyr/kernel.h>
|
||||
#endif
|
||||
|
||||
#define ILI9340_CMD_ENTER_SLEEP 0x10
|
||||
#define ILI9340_CMD_EXIT_SLEEP 0x11
|
||||
|
|
|
@ -31,7 +31,12 @@ xpt2046_init(void);
|
|||
extern void
|
||||
wgl_init();
|
||||
|
||||
#if KERNEL_VERSION_NUMBER < 0x030200 /* version 3.2.0 */
|
||||
#include <zephyr.h>
|
||||
#else
|
||||
#include <zephyr/kernel.h>
|
||||
#endif
|
||||
|
||||
#include <drivers/uart.h>
|
||||
#include <device.h>
|
||||
|
||||
|
|
|
@ -10,8 +10,12 @@
|
|||
#include <string.h>
|
||||
#include "drivers/spi.h"
|
||||
|
||||
#include "zephyr.h"
|
||||
#include "kernel.h"
|
||||
#if KERNEL_VERSION_NUMBER < 0x030200 /* version 3.2.0 */
|
||||
#include <zephyr.h>
|
||||
#include <kernel.h>
|
||||
#else
|
||||
#include <zephyr/kernel.h>
|
||||
#endif
|
||||
|
||||
#if USE_XPT2046
|
||||
|
||||
|
|
|
@ -7,7 +7,12 @@
|
|||
#define ZEPHYR_DRIVERS_DISPLAY_DISPLAY_ILI9340_H_
|
||||
#include "board_config.h"
|
||||
#include <autoconf.h>
|
||||
|
||||
#if KERNEL_VERSION_NUMBER < 0x030200 /* version 3.2.0 */
|
||||
#include <zephyr.h>
|
||||
#else
|
||||
#include <zephyr/kernel.h>
|
||||
#endif
|
||||
|
||||
#define ILI9340_CMD_ENTER_SLEEP 0x10
|
||||
#define ILI9340_CMD_EXIT_SLEEP 0x11
|
||||
|
|
|
@ -16,7 +16,12 @@
|
|||
#include "connection_native_api.h"
|
||||
#include "display_indev.h"
|
||||
|
||||
#if KERNEL_VERSION_NUMBER < 0x030200 /* version 3.2.0 */
|
||||
#include <zephyr.h>
|
||||
#else
|
||||
#include <zephyr/kernel.h>
|
||||
#endif
|
||||
|
||||
#include <drivers/uart.h>
|
||||
#include <device.h>
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user