initial buildroot for linux 5.15

This commit is contained in:
Huan.Feng
2021-12-06 14:12:13 +08:00
parent d7767d594e
commit 7b6fc358fa
12736 changed files with 508822 additions and 0 deletions
@@ -0,0 +1,32 @@
Subject: [PATCH] Work around bool type redefinition by altivec
On powerpc64le, the SDL header may include altivec.h and this
(combined with -std=c99) will cause a compile failure due to bool
being redefined as a vector type.
Adjust the compiler flags to add -std=gnu99 (which is compatible with
altivec) when using gcc. The generic flag '-std=c99' is left in place for other
compilers (in the gcc case it is overridden by the (later) gnu flag).
Signed-off-by: Sam Bobroff <sam.bobroff@au1.ibm.com>
---
waftools/detections/compiler.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/waftools/detections/compiler.py b/waftools/detections/compiler.py
index 5bbba87..50836a2 100644
--- a/waftools/detections/compiler.py
+++ b/waftools/detections/compiler.py
@@ -43,7 +43,8 @@ def __add_gcc_flags__(ctx):
"-Wno-switch", "-Wparentheses", "-Wpointer-arith",
"-Wno-pointer-sign",
# GCC bug 66425
- "-Wno-unused-result"]
+ "-Wno-unused-result",
+ "-std=gnu99"]
def __add_clang_flags__(ctx):
ctx.env.CFLAGS += ["-Wno-logical-op-parentheses", "-fcolor-diagnostics",
--
2.10.0.297.gf6727b0
+41
View File
@@ -0,0 +1,41 @@
config BR2_PACKAGE_MPV_SUPPORTS_VAAPI
bool
default y if BR2_PACKAGE_LIBDRM && BR2_PACKAGE_MESA3D_OPENGL_EGL
default y if BR2_PACKAGE_WAYLAND
default y if BR2_PACKAGE_XORG7
config BR2_PACKAGE_MPV
bool "mpv"
depends on BR2_INSTALL_LIBSTDCPP # libass
depends on BR2_TOOLCHAIN_HAS_SYNC_4 # libass
depends on BR2_TOOLCHAIN_HAS_THREADS
depends on BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # C11/stdatomic.h
depends on BR2_TOOLCHAIN_HAS_ATOMIC
select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
select BR2_PACKAGE_FFMPEG
select BR2_PACKAGE_FFMPEG_SWSCALE
select BR2_PACKAGE_LIBASS
select BR2_PACKAGE_ZLIB
select BR2_PACKAGE_WAYLAND_PROTOCOLS if BR2_PACKAGE_WAYLAND
# Select xkbcommon for wayland to avoid being mysterious
select BR2_PACKAGE_LIBXKBCOMMON if BR2_PACKAGE_WAYLAND
# Select all necessary X11 dependencies if X.org is enabled
select BR2_PACKAGE_XLIB_LIBX11 if BR2_PACKAGE_XORG7
select BR2_PACKAGE_XLIB_LIBXEXT if BR2_PACKAGE_XORG7
select BR2_PACKAGE_XLIB_LIBXINERAMA if BR2_PACKAGE_XORG7
select BR2_PACKAGE_XLIB_LIBXSCRNSAVER if BR2_PACKAGE_XORG7
select BR2_PACKAGE_XLIB_LIBXRANDR if BR2_PACKAGE_XORG7
help
mpv is a fork of mplayer2 and MPlayer. It shares some features
with the former projects while introducing many more.
https://mpv.io/
comment "mpv needs a toolchain w/ C++, threads, gcc >= 4.9"
depends on BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS
depends on BR2_TOOLCHAIN_HAS_ATOMIC
depends on BR2_TOOLCHAIN_HAS_SYNC_4
depends on !BR2_TOOLCHAIN_HAS_THREADS || \
!BR2_INSTALL_LIBSTDCPP || \
!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+3
View File
@@ -0,0 +1,3 @@
# Locally calculated
sha256 100a116b9f23bdcda3a596e9f26be3a69f166a4f1d00910d1789b6571c46f3a9 mpv-0.33.1.tar.gz
sha256 a99d7b0625a0566271aad6de694e52eafd566db024f9516720d526c680d3ee30 LICENSE.GPL
+225
View File
@@ -0,0 +1,225 @@
################################################################################
#
# mpv
#
################################################################################
MPV_VERSION = 0.33.1
MPV_SITE = $(call github,mpv-player,mpv,v$(MPV_VERSION))
MPV_DEPENDENCIES = \
host-pkgconf ffmpeg libass zlib \
$(if $(BR2_PACKAGE_LIBICONV),libiconv)
MPV_LICENSE = GPL-2.0+
MPV_LICENSE_FILES = LICENSE.GPL
MPV_CPE_ID_VENDOR = mpv
MPV_INSTALL_STAGING = YES
MPV_NEEDS_EXTERNAL_WAF = YES
# Some of these options need testing and/or tweaks
MPV_CONF_OPTS = \
--prefix=/usr \
--disable-android \
--disable-caca \
--disable-cocoa \
--disable-coreaudio \
--disable-cuda-hwaccel \
--disable-opensles \
--disable-rubberband \
--disable-uchardet \
--disable-vapoursynth
ifeq ($(BR2_REPRODUCIBLE),y)
MPV_CONF_OPTS += --disable-build-date
endif
ifeq ($(BR2_STATIC_LIBS),y)
MPV_CONF_OPTS += --disable-libmpv-shared --enable-libmpv-static
else
MPV_CONF_OPTS += --enable-libmpv-shared --disable-libmpv-static
endif
# ALSA support requires pcm+mixer
ifeq ($(BR2_PACKAGE_ALSA_LIB_MIXER)$(BR2_PACKAGE_ALSA_LIB_PCM),yy)
MPV_CONF_OPTS += --enable-alsa
MPV_DEPENDENCIES += alsa-lib
else
MPV_CONF_OPTS += --disable-alsa
endif
ifeq ($(BR2_PACKAGE_MESA3D_GBM),y)
MPV_CONF_OPTS += --enable-gbm
MPV_DEPENDENCIES += mesa3d
ifeq ($(BR2_PACKAGE_LIBDRM),y)
MPV_CONF_OPTS += --enable-egl-drm
else
MPV_CONF_OPTS += --disable-egl-drm
endif
else
MPV_CONF_OPTS += --disable-gbm --disable-egl-drm
endif
# jack support
# It also requires 64-bit sync intrinsics
ifeq ($(BR2_TOOLCHAIN_HAS_SYNC_8)$(BR2_PACKAGE_JACK2),yy)
MPV_CONF_OPTS += --enable-jack
MPV_DEPENDENCIES += jack2
else
MPV_CONF_OPTS += --disable-jack
endif
# jpeg support
ifeq ($(BR2_PACKAGE_JPEG),y)
MPV_CONF_OPTS += --enable-jpeg
MPV_DEPENDENCIES += jpeg
else
MPV_CONF_OPTS += --disable-jpeg
endif
# lcms2 support
ifeq ($(BR2_PACKAGE_LCMS2),y)
MPV_CONF_OPTS += --enable-lcms2
MPV_DEPENDENCIES += lcms2
else
MPV_CONF_OPTS += --disable-lcms2
endif
# libarchive support
ifeq ($(BR2_PACKAGE_LIBARCHIVE),y)
MPV_CONF_OPTS += --enable-libarchive
MPV_DEPENDENCIES += libarchive
else
MPV_CONF_OPTS += --disable-libarchive
endif
# bluray support
ifeq ($(BR2_PACKAGE_LIBBLURAY),y)
MPV_CONF_OPTS += --enable-libbluray
MPV_DEPENDENCIES += libbluray
else
MPV_CONF_OPTS += --disable-libbluray
endif
# libcdio-paranoia
ifeq ($(BR2_PACKAGE_LIBCDIO_PARANOIA),y)
MPV_CONF_OPTS += --enable-cdda
MPV_DEPENDENCIES += libcdio-paranoia
else
MPV_CONF_OPTS += --disable-cdda
endif
# libdvdnav
ifeq ($(BR2_PACKAGE_LIBDVDNAV),y)
MPV_CONF_OPTS += --enable-dvdnav
MPV_DEPENDENCIES += libdvdnav
else
MPV_CONF_OPTS += --disable-dvdnav
endif
# libdrm
ifeq ($(BR2_PACKAGE_LIBDRM),y)
MPV_CONF_OPTS += --enable-drm
MPV_DEPENDENCIES += libdrm
else
MPV_CONF_OPTS += --disable-drm
endif
# libvdpau
ifeq ($(BR2_PACKAGE_LIBVDPAU),y)
MPV_CONF_OPTS += --enable-vdpau
MPV_DEPENDENCIES += libvdpau
else
MPV_CONF_OPTS += --disable-vdpau
endif
# LUA support, only for lua51/lua52/luajit
# This enables the controller (OSD) together with libass
ifeq ($(BR2_PACKAGE_LUA_5_1)$(BR2_PACKAGE_LUAJIT),y)
MPV_CONF_OPTS += --enable-lua
MPV_DEPENDENCIES += luainterpreter
else
MPV_CONF_OPTS += --disable-lua
endif
# OpenGL support
ifeq ($(BR2_PACKAGE_HAS_LIBGL),y)
MPV_CONF_OPTS += --enable-gl
MPV_DEPENDENCIES += libgl
else ifeq ($(BR2_PACKAGE_HAS_LIBGLES),y)
MPV_CONF_OPTS += --enable-gl
MPV_DEPENDENCIES += libgles
else ifeq ($(BR2_PACKAGE_HAS_LIBEGL),y)
MPV_CONF_OPTS += --enable-gl
MPV_DEPENDENCIES += libegl
else
MPV_CONF_OPTS += --disable-gl
endif
# pulseaudio support
ifeq ($(BR2_PACKAGE_PULSEAUDIO),y)
MPV_CONF_OPTS += --enable-pulse
MPV_DEPENDENCIES += pulseaudio
else
MPV_CONF_OPTS += --disable-pulse
endif
# SDL support
# Sdl2 requires 64-bit sync intrinsics
ifeq ($(BR2_TOOLCHAIN_HAS_SYNC_8)$(BR2_PACKAGE_SDL2),yy)
MPV_CONF_OPTS += --enable-sdl2
MPV_DEPENDENCIES += sdl2
else
MPV_CONF_OPTS += --disable-sdl2
endif
# Raspberry Pi support
ifeq ($(BR2_PACKAGE_RPI_USERLAND),y)
MPV_CONF_OPTS += --enable-rpi --enable-gl
MPV_DEPENDENCIES += rpi-userland
else
MPV_CONF_OPTS += --disable-rpi
endif
# va-api support
ifeq ($(BR2_PACKAGE_LIBVA)$(BR2_PACKAGE_MPV_SUPPORTS_VAAPI),yy)
MPV_CONF_OPTS += --enable-vaapi
MPV_DEPENDENCIES += libva
ifeq ($(BR2_PACKAGE_LIBDRM)$(BR2_PACKAGE_MESA3D_OPENGL_EGL),yy)
MPV_CONF_OPTS += --enable-vaapi-drm
else
MPV_CONF_OPTS += --disable-vaapi-drm
endif
else
MPV_CONF_OPTS += --disable-vaapi --disable-vaapi-drm
endif
# wayland support
ifeq ($(BR2_PACKAGE_WAYLAND),y)
MPV_CONF_OPTS += --enable-wayland
MPV_DEPENDENCIES += libxkbcommon wayland wayland-protocols
else
MPV_CONF_OPTS += --disable-wayland
endif
# Base X11 support. Config.in ensures that if BR2_PACKAGE_XORG7 is
# enabled, xlib_libX11, xlib_libXext, xlib_libXinerama,
# xlib_libXrandr, xlib_libXScrnSaver.
ifeq ($(BR2_PACKAGE_XORG7),y)
MPV_CONF_OPTS += --enable-x11
MPV_DEPENDENCIES += xlib_libX11 xlib_libXext xlib_libXinerama xlib_libXrandr xlib_libXScrnSaver
# XVideo
ifeq ($(BR2_PACKAGE_XLIB_LIBXV),y)
MPV_CONF_OPTS += --enable-xv
MPV_DEPENDENCIES += xlib_libXv
else
MPV_CONF_OPTS += --disable-xv
endif
else
MPV_CONF_OPTS += --disable-x11
endif
ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
MPV_CONF_ENV += LDFLAGS="$(TARGET_LDFLAGS) -latomic"
endif
$(eval $(waf-package))