310e4f07f8
In buildroot ffmpeg uses x264 as optional dependency if BR2_PACKAGE_FFMPEG_GPL is enabled at the same time. If BR2_PACKAGE_FFMPEG_GPL is disabled and ffmpeg is built without x264 support before x264 itself is build, x264 picks up certain ffmpeg libs as optional dependency leading to build errors because x264 does not correctly link statically against ffmpeg. To avoid a circular dependency and to avoid teaching x264 how to correctly link statically with ffmpeg we just disable all ffmpeg- related options. Fixes http://autobuild.buildroot.net/results/36a/36abb5b8f3aab57fb7b63056b216b4a58143ee3e/ Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
70 lines
1.8 KiB
Makefile
70 lines
1.8 KiB
Makefile
################################################################################
|
|
#
|
|
# x264
|
|
#
|
|
################################################################################
|
|
|
|
X264_VERSION = 97eaef2ab82a46d13ea5e00270712d6475fbe42b
|
|
X264_SITE = git://git.videolan.org/x264.git
|
|
X264_LICENSE = GPL-2.0+
|
|
X264_DEPENDENCIES = host-pkgconf
|
|
X264_LICENSE_FILES = COPYING
|
|
X264_INSTALL_STAGING = YES
|
|
X264_CONF_OPTS = --disable-avs --disable-lavf --disable-swscale
|
|
|
|
ifeq ($(BR2_i386)$(BR2_x86_64),y)
|
|
# yasm needed for assembly files
|
|
X264_DEPENDENCIES += host-yasm
|
|
X264_CONF_ENV += AS="$(HOST_DIR)/usr/bin/yasm"
|
|
else ifeq ($(BR2_ARM_CPU_ARMV7A)$(BR2_aarch64),y)
|
|
# We need to pass gcc as AS, because the ARM assembly files have to be
|
|
# preprocessed
|
|
X264_CONF_ENV += AS="$(TARGET_CC)"
|
|
else
|
|
X264_CONF_OPTS += --disable-asm
|
|
endif
|
|
|
|
ifeq ($(BR2_STATIC_LIBS),)
|
|
X264_CONF_OPTS += --enable-pic --enable-shared
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_X264_CLI),)
|
|
X264_CONF_OPTS += --disable-cli
|
|
endif
|
|
|
|
ifeq ($(BR2_TOOLCHAIN_HAS_THREADS),)
|
|
X264_CONF_OPTS += --disable-thread
|
|
endif
|
|
|
|
# Even though the configure script is not generated by autoconf, x264
|
|
# uses config.sub/config.guess, so we want up-to-date versions of
|
|
# them.
|
|
X264_POST_PATCH_HOOKS += UPDATE_CONFIG_HOOK
|
|
|
|
# the configure script is not generated by autoconf
|
|
define X264_CONFIGURE_CMDS
|
|
(cd $(@D); $(TARGET_CONFIGURE_OPTS) $(X264_CONF_ENV) ./configure \
|
|
--prefix=/usr \
|
|
--host="$(GNU_TARGET_NAME)" \
|
|
--cross-prefix="$(TARGET_CROSS)" \
|
|
--disable-ffms \
|
|
--enable-static \
|
|
--disable-opencl \
|
|
$(X264_CONF_OPTS) \
|
|
)
|
|
endef
|
|
|
|
define X264_BUILD_CMDS
|
|
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D)
|
|
endef
|
|
|
|
define X264_INSTALL_STAGING_CMDS
|
|
$(TARGET_MAKE_ENV) $(MAKE) DESTDIR="$(STAGING_DIR)" -C $(@D) install
|
|
endef
|
|
|
|
define X264_INSTALL_TARGET_CMDS
|
|
$(TARGET_MAKE_ENV) $(MAKE) DESTDIR="$(TARGET_DIR)" -C $(@D) install
|
|
endef
|
|
|
|
$(eval $(generic-package))
|