From b59b799cb1ec5126ad3428e264bc349132adbaeb Mon Sep 17 00:00:00 2001 From: Yousong Zhou Date: Thu, 30 Nov 2017 14:52:30 +0800 Subject: ltq-ifxos: fix compilation against glibc Fixes FS#1196 Signed-off-by: Yousong Zhou --- package/kernel/lantiq/ltq-ifxos/Makefile | 4 +- ...pilation-failure-from-inclusion-of-wrong-.patch | 59 ++++++++++++++++++++++ 2 files changed, 60 insertions(+), 3 deletions(-) create mode 100644 package/kernel/lantiq/ltq-ifxos/patches/200-Fix-app-compilation-failure-from-inclusion-of-wrong-.patch (limited to 'package/kernel') diff --git a/package/kernel/lantiq/ltq-ifxos/Makefile b/package/kernel/lantiq/ltq-ifxos/Makefile index 05663de2c4..a0891be3e0 100644 --- a/package/kernel/lantiq/ltq-ifxos/Makefile +++ b/package/kernel/lantiq/ltq-ifxos/Makefile @@ -8,7 +8,7 @@ include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=lib_ifxos PKG_VERSION:=1.5.19 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) PKG_SOURCE_URL:=https://github.com/xdarklight/$(PKG_NAME)/archive/v$(PKG_VERSION) @@ -34,8 +34,6 @@ define KernelPackage/ltq-ifxos AUTOLOAD:=$(call AutoLoad,10,drv_ifxos) endef -MAKE_FLAGS+=-s - CONFIGURE_ARGS += \ ARCH=$(LINUX_KARCH) \ --enable-linux-26 \ diff --git a/package/kernel/lantiq/ltq-ifxos/patches/200-Fix-app-compilation-failure-from-inclusion-of-wrong-.patch b/package/kernel/lantiq/ltq-ifxos/patches/200-Fix-app-compilation-failure-from-inclusion-of-wrong-.patch new file mode 100644 index 0000000000..dee3482e4f --- /dev/null +++ b/package/kernel/lantiq/ltq-ifxos/patches/200-Fix-app-compilation-failure-from-inclusion-of-wrong-.patch @@ -0,0 +1,59 @@ +From 7d52945b0b261c54ec736ecc435936c5fb8b81a4 Mon Sep 17 00:00:00 2001 +From: Yousong Zhou +Date: Thu, 30 Nov 2017 11:07:12 +0800 +Subject: [PATCH] Fix app compilation failure from inclusion of wrong headers + +Compiling against glibc can fail with the following errors + + In file included from /home/stefan/Router/o26431-vmmc_v5/source/staging_dir/toolchain-mips_24kc_gcc-5.5.0_glibc/include/bits/fcntl-linux.h:321:0, + from /home/stefan/Router/o26431-vmmc_v5/source/staging_dir/toolchain-mips_24kc_gcc-5.5.0_glibc/include/bits/fcntl.h:104, + from /home/stefan/Router/o26431-vmmc_v5/source/staging_dir/toolchain-mips_24kc_gcc-5.5.0_glibc/include/fcntl.h:35, + from linux/ifxos_linux_device_access_appl.c:30: + /home/stefan/Router/o26431-vmmc_v5/source/build_dir/target-mips_24kc_glibc/linux-lantiq_xrx200/linux-4.9.65/include/linux/falloc.h:12:2: error: unknown type name '__s16' + __s16 l_type; + ^ + /home/stefan/Router/o26431-vmmc_v5/source/build_dir/target-mips_24kc_glibc/linux-lantiq_xrx200/linux-4.9.65/include/linux/falloc.h:13:2: error: unknown type name '__s16' + __s16 l_whence; + ^ + /home/stefan/Router/o26431-vmmc_v5/source/build_dir/target-mips_24kc_glibc/linux-lantiq_xrx200/linux-4.9.65/include/linux/falloc.h:14:2: error: unknown type name '__s64' + __s64 l_start; + ^ + /home/stefan/Router/o26431-vmmc_v5/source/build_dir/target-mips_24kc_glibc/linux-lantiq_xrx200/linux-4.9.65/include/linux/falloc.h:15:2: error: unknown type name '__s64' + __s64 l_len; /* len == 0 means until end of file */ + ^ + /home/stefan/Router/o26431-vmmc_v5/source/build_dir/target-mips_24kc_glibc/linux-lantiq_xrx200/linux-4.9.65/include/linux/falloc.h:16:2: error: unknown type name '__s32' + __s32 l_sysid; + ^ + /home/stefan/Router/o26431-vmmc_v5/source/build_dir/target-mips_24kc_glibc/linux-lantiq_xrx200/linux-4.9.65/include/linux/falloc.h:17:2: error: unknown type name '__u32' + __u32 l_pid; + ^ + /home/stefan/Router/o26431-vmmc_v5/source/build_dir/target-mips_24kc_glibc/linux-lantiq_xrx200/linux-4.9.65/include/linux/falloc.h:18:2: error: unknown type name '__s32' + __s32 l_pad[4]; /* reserved area */ + ^ + Makefile:1945: recipe for target 'libifxos_a-ifxos_linux_device_access_appl.o' failed + +Ref: https://bugs.lede-project.org/index.php?do=details&task_id=1196 +--- + src/Makefile.am | 6 +----- + 1 file changed, 1 insertion(+), 5 deletions(-) + +diff --git a/src/Makefile.am b/src/Makefile.am +index f95668f..d232e7f 100644 +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -14,11 +14,7 @@ lib_LIBRARIES = libifxos.a + + AM_CPPFLAGS = \ + -I@srcdir@\ +- -I@srcdir@/include \ +- -I@KERNEL_INCL_PATH@ \ +- -I@KERNEL_BUILD_PATH@/include \ +- -I@KERNEL_BUILD_PATH@/include2 \ +- -I$(TARGET_INCL_PATH) ++ -I@srcdir@/include + + if HAVE_GCC + +-- +1.8.3.1 + -- cgit v1.2.3