Skip to contentSkip to conversation

x264_r2245.bb: Fix build when DISTRO_FEATURES lacks "largefile".

PATCH New Graham Gower 1 participant 1 message Nov 30, 2010

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x264_r2245.bb: Fix build when DISTRO_FEATURES lacks "largefile".

mipsel-oe-linux-uclibc-gcc -march=mips32 -O3 -ffast-math -isystem/mnt/oe/tmp/sysroots/mipsel-oe-linux-uclibc/include -fexpensive-optimizations -fomit-frame-pointer -frename-registers -Os -Wall -I. -fPIC -std=gnu99 -s -fomit-frame-pointer -isystem/mnt/oe/tmp/sysroots/mipsel-oe-linux-uclibc/include -c -o common/mc.o common/mc.c In file included from /mnt/oe/tmp/sysroots/mipsel-oe-linux-uclibc/include/stdio.h:28:0,

                 from common/osdep.h:29,
                 from common/common.h:76,
                 from common/mc.c:24:

/mnt/oe/tmp/sysroots/mipsel-oe-linux-uclibc/include/features.h:216:5: error: #error It appears you have defined _FILE_OFFSET_BITS=64. Unfortunately, uClibc was built without large file support enabled.

---
 recipes/vlc/x264_r2245.bb |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
recipes/vlc/x264_r2245.bb +4 -0
index f533bfc..e507d32 100644
@@ -25,4 +25,8 @@ DEPENDS_x86 = "yasm-native"
 
 EXTRA_OECONF = '--enable-shared ${X264_DISABLE_ASM} --extra-cflags="${X264_ECFLAGS}"'
 
+do_configure_append() {
+	eval "${@base_contains('DISTRO_FEATURES', 'largefile', '', 'sed -i -e "/_LARGEFILE_SOURCE/d" ${S}/common/osdep.h', d)}"
+	eval "${@base_contains('DISTRO_FEATURES', 'largefile', '', 'sed -i -e "/_FILE_OFFSET_BITS/d" ${S}/common/osdep.h', d)}"
+}
 
Signature · 1 line
1.7.1