1 From 1d7b7046c8f735e150e92aeace3fe6d0686b9bc9 Mon Sep 17 00:00:00 2001
2 From: Gary Bisson <gary.bisson@boundarydevices.com>
3 Date: Wed, 3 Oct 2018 10:52:29 +0200
4 Subject: [PATCH] Fix version.h inclusion to be from kernel build folder
6 Instead of relying on Toolchain headers which can be from newer kernel.
8 Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com>
12 2 files changed, 6 insertions(+)
14 diff --git a/Makefile_G1G2 b/Makefile_G1G2
15 index 29866a4..c473bcb 100755
18 @@ -16,6 +16,9 @@ INCLUDE_HEADERS += -I$(LINUX_KERNEL_ROOT)/include/uapi -I$(LINUX_KERNEL_ROOT)/in
20 INCLUDE_HEADERS += -I$(LINUX_KERNEL_ROOT)/drivers/staging/android/uapi
22 +# LINUX_VERSION_CODE from kernel build folder instead of toolchain headers
23 +INCLUDE_HEADERS += -I$(LINUX_KERNEL_BUILD)/include/generated/uapi
25 CFLAGS += -DDEC_MODULE_PATH=\"/dev/mxc_hantro\" -DUSE_FAKE_RFC_TABLE -DFIFO_DATATYPE=void* -DNDEBUG -DDOWN_SCALER \
26 -DUSE_EXTERNAL_BUFFER -DUSE_FAST_EC -DUSE_VP9_EC -DGET_FREE_BUFFER_NON_BLOCK \
27 -DDEC_X170_OUTPUT_FORMAT=0 -DDEC_X170_TIMEOUT_LENGTH=-1 -DENABLE_HEVC_SUPPORT \
28 diff --git a/Makefile_H1 b/Makefile_H1
29 index 56b4332..0be43ce 100755
32 @@ -23,6 +23,9 @@ ENV += -I$(SDKTARGETSYSROOT)/usr/imx/include
34 ENV += -I$(LINUX_KERNEL_ROOT)/drivers/staging/android/uapi
36 +# LINUX_VERSION_CODE from kernel build folder instead of toolchain headers
37 +INCLUDE_HEADERS += -I$(LINUX_KERNEL_BUILD)/include/generated/uapi
39 LIBENCNAME = libcodec_enc
40 LIBSENC = -L./ -lhantro_h1 -lpthread