blob: 51ae9d1179eed09df0ee9de40d55f35641d57c7d [file] [log] [blame]
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001SUMMARY = "H.264/MPEG-4 AVC video encoder"
2DESCRIPTION = "A free software library and application for encoding video streams into the H.264/MPEG-4 AVC format."
3HOMEPAGE = "http://www.videolan.org/developers/x264.html"
4
Andrew Geissler7e0e3c02022-02-25 20:34:39 +00005LICENSE = "GPL-2.0-only"
Patrick Williamsc124f4f2015-09-15 14:41:29 -05006LICENSE_FLAGS = "commercial"
7LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
8
Brad Bishop316dfdd2018-06-25 12:45:53 -04009DEPENDS = "nasm-native"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050010
Andrew Geissler595f6302022-01-24 19:11:47 +000011SRC_URI = "git://github.com/mirror/x264;branch=stable;protocol=https \
Patrick Williamsc124f4f2015-09-15 14:41:29 -050012 file://don-t-default-to-cortex-a9-with-neon.patch \
Brad Bishop6e60e8b2018-02-01 10:27:11 -050013 file://Fix-X32-build-by-disabling-asm.patch \
Patrick Williamsc124f4f2015-09-15 14:41:29 -050014 "
Brad Bishop316dfdd2018-06-25 12:45:53 -040015UPSTREAM_CHECK_COMMITS = "1"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050016
Andrew Geissler5f350902021-07-23 13:09:54 -040017SRCREV = "5db6aa6cab1b146e07b60cc1736a01f21da01154"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050018
Andrew Geissler9b4d8b02021-02-19 12:26:16 -060019PV = "r3039+git${SRCPV}"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050020
21S = "${WORKDIR}/git"
22
Brad Bishop19323692019-04-05 15:28:33 -040023inherit lib_package pkgconfig
Patrick Williamsc124f4f2015-09-15 14:41:29 -050024
25X264_DISABLE_ASM = ""
Patrick Williams213cb262021-08-07 19:21:33 -050026X264_DISABLE_ASM:x86 = "--disable-asm"
27X264_DISABLE_ASM:armv4 = "--disable-asm"
28X264_DISABLE_ASM:armv5 = "--disable-asm"
29X264_DISABLE_ASM:powerpc = "${@bb.utils.contains("TUNE_FEATURES", "spe", "--disable-asm", "", d)}"
30X264_DISABLE_ASM:mipsarch = "${@bb.utils.contains("TUNE_FEATURES", "r6", "", "--disable-asm", d)}"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050031
32EXTRA_OECONF = '--prefix=${prefix} \
33 --host=${HOST_SYS} \
34 --libdir=${libdir} \
35 --cross-prefix=${TARGET_PREFIX} \
36 --sysroot=${STAGING_DIR_TARGET} \
37 --enable-shared \
38 --enable-static \
39 --disable-lavf \
40 --disable-swscale \
Brad Bishop6e60e8b2018-02-01 10:27:11 -050041 --disable-opencl \
Patrick Williamsc124f4f2015-09-15 14:41:29 -050042 --enable-pic \
43 ${X264_DISABLE_ASM} \
44 '
45
46do_configure() {
Brad Bishop316dfdd2018-06-25 12:45:53 -040047 install -m 0755 ${STAGING_DATADIR_NATIVE}/gnu-config/config.guess ${S}
48 install -m 0755 ${STAGING_DATADIR_NATIVE}/gnu-config/config.sub ${S}
Patrick Williamsc124f4f2015-09-15 14:41:29 -050049 ./configure ${EXTRA_OECONF}
50}
51
Patrick Williamsc124f4f2015-09-15 14:41:29 -050052do_install() {
53 oe_runmake install DESTDIR=${D}
54}
55
Brad Bishop6e60e8b2018-02-01 10:27:11 -050056AS[unexport] = "1"