Kodi 18.0 has just been released and there's a new FFmpeg version available for it:
https://kodi.tv/article/kodi-180
https://github.com/xbmc/xbmc/tree/ma.../target/ffmpeg
I'm working on compiling Kodi 18.0 for Slackware ARM - Raspberry Pi boards and hope that this weekend I'll be able to create a thread and write down the instructions (they changed the way it builds, wrapped everything in cmake ...FFS...).
Meanwhile you can play with the new FFmpeg 4.0.3-Leia-RC5, but be advised, I'm putting this in bold so you won't miss it:
Due to the version change, you'll need to rebuild all applications that are linked to FFmpeg, goofing around with the libs (creating symlinks for backward compatibility) won't work!
This new FFmpeg version has some more improvements and optimizations and the configure script is broken and needs a patch - it suffers from far-sightedness, as it cannot find OMX_Core.h in the /opt/vc tree.
- grab the code and unpack it:
Code:
wget https://github.com/xbmc/FFmpeg/archive/4.0.3-Leia-RC5.tar.gz
tar -xvzpf 4.0.3-Leia-RC5.tar.gz
cd FFmpeg-4.0.3-Leia-RC5/
- as mentioned, if you use the original configure script you'll end up with:
Code:
ERROR: OMX_Core.h not found
If you think configure made a mistake, make sure you are using the latest
version from Git. If the latest version fails, report the problem to the
ffmpeg-user@ffmpeg.org mailing list or IRC #ffmpeg on irc.freenode.net.
Include the log file "ffbuild/config.log" produced by configure as this will help
solve the problem.
- I just took the omx related configure section from the well tested & working older FFmpeg-3.1.9-Krypton-17.4 and made a working patch out of it
- therefore, create the file configure.patch in the FFmpeg source tree with the following content:
Code:
--- configure-ok 2019-01-31 22:58:17
+++ configure 2019-01-31 22:58:59
@@ -6138,10 +6138,12 @@
check_lib opengl ES2/gl.h glGetError "-isysroot=${sysroot} -Wl,-framework,OpenGLES" ||
die "ERROR: opengl not found."
}
-enabled omx && require_header OMX_Core.h
-enabled omx_rpi && { check_header OMX_Core.h ||
- { ! enabled cross_compile && add_cflags -isystem/opt/vc/include/IL && check_header OMX_Core.h ; } ||
- die "ERROR: OpenMAX IL headers not found"; } && enable omx
+enabled omx_rpi && enable omx
+enabled omx && { check_header OMX_Core.h ||
+ { ! enabled cross_compile && enabled omx_rpi && {
+ add_cflags -isystem/opt/vc/include/IL ; }
+ check_header OMX_Core.h ; } ||
+ die "ERROR: OpenMAX IL headers not found"; }
enabled openssl && { check_pkg_config openssl openssl openssl/ssl.h OPENSSL_init_ssl ||
check_pkg_config openssl openssl openssl/ssl.h SSL_library_init ||
check_lib openssl openssl/ssl.h SSL_library_init -lssl -lcrypto ||
- to patch the configure script just run:
Code:
patch configure < configure.patch
- you're all set and you can move to the configuration & build
- the configure options have changed and you'll need to use these actual ones:
For Pi 1/Zero:
Code:
./configure --extra-ldflags="-L /opt/vc/lib/" --extra-cflags='-march=armv6zk -mtune=arm1176jzf-s -mfpu=vfp -mfloat-abi=soft' --extra-cxxflags='-march=armv6zk -mtune=arm1176jzf-s -mfpu=vfp -mfloat-abi=soft' --disable-devices --disable-ffprobe --disable-doc --disable-w32threads --enable-ffplay --extra-libs=-ldl --enable-shared --enable-libass --disable-devices --enable-mmal --enable-decoder=h264_mmal --enable-decoder=mpeg2_mmal --enable-encoder=h264_omx --enable-omx --enable-omx-rpi --disable-neon --enable-gnutls --enable-libvorbis --enable-muxer=ogg --enable-encoder=libvorbis --enable-nonfree --enable-libx264 --enable-gpl --enable-runtime-cpudetect --enable-postproc --enable-bzlib --enable-muxer=spdif --enable-muxer=adts --enable-muxer=asf --enable-encoder=ac3 --enable-encoder=aac --enable-encoder=wmav2 --enable-protocol=http --enable-encoder=png --enable-encoder=mjpeg --enable-pthreads --enable-pic --enable-zlib --disable-mipsdsp --disable-mipsdspr2
For Pi 2B:
Code:
./configure --extra-ldflags="-L /opt/vc/lib/" --extra-cflags='-march=armv7-a -mtune=cortex-a7 -mfpu=neon-vfpv4 -mvectorize-with-neon-quad -mfloat-abi=hard' --extra-cxxflags='-march=armv7-a -mtune=cortex-a7 -mfpu=neon-vfpv4 -mvectorize-with-neon-quad -mfloat-abi=hard' --disable-devices --disable-ffprobe --disable-doc --disable-w32threads --enable-ffplay --extra-libs=-ldl --enable-shared --enable-libass --disable-devices --enable-mmal --enable-decoder=h264_mmal --enable-decoder=mpeg2_mmal --enable-encoder=h264_omx --enable-omx --enable-omx-rpi --enable-neon --enable-gnutls --enable-libvorbis --enable-muxer=ogg --enable-encoder=libvorbis --enable-nonfree --enable-libx264 --enable-gpl --enable-runtime-cpudetect --enable-postproc --enable-bzlib --enable-muxer=spdif --enable-muxer=adts --enable-muxer=asf --enable-encoder=ac3 --enable-encoder=aac --enable-encoder=wmav2 --enable-protocol=http --enable-encoder=png --enable-encoder=mjpeg --enable-pthreads --enable-pic --enable-zlib --disable-mipsdsp --disable-mipsdspr2
For Pi 3B:
Code:
./configure --extra-ldflags="-L /opt/vc/lib/" --extra-cflags='-march=armv8-a+crc -mtune=cortex-a53 -mfpu=neon-fp-armv8 -mvectorize-with-neon-quad -mfloat-abi=hard' --extra-cxxflags='-march=armv8-a+crc -mtune=cortex-a53 -mfpu=neon-fp-armv8 -mvectorize-with-neon-quad -mfloat-abi=hard' --disable-devices --disable-ffprobe --disable-doc --disable-w32threads --enable-ffplay --extra-libs=-ldl --enable-shared --enable-libass --disable-devices --enable-mmal --enable-decoder=h264_mmal --enable-decoder=mpeg2_mmal --enable-encoder=h264_omx --enable-omx --enable-omx-rpi --enable-neon --enable-gnutls --enable-libvorbis --enable-muxer=ogg --enable-encoder=libvorbis --enable-nonfree --enable-libx264 --enable-gpl --enable-runtime-cpudetect --enable-postproc --enable-bzlib --enable-muxer=spdif --enable-muxer=adts --enable-muxer=asf --enable-encoder=ac3 --enable-encoder=aac --enable-encoder=wmav2 --enable-protocol=http --enable-encoder=png --enable-encoder=mjpeg --enable-pthreads --enable-pic --enable-zlib --disable-mipsdsp --disable-mipsdspr2
- start building:
Code:
#on Pi1 / Zero run:
make -j 1 V=1
# on Pi 2B/ Pi 3B (both quad-core) to avoid exhausting the 1GB RAM, run only 3 make jobs
make -j 3 V=1
- remove any other existent ffmpeg versions/packages and install this one:
- or, create a package (recommended) and install that one:
https://docs.slackware.com/howtos:sl...ding_a_package
Have Fun!