From 72fd2b48b7154274a1d2009cdaab54e7f49fb3aa Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 28 Dec 2024 06:30:54 +0000 Subject: gentoo auto-resync : 28:12:2024 - 06:30:54 --- media-tv/Manifest.gz | Bin 3440 -> 3438 bytes media-tv/kodi/Manifest | 6 +- media-tv/kodi/kodi-21.1-r1.ebuild | 546 ++++++++++++++++++++++++++++++++++ media-tv/kodi/kodi-21.1.ebuild | 546 ---------------------------------- media-tv/kodi/kodi-21.9999.ebuild | 2 +- media-tv/kodi/kodi-9999.ebuild | 2 +- media-tv/mythtv/Manifest | 2 +- media-tv/mythtv/mythtv-33.1-r2.ebuild | 386 ------------------------ media-tv/mythtv/mythtv-33.1-r3.ebuild | 386 ++++++++++++++++++++++++ 9 files changed, 938 insertions(+), 938 deletions(-) create mode 100644 media-tv/kodi/kodi-21.1-r1.ebuild delete mode 100644 media-tv/kodi/kodi-21.1.ebuild delete mode 100644 media-tv/mythtv/mythtv-33.1-r2.ebuild create mode 100644 media-tv/mythtv/mythtv-33.1-r3.ebuild (limited to 'media-tv') diff --git a/media-tv/Manifest.gz b/media-tv/Manifest.gz index de6d53b07f4f..586761c14632 100644 Binary files a/media-tv/Manifest.gz and b/media-tv/Manifest.gz differ diff --git a/media-tv/kodi/Manifest b/media-tv/kodi/Manifest index ca0f5c4706e7..05e825318b00 100644 --- a/media-tv/kodi/Manifest +++ b/media-tv/kodi/Manifest @@ -9,7 +9,7 @@ DIST kodi-21.1-Omega.tar.gz 41091890 BLAKE2B e711ef9b958ff3f8e006913ea6c42092164 DIST libdvdcss-1.4.3-Next-Nexus-Alpha2-2.tar.gz 102124 BLAKE2B 2f503d3ab767094958f7ec10b4ad11ffd02665deee571c8f3c739bef5fc7e2ff84babc5a3fdee638dc095f896b72fe3ce65e6b688674cb5f7b7b77190992688c SHA512 d3be3bfc13c5ea56d8db745c2aab090c99760684fe4c8f62a13d266feb319e9180ceeecf8116bfd2ed90d9accba2c11dbbf93b61ad00f69a40812ebf4eabcdda DIST libdvdnav-6.1.1-Next-Nexus-Alpha2-2.tar.gz 128547 BLAKE2B db4d05836d8fbb3637ae50bdbfc0e4b612ee6b3be24addfea94ce772c3bf28d58b63a3f252d6f9f016f72f8cbb841cc1820b091226b136f4c4664385a32da73c SHA512 51e6fc033121241354a5f0b3fc9a430577ae3ff6bb7f31445aa548ef4893037fb80eea3b2c6774c81e9ebaf9c45e9b490c98c2c65eb38f9f7daba84b236f7e1d DIST libdvdread-6.1.3-Next-Nexus-Alpha2-2.tar.gz 110513 BLAKE2B c94feb5a03a12efa5b7767965118d2500a088299ea36f3b82e46d157e45893e6b04503cb50f179ca681bac914457607fab26acfa6e304752b355c407578572d1 SHA512 629a41157d07b8ec0ea1fe89ae5ec48f63047472a862782b805c531ae31a0376fc4dc15175f8280c3ef91d7fa977bacebb1b51232640034a34bab2293210fc5e -EBUILD kodi-21.1.ebuild 14313 BLAKE2B 0595a24ed49e32323dd7c26c4dc55421842edf76e9acebd3ca8d8a1f430c9667e65f2b904c29b5716124c2914e33988c6cbfbd76b4419666b33f8a706096d58c SHA512 c41888c1e1d125bc3b0210d88b76904c0d8e19a38e02e81cde7fab74702942374ae9c653e2b33a5478a34a7cc7995c8b4658d7b41605e9d3b6e6c2aadf892e85 -EBUILD kodi-21.9999.ebuild 14269 BLAKE2B 0b38b47b819e40f58996ee79bb4aad1da3177175dc0939c764d4b22de0f8c447ed436e491e34239a13f2e5197c32ab51c02b6dbe3fe76bf30eafe301de355277 SHA512 ac3fc2bdb912abe662760f55135875ac143e20471cb8a6b6ee69ed0983f085eeed47968a0c950155000caae299a67b35d404115ec70c6d98791bee1372b0278e -EBUILD kodi-9999.ebuild 13796 BLAKE2B a34999f5ec80f1b4a04e9b7e6ba94464702b277ac21ac21460423b5c900a5f06521f28e2399217d6c43b817203a67ccb5d057e850282d425d93803b5d679e3be SHA512 e76a02c7eb84b8ca4f1fb6fd9d09be0073b49863cc3d7a64a5412bab022d8b3f8c0e0e180902d12b69104c601f7e0d5eb458232613720b514db7769f76f563dc +EBUILD kodi-21.1-r1.ebuild 14307 BLAKE2B e9f37b5c1a8198477cd6de86abe6f394c0ca827e6587df2d8d7109452049f02490b0680706b29d7b0d281acb515269746a35269fbd6a31acf033a3948ac57c33 SHA512 59285053228b3274f941177353714aab4f22f1376c509d0f960e15aeaf155b0c08499354bb228fdd15c25618b2a07a5a8bc5f9769d83a44181a332603b3b54e1 +EBUILD kodi-21.9999.ebuild 14263 BLAKE2B fd6ff121c0d44484d140b1052224de3d4206db15d46b9805475c21d9ee93a2131eb30182c45bc08bcc865831e524a1f25c001df32eda8249c6b7348b6a89e931 SHA512 394b9a3e746a806ed19453bdd7505c02fd373773c56249ab885cdb9984fb75e67ed0e934b80cfe81797862aec541a9171f938e302724091d2d07ab9a37e9e76d +EBUILD kodi-9999.ebuild 13790 BLAKE2B a71e12e1fb6348a021dbb2db74b3ea700381482e537c5b3fc6d1b14eb5bac90b5320669e894f29bb2739a21b186ac2f15876d463f774acd14ed50f43deac7a48 SHA512 278fb9b330bff84246b4264673957386b00a0646d35106cb7c9887f4e0640bf8aa428fdf5d8e9637da22edda62476b5085fe2db2b81a1c4eaa3147256aa58928 MISC metadata.xml 2555 BLAKE2B 65aeffc3e2130f686a6172d43bd077f86fc45932ace4b865b112d1849f3f3bc3e99d819f09b326d94f83f3834fd504d57405876e304f459e35a280dfcc198283 SHA512 d2219a960862ba094effebc372e0af2973876fa429e39a943298531888c104e36bebff9efd679778f40f1e3ba6dfe2f719545b77f29a70abfe78deb0a9b4d1f9 diff --git a/media-tv/kodi/kodi-21.1-r1.ebuild b/media-tv/kodi/kodi-21.1-r1.ebuild new file mode 100644 index 000000000000..9427b2c24098 --- /dev/null +++ b/media-tv/kodi/kodi-21.1-r1.ebuild @@ -0,0 +1,546 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +CODENAME="Omega" + +# libdvd{css,read,nav} are not unbundlable without patching the buildsystem. + +# Versions for the forked projects that are bundled +# See tools/depends/target//-VERSION +LIBDVDCSS_VERSION="1.4.3-Next-Nexus-Alpha2-2" +LIBDVDREAD_VERSION="6.1.3-Next-Nexus-Alpha2-2" +LIBDVDNAV_VERSION="6.1.1-Next-Nexus-Alpha2-2" +FFMPEG_VERSION="6.0.1" + +# Java bundles from xbmc/interfaces/swig/CMakeLists.txt +GROOVY_VERSION="4.0.16" +APACHE_COMMON_LANG_VERSION="3.14.0" +APACHE_COMMON_TEXT_VERSION="1.11.0" + +_JAVA_PKG_WANT_BUILD_VM=( {openjdk{,-jre},icedtea}{,-bin}-{8,11,17,21} ) +JAVA_PKG_WANT_BUILD_VM=${_JAVA_PKG_WANT_BUILD_VM[@]} +# Required to be set, but not used. +JAVA_PKG_WANT_SOURCE="21" +JAVA_PKG_WANT_TARGET="21" + +PYTHON_REQ_USE="sqlite,ssl" +PYTHON_COMPAT=( python3_{10..12} ) + +# See cmake/scripts/common/ArchSetup.cmake for available options +CPU_FLAGS="cpu_flags_x86_sse cpu_flags_x86_sse2 cpu_flags_x86_sse3 cpu_flags_x86_sse4_1 cpu_flags_x86_sse4_2 cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_arm_neon" + +inherit autotools cmake desktop flag-o-matic java-pkg-2 libtool linux-info optfeature pax-utils python-single-r1 \ + toolchain-funcs xdg + +DESCRIPTION="A free and open source media-player and entertainment hub" +HOMEPAGE="https://kodi.tv/" + +SRC_URI=" + https://github.com/xbmc/libdvdnav/archive/${LIBDVDNAV_VERSION}.tar.gz + -> libdvdnav-${LIBDVDNAV_VERSION}.tar.gz + https://github.com/xbmc/libdvdread/archive/${LIBDVDREAD_VERSION}.tar.gz + -> libdvdread-${LIBDVDREAD_VERSION}.tar.gz + https://mirrors.kodi.tv/build-deps/sources/apache-groovy-binary-${GROOVY_VERSION}.zip + https://mirrors.kodi.tv/build-deps/sources/commons-lang3-${APACHE_COMMON_LANG_VERSION}-bin.tar.gz + https://mirrors.kodi.tv/build-deps/sources/commons-text-${APACHE_COMMON_TEXT_VERSION}-bin.tar.gz + css? ( + https://github.com/xbmc/libdvdcss/archive/${LIBDVDCSS_VERSION}.tar.gz + -> libdvdcss-${LIBDVDCSS_VERSION}.tar.gz + ) + !system-ffmpeg? ( + https://ffmpeg.org/releases/ffmpeg-${FFMPEG_VERSION}.tar.gz + ) +" +if [[ ${PV} == *9999 ]] ; then + EGIT_REPO_URI="https://github.com/xbmc/xbmc.git" + if [[ ${PV} != "9999" ]]; then + EGIT_BRANCH="${CODENAME}" + fi + inherit git-r3 +else + MY_PV=${PV/_p/_r} + MY_PV=${MY_PV/_alpha/a} + MY_PV=${MY_PV/_beta/b} + MY_PV=${MY_PV/_rc/rc} + MY_PV="${MY_PV}-${CODENAME}" + MY_P="${PN}-${MY_PV}" + SRC_URI+=" https://github.com/xbmc/xbmc/archive/${MY_PV}.tar.gz -> ${MY_P}.tar.gz" + KEYWORDS="amd64 ~arm arm64 ~riscv ~x86" + S=${WORKDIR}/xbmc-${MY_PV} +fi + +LICENSE="GPL-2+" +# vendored dependencies +# apache-groovy, common-lang3 and commons-text +LICENSE+=" Apache-2.0" +# libdvdnav, libdvdread and libdvdcss. +LICENSE+=" GPL-2+" +# ffmpeg built as USE="gpl" +LICENSE+=" !system-ffmpeg? ( GPL-2 )" + +SLOT="0" +# use flag is called libusb so that it doesn't fool people in thinking that +# it is _required_ for USB support. Otherwise they'll disable udev and +# that's going to be worse. +IUSE="airplay alsa bluetooth bluray caps cec +css dbus doc eventclients gbm gles lcms libusb lirc mariadb mysql nfs +optical pipewire pulseaudio samba soc +system-ffmpeg test udf udev upnp vaapi vdpau wayland webserver X +xslt zeroconf ${CPU_FLAGS}" +REQUIRED_USE=" + ${PYTHON_REQUIRED_USE} + || ( gbm wayland X ) + ?? ( mariadb mysql ) + bluray? ( udf ) + gbm? ( udev ) + soc? ( system-ffmpeg ) + udev? ( !libusb ) + vdpau? ( X !gles !gbm ) + zeroconf? ( dbus ) +" +RESTRICT="!test? ( test )" + +# dev-libs/libcec[-cubox] bug #818262 +COMMON_DEPEND=" + >=dev-libs/flatbuffers-23.3.3:= + >=dev-libs/lzo-2.04:2 + media-libs/giflib:= + >=media-libs/libjpeg-turbo-2.0.4:= + >=media-libs/libpng-1.6.26:0= + wayland? ( + dev-cpp/waylandpp:= + ) +" +COMMON_TARGET_DEPEND="${PYTHON_DEPS} + >=net-misc/curl-7.68.0[http2] + >=sys-libs/zlib-1.2.11 + dev-db/sqlite:3 + dev-libs/crossguid + >=dev-libs/fribidi-1.0.5 + >=dev-libs/libcdio-2.1.0:=[cxx] + >=dev-libs/libfmt-6.1.2:= + dev-libs/libfstrcmp + dev-libs/libpcre[cxx] + >=dev-libs/openssl-1.1.1k:0= + >=dev-libs/spdlog-1.5.0:= + dev-libs/tinyxml[stl] + dev-libs/tinyxml2:= + media-fonts/roboto + media-libs/libglvnd[X?] + >=media-libs/freetype-2.10.1 + media-libs/harfbuzz:= + >=media-libs/libass-0.15.0:= + media-libs/mesa[egl(+),gbm(+)?,wayland?,X?] + media-libs/taglib:= + sci-libs/kissfft + virtual/libiconv + virtual/ttf-fonts + x11-libs/libdrm + $(python_gen_cond_dep ' + dev-python/pillow[${PYTHON_USEDEP}] + dev-python/pycryptodome[${PYTHON_USEDEP}] + ') + airplay? ( + >=app-pda/libplist-2.0.0:= + net-libs/shairplay + ) + alsa? ( + >=media-libs/alsa-lib-1.1.4.1 + ) + bluetooth? ( + net-wireless/bluez:= + ) + bluray? ( + >=media-libs/libbluray-1.1.2:= + ) + caps? ( + sys-libs/libcap + ) + cec? ( + >=dev-libs/libcec-4.0[-cubox] + ) + dbus? ( + sys-apps/dbus + ) + gbm? ( + >=dev-libs/libinput-1.10.5:= + media-libs/libdisplay-info + x11-libs/libxkbcommon + ) + gles? ( + || ( + >=media-libs/mesa-24.1.0_rc1[opengl] + =media-libs/lcms-2.10:2 + ) + libusb? ( + virtual/libusb:1 + ) + lirc? ( + app-misc/lirc + ) + mariadb? ( + dev-db/mariadb-connector-c:= + ) + mysql? ( + dev-db/mysql-connector-c:= + ) + nfs? ( + >=net-fs/libnfs-2.0.0:= + ) + pipewire? ( + >=media-video/pipewire-0.3.50:= + ) + pulseaudio? ( + media-libs/libpulse + ) + samba? ( + >=net-fs/samba-3.4.6[smbclient(+)] + ) + system-ffmpeg? ( + =media-video/ffmpeg-6*:=[encode,soc(-)?,postproc,vaapi?,vdpau?,X?] + ) + !system-ffmpeg? ( + app-arch/bzip2 + app-arch/xz-utils + media-libs/dav1d:= + net-libs/gnutls:= + ) + udf? ( + >=dev-libs/libudfread-1.0.0 + ) + udev? ( + virtual/libudev:= + ) + vaapi? ( + media-libs/libva:=[wayland?,X?] + ) + vdpau? ( + || ( + >=x11-libs/libvdpau-1.1 + >=x11-drivers/nvidia-drivers-180.51 + ) + ) + wayland? ( + >=x11-libs/libxkbcommon-0.4.1[wayland] + ) + webserver? ( + >=net-libs/libmicrohttpd-0.9.77:=[messages(+)] + ) + X? ( + x11-libs/libX11 + x11-libs/libXext + x11-libs/libXrandr + ) + xslt? ( + dev-libs/libxslt + >=dev-libs/libxml2-2.9.4 + ) + zeroconf? ( + net-dns/avahi[dbus] + ) +" +RDEPEND=" + ${COMMON_DEPEND} + ${COMMON_TARGET_DEPEND} +" +DEPEND=" + ${COMMON_DEPEND} + ${COMMON_TARGET_DEPEND} + >=dev-libs/rapidjson-1.0.2 + test? ( + >=dev-cpp/gtest-1.10.0 + ) + wayland? ( + >=dev-libs/wayland-protocols-1.7 + ) + X? ( + x11-base/xorg-proto + x11-libs/libXrender + ) +" +BDEPEND=" + ${COMMON_DEPEND} + app-arch/unzip + dev-build/cmake + dev-lang/swig + virtual/pkgconfig + <=virtual/jre-21:* + doc? ( + app-text/doxygen + ) +" + +PATCHES=( + "${FILESDIR}"/kodi-21-optional-ffmpeg-libx11.patch + "${FILESDIR}"/kodi-21.1-silence-libdvdread-git.patch + "${FILESDIR}"/kodi-21.1-fix-gcc15.patch +) + +# bug #544020 +CONFIG_CHECK="~IP_MULTICAST" +ERROR_IP_MULTICAST=" +In some cases Kodi needs to access multicast addresses. +Please consider enabling IP_MULTICAST under Networking options. +" + +pkg_setup() { + check_extra_config + java-pkg-2_pkg_setup + python-single-r1_pkg_setup +} + +src_unpack() { + if [[ ${PV} == *9999 ]] ; then + git-r3_src_unpack + else + unpack ${MY_P}.tar.gz + fi + + unpack apache-groovy-binary-${GROOVY_VERSION}.zip + unpack commons-lang3-${APACHE_COMMON_LANG_VERSION}-bin.tar.gz + unpack commons-text-${APACHE_COMMON_TEXT_VERSION}-bin.tar.gz +} + +src_prepare() { + cmake_src_prepare + + # avoid long delays when powerkit isn't running #348580 + sed -i \ + -e '/dbus_connection_send_with_reply_and_block/s:-1:3000:' \ + xbmc/platform/linux/*.cpp || die + + # Add all possible names for kissfft libraries + for datatype in {float,int16,int32,simd}; do + sed -i \ + -e "s/\(find_library(KISSFFT_LIBRARY NAMES .*\)/\1 kissfft-${datatype} kissfft-${datatype}-openmp/" \ + cmake/modules/FindKissFFT.cmake || die + done + + if tc-is-cross-compiler; then + # These tools are automatically built with CMake during a native build + # but need to be built in advance using Autotools for a cross build. + NATIVE_TOOLS=( + TexturePacker + JsonSchemaBuilder + ) + + local t + for t in "${NATIVE_TOOLS[@]}" ; do + pushd "${S}/tools/depends/native/$t/src" >/dev/null || die + AT_NOELIBTOOLIZE="yes" AT_TOPLEVEL_EAUTORECONF="yes" eautoreconf + popd >/dev/null || die + done + elibtoolize + fi +} + +src_configure() { + local core_platform=( + $(usev gbm) + $(usev wayland) + $(usev X x11) + ) + + local mycmakeargs=( + -Wno-dev # less noise + + -DAPP_RENDER_SYSTEM=$(usex gles gles gl) + -DCORE_PLATFORM_NAME="${core_platform[*]}" + -Ddocdir="${EPREFIX}/usr/share/doc/${PF}" + -DENABLE_TESTING=$(usex test) + -DVERBOSE=ON + + # Enforce use of configured python interpeter + -DPYTHON_PATH=$(python_get_library_path) + -DPYTHON_VER=${EPYTHON##python} # wont work for pypy + + # Toolchain + -DENABLE_CCACHE=OFF + -DENABLE_CLANGFORMAT=OFF + -DENABLE_CLANGTIDY=OFF + -DENABLE_CPPCHECK=OFF + -DENABLE_INCLUDEWHATYOUUSE=OFF + # https://bugs.gentoo.org/show_bug.cgi?id=606124 + -DENABLE_GOLD=OFF + -DENABLE_LLD=OFF + -DENABLE_MOLD=OFF + -DUSE_LTO=OFF + + # Features + -DENABLE_AIRTUNES=$(usex airplay) + -DENABLE_ALSA=$(usex alsa) + -DENABLE_AVAHI=$(usex zeroconf) + -DENABLE_BLUETOOTH=$(usex bluetooth) + -DENABLE_BLURAY=$(usex bluray) + -DENABLE_CAP=$(usex caps) + -DENABLE_CEC=$(usex cec) + -DENABLE_DBUS=$(usex dbus) + -DENABLE_DVDCSS=$(usex css) + -DENABLE_EVENTCLIENTS=ON # alway enable to have 'kodi-send' and filter extra stuff in 'src_install()' + -DENABLE_ISO9660PP=$(usex optical) + -DENABLE_LCMS2=$(usex lcms) + -DENABLE_LIRCCLIENT=$(usex lirc) + -DENABLE_MARIADBCLIENT=$(usex mariadb) + -DENABLE_MDNS=OFF # used only on Android + -DENABLE_MICROHTTPD=$(usex webserver) + -DENABLE_MYSQLCLIENT=$(usex mysql) + -DENABLE_NFS=$(usex nfs) + -DENABLE_OPENGL=$(usex !gles) + -DENABLE_OPENGLES=$(usex gles) + -DENABLE_OPTICAL=$(usex optical) + -DENABLE_PIPEWIRE=$(usex pipewire) + -DENABLE_PLIST=$(usex airplay) + -DENABLE_PULSEAUDIO=$(usex pulseaudio) + -DENABLE_SMBCLIENT=$(usex samba) + -DENABLE_SNDIO=OFF + -DENABLE_UDEV=$(usex udev) + -DENABLE_UDFREAD=$(usex udf) + -DENABLE_UPNP=$(usex upnp) + -DENABLE_VAAPI=$(usex vaapi) + -DENABLE_VDPAU=$(usex vdpau) + -DENABLE_XSLT=$(usex xslt) + + -DWITH_FFMPEG=$(usex system-ffmpeg) + + #To bundle or not + -DENABLE_INTERNAL_CROSSGUID=OFF + -DENABLE_INTERNAL_DAV1D=OFF + -DENABLE_INTERNAL_FFMPEG="$(usex !system-ffmpeg)" + -DENABLE_INTERNAL_FLATBUFFERS=OFF + -DENABLE_INTERNAL_FMT=OFF + -DENABLE_INTERNAL_FSTRCMP=OFF + -DENABLE_INTERNAL_GTEST=OFF + -DENABLE_INTERNAL_KISSFFT=OFF + -DENABLE_INTERNAL_PCRE=OFF + -DENABLE_INTERNAL_RapidJSON=OFF + -DENABLE_INTERNAL_SPDLOG=OFF + -DENABLE_INTERNAL_TAGLIB=OFF + -DENABLE_INTERNAL_UDFREAD=OFF + + -DTARBALL_DIR="${DISTDIR}" + -Dlibdvdnav_URL="${DISTDIR}/libdvdnav-${LIBDVDNAV_VERSION}.tar.gz" + -Dlibdvdread_URL="${DISTDIR}/libdvdread-${LIBDVDREAD_VERSION}.tar.gz" + -Dgroovy_SOURCE_DIR="${WORKDIR}/groovy-${GROOVY_VERSION}" + -Dapache-commons-lang_SOURCE_DIR="${WORKDIR}/commons-lang3-${APACHE_COMMON_LANG_VERSION}" + -Dapache-commons-text_SOURCE_DIR="${WORKDIR}/commons-text-${APACHE_COMMON_TEXT_VERSION}" + ) + + # Separated to avoid "Manually-specified variables were not used by the project:" + use cec && mycmakeargs+=( -DENABLE_INTERNAL_CEC=OFF ) + use css && mycmakeargs+=( -Dlibdvdcss_URL="${DISTDIR}/libdvdcss-${LIBDVDCSS_VERSION}.tar.gz" ) + use nfs && mycmakeargs+=( -DENABLE_INTERNAL_NFS=OFF ) + use !system-ffmpeg && mycmakeargs+=( + -DFFMPEG_URL="${DISTDIR}/ffmpeg-${FFMPEG_VERSION}.tar.gz" + ) + use !udev && mycmakeargs+=( -DENABLE_LIBUSB=$(usex libusb) ) + use X && use !gles && mycmakeargs+=( -DENABLE_GLX=ON ) + + for flag in ${CPU_FLAGS[@]} ; do + local name=${flag#cpu_flags_*_} + mycmakeargs+=( -DENABLE_${name^^}=$(usex ${flag}) ) + done + + if ! is-flag -DNDEBUG && ! is-flag -D_DEBUG ; then + # Kodi requires one of the 'NDEBUG' or '_DEBUG' defines + append-cflags -DNDEBUG + append-cxxflags -DNDEBUG + fi + + # Violates ODR (bug #860984) and USE_LTO does spooky stuff + # https://github.com/xbmc/xbmc/commit/cb72a22d54a91845b1092c295f84eeb48328921e + filter-lto + + if tc-is-cross-compiler; then + for t in "${NATIVE_TOOLS[@]}" ; do + pushd "${S}/tools/depends/native/$t/src" >/dev/null || die + econf_build + install -m0755 /dev/null "$t" || die # Actually build later. + mycmakeargs+=( -DWITH_${t^^}="${PWD}/$t" ) + popd >/dev/null || die + done + fi + + cmake_src_configure +} + +src_compile() { + if tc-is-cross-compiler; then + for t in "${NATIVE_TOOLS[@]}" ; do + emake -C "${S}/tools/depends/native/$t/src" + done + fi + + cmake_src_compile all + use doc && cmake_build doc + use test && cmake_build kodi-test +} + +src_test() { + local -x CMAKE_SKIP_TESTS=( + # Known failing, unreliable test + # bug #743938 + TestCPUInfo.GetCPUFrequency + # Test failure stemming from sci-libs/kissfft + # The difference between output[2i] and (i==freq1?1.0:0.0) is inf, which exceeds 1e-7, where output[2i] + # evaluates to inf,(i==freq1?1.0:0.0) evaluates to 0, and 1e-7 evaluates to 9.9999999999999995e-08. + TestRFFT.SimpleSignal + # Tries to ping localhost, naturally breaking network-sandbox + TestNetwork.PingHost + ) + + if use arm || use x86; then + # bug #779184 + # https://github.com/xbmc/xbmc/issues/18594 + CMAKE_SKIP_TESTS+=( + TestDateTime.Reset + TestDateTime.SetDateTime + TestDateTime.SetFromDBTime + ) + fi + + # see https://github.com/xbmc/xbmc/issues/17860#issuecomment-630120213 + local -x KODI_HOME="${BUILD_DIR}" + + cmake_src_test +} + +src_install() { + cmake_src_install + + # bug #457588 + pax-mark Em "${ED}"/usr/$(get_libdir)/${PN}/${PN}.bin + + newicon media/icon48x48.png kodi.png + + rm "${ED}"/usr/share/kodi/addons/skin.estuary/fonts/Roboto-Thin.ttf || die + dosym ../../../../fonts/roboto/Roboto-Thin.ttf \ + usr/share/kodi/addons/skin.estuary/fonts/Roboto-Thin.ttf + + if use !eventclients ; then + rm -f "${ED}"/usr/bin/kodi-ps3remote || die + rm -f "${D}"$(python_get_sitedir)/kodi/ps3_remote.py || die + rm -rf "${D}"$(python_get_sitedir)/kodi/ps3 || die + rm -rf "${D}"$(python_get_sitedir)/kodi/bt || die + rm -rf "${ED}"/usr/share/doc/${PF}/kodi-eventclients-dev || die + fi + + python_optimize "${D}$(python_get_sitedir)" + + einstalldocs + use doc && dodoc -r "${S}"/docs/html/ +} + +pkg_postinst() { + xdg_pkg_postinst + + if use dbus ; then + optfeature "getting battery level and active power source" sys-power/upower + optfeature "control of shutdown, reboot, suspend, and hibernate" sys-auth/elogind sys-apps/systemd + optfeature "storage management support (automounting, volume monitoring, etc)" sys-fs/udisks:2 + fi +} diff --git a/media-tv/kodi/kodi-21.1.ebuild b/media-tv/kodi/kodi-21.1.ebuild deleted file mode 100644 index 40695f070a1a..000000000000 --- a/media-tv/kodi/kodi-21.1.ebuild +++ /dev/null @@ -1,546 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -CODENAME="Omega" - -# libdvd{css,read,nav} are not unbundlable without patching the buildsystem. - -# Versions for the forked projects that are bundled -# See tools/depends/target//-VERSION -LIBDVDCSS_VERSION="1.4.3-Next-Nexus-Alpha2-2" -LIBDVDREAD_VERSION="6.1.3-Next-Nexus-Alpha2-2" -LIBDVDNAV_VERSION="6.1.1-Next-Nexus-Alpha2-2" -FFMPEG_VERSION="6.0.1" - -# Java bundles from xbmc/interfaces/swig/CMakeLists.txt -GROOVY_VERSION="4.0.16" -APACHE_COMMON_LANG_VERSION="3.14.0" -APACHE_COMMON_TEXT_VERSION="1.11.0" - -_JAVA_PKG_WANT_BUILD_VM=( {openjdk{,-jre},icedtea}{,-bin}-{8,11,17,21} ) -JAVA_PKG_WANT_BUILD_VM=${_JAVA_PKG_WANT_BUILD_VM[@]} -# Required to be set, but not used. -JAVA_PKG_WANT_SOURCE="21" -JAVA_PKG_WANT_TARGET="21" - -PYTHON_REQ_USE="sqlite,ssl" -PYTHON_COMPAT=( python3_{10..12} ) - -# See cmake/scripts/common/ArchSetup.cmake for available options -CPU_FLAGS="cpu_flags_x86_sse cpu_flags_x86_sse2 cpu_flags_x86_sse3 cpu_flags_x86_sse4_1 cpu_flags_x86_sse4_2 cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_arm_neon" - -inherit autotools cmake desktop flag-o-matic java-pkg-2 libtool linux-info optfeature pax-utils python-single-r1 \ - toolchain-funcs xdg - -DESCRIPTION="A free and open source media-player and entertainment hub" -HOMEPAGE="https://kodi.tv/" - -SRC_URI=" - https://github.com/xbmc/libdvdnav/archive/${LIBDVDNAV_VERSION}.tar.gz - -> libdvdnav-${LIBDVDNAV_VERSION}.tar.gz - https://github.com/xbmc/libdvdread/archive/${LIBDVDREAD_VERSION}.tar.gz - -> libdvdread-${LIBDVDREAD_VERSION}.tar.gz - https://mirrors.kodi.tv/build-deps/sources/apache-groovy-binary-${GROOVY_VERSION}.zip - https://mirrors.kodi.tv/build-deps/sources/commons-lang3-${APACHE_COMMON_LANG_VERSION}-bin.tar.gz - https://mirrors.kodi.tv/build-deps/sources/commons-text-${APACHE_COMMON_TEXT_VERSION}-bin.tar.gz - css? ( - https://github.com/xbmc/libdvdcss/archive/${LIBDVDCSS_VERSION}.tar.gz - -> libdvdcss-${LIBDVDCSS_VERSION}.tar.gz - ) - !system-ffmpeg? ( - https://ffmpeg.org/releases/ffmpeg-${FFMPEG_VERSION}.tar.gz - ) -" -if [[ ${PV} == *9999 ]] ; then - EGIT_REPO_URI="https://github.com/xbmc/xbmc.git" - if [[ ${PV} != "9999" ]]; then - EGIT_BRANCH="${CODENAME}" - fi - inherit git-r3 -else - MY_PV=${PV/_p/_r} - MY_PV=${MY_PV/_alpha/a} - MY_PV=${MY_PV/_beta/b} - MY_PV=${MY_PV/_rc/rc} - MY_PV="${MY_PV}-${CODENAME}" - MY_P="${PN}-${MY_PV}" - SRC_URI+=" https://github.com/xbmc/xbmc/archive/${MY_PV}.tar.gz -> ${MY_P}.tar.gz" - KEYWORDS="amd64 ~arm arm64 ~riscv ~x86" - S=${WORKDIR}/xbmc-${MY_PV} -fi - -LICENSE="GPL-2+" -# vendored dependencies -# apache-groovy, common-lang3 and commons-text -LICENSE+=" Apache-2.0" -# libdvdnav, libdvdread and libdvdcss. -LICENSE+=" GPL-2+" -# ffmpeg built as USE="gpl" -LICENSE+=" !system-ffmpeg? ( GPL-2 )" - -SLOT="0" -# use flag is called libusb so that it doesn't fool people in thinking that -# it is _required_ for USB support. Otherwise they'll disable udev and -# that's going to be worse. -IUSE="airplay alsa bluetooth bluray caps cec +css dbus doc eventclients gbm gles lcms libusb lirc mariadb mysql nfs +optical pipewire pulseaudio samba soc +system-ffmpeg test udf udev upnp vaapi vdpau wayland webserver X +xslt zeroconf ${CPU_FLAGS}" -REQUIRED_USE=" - ${PYTHON_REQUIRED_USE} - || ( gbm wayland X ) - ?? ( mariadb mysql ) - bluray? ( udf ) - gbm? ( udev ) - soc? ( system-ffmpeg ) - udev? ( !libusb ) - vdpau? ( X !gles !gbm ) - zeroconf? ( dbus ) -" -RESTRICT="!test? ( test )" - -# dev-libs/libcec[-cubox] bug #818262 -COMMON_DEPEND=" - >=dev-libs/flatbuffers-23.3.3:= - >=dev-libs/lzo-2.04:2 - media-libs/giflib:= - >=media-libs/libjpeg-turbo-2.0.4:= - >=media-libs/libpng-1.6.26:0= - wayland? ( - dev-cpp/waylandpp:= - ) -" -COMMON_TARGET_DEPEND="${PYTHON_DEPS} - >=net-misc/curl-7.68.0[http2] - >=sys-libs/zlib-1.2.11 - dev-db/sqlite:3 - dev-libs/crossguid - >=dev-libs/fribidi-1.0.5 - >=dev-libs/libcdio-2.1.0:=[cxx] - >=dev-libs/libfmt-6.1.2:= - dev-libs/libfstrcmp - dev-libs/libpcre[cxx] - >=dev-libs/openssl-1.1.1k:0= - >=dev-libs/spdlog-1.5.0:= - dev-libs/tinyxml[stl] - dev-libs/tinyxml2:= - media-fonts/roboto - media-libs/libglvnd[X?] - >=media-libs/freetype-2.10.1 - media-libs/harfbuzz:= - >=media-libs/libass-0.15.0:= - media-libs/mesa[egl(+),gbm(+)?,wayland?,X?] - >=media-libs/taglib-1.9.0 - sci-libs/kissfft - virtual/libiconv - virtual/ttf-fonts - x11-libs/libdrm - $(python_gen_cond_dep ' - dev-python/pillow[${PYTHON_USEDEP}] - dev-python/pycryptodome[${PYTHON_USEDEP}] - ') - airplay? ( - >=app-pda/libplist-2.0.0:= - net-libs/shairplay - ) - alsa? ( - >=media-libs/alsa-lib-1.1.4.1 - ) - bluetooth? ( - net-wireless/bluez:= - ) - bluray? ( - >=media-libs/libbluray-1.1.2:= - ) - caps? ( - sys-libs/libcap - ) - cec? ( - >=dev-libs/libcec-4.0[-cubox] - ) - dbus? ( - sys-apps/dbus - ) - gbm? ( - >=dev-libs/libinput-1.10.5:= - media-libs/libdisplay-info - x11-libs/libxkbcommon - ) - gles? ( - || ( - >=media-libs/mesa-24.1.0_rc1[opengl] - =media-libs/lcms-2.10:2 - ) - libusb? ( - virtual/libusb:1 - ) - lirc? ( - app-misc/lirc - ) - mariadb? ( - dev-db/mariadb-connector-c:= - ) - mysql? ( - dev-db/mysql-connector-c:= - ) - nfs? ( - >=net-fs/libnfs-2.0.0:= - ) - pipewire? ( - >=media-video/pipewire-0.3.50:= - ) - pulseaudio? ( - media-libs/libpulse - ) - samba? ( - >=net-fs/samba-3.4.6[smbclient(+)] - ) - system-ffmpeg? ( - =media-video/ffmpeg-6*:=[encode,soc(-)?,postproc,vaapi?,vdpau?,X?] - ) - !system-ffmpeg? ( - app-arch/bzip2 - app-arch/xz-utils - media-libs/dav1d:= - net-libs/gnutls:= - ) - udf? ( - >=dev-libs/libudfread-1.0.0 - ) - udev? ( - virtual/libudev:= - ) - vaapi? ( - media-libs/libva:=[wayland?,X?] - ) - vdpau? ( - || ( - >=x11-libs/libvdpau-1.1 - >=x11-drivers/nvidia-drivers-180.51 - ) - ) - wayland? ( - >=x11-libs/libxkbcommon-0.4.1[wayland] - ) - webserver? ( - >=net-libs/libmicrohttpd-0.9.77:=[messages(+)] - ) - X? ( - x11-libs/libX11 - x11-libs/libXext - x11-libs/libXrandr - ) - xslt? ( - dev-libs/libxslt - >=dev-libs/libxml2-2.9.4 - ) - zeroconf? ( - net-dns/avahi[dbus] - ) -" -RDEPEND=" - ${COMMON_DEPEND} - ${COMMON_TARGET_DEPEND} -" -DEPEND=" - ${COMMON_DEPEND} - ${COMMON_TARGET_DEPEND} - >=dev-libs/rapidjson-1.0.2 - test? ( - >=dev-cpp/gtest-1.10.0 - ) - wayland? ( - >=dev-libs/wayland-protocols-1.7 - ) - X? ( - x11-base/xorg-proto - x11-libs/libXrender - ) -" -BDEPEND=" - ${COMMON_DEPEND} - app-arch/unzip - dev-build/cmake - dev-lang/swig - virtual/pkgconfig - <=virtual/jre-21:* - doc? ( - app-text/doxygen - ) -" - -PATCHES=( - "${FILESDIR}"/kodi-21-optional-ffmpeg-libx11.patch - "${FILESDIR}"/kodi-21.1-silence-libdvdread-git.patch - "${FILESDIR}"/kodi-21.1-fix-gcc15.patch -) - -# bug #544020 -CONFIG_CHECK="~IP_MULTICAST" -ERROR_IP_MULTICAST=" -In some cases Kodi needs to access multicast addresses. -Please consider enabling IP_MULTICAST under Networking options. -" - -pkg_setup() { - check_extra_config - java-pkg-2_pkg_setup - python-single-r1_pkg_setup -} - -src_unpack() { - if [[ ${PV} == *9999 ]] ; then - git-r3_src_unpack - else - unpack ${MY_P}.tar.gz - fi - - unpack apache-groovy-binary-${GROOVY_VERSION}.zip - unpack commons-lang3-${APACHE_COMMON_LANG_VERSION}-bin.tar.gz - unpack commons-text-${APACHE_COMMON_TEXT_VERSION}-bin.tar.gz -} - -src_prepare() { - cmake_src_prepare - - # avoid long delays when powerkit isn't running #348580 - sed -i \ - -e '/dbus_connection_send_with_reply_and_block/s:-1:3000:' \ - xbmc/platform/linux/*.cpp || die - - # Add all possible names for kissfft libraries - for datatype in {float,int16,int32,simd}; do - sed -i \ - -e "s/\(find_library(KISSFFT_LIBRARY NAMES .*\)/\1 kissfft-${datatype} kissfft-${datatype}-openmp/" \ - cmake/modules/FindKissFFT.cmake || die - done - - if tc-is-cross-compiler; then - # These tools are automatically built with CMake during a native build - # but need to be built in advance using Autotools for a cross build. - NATIVE_TOOLS=( - TexturePacker - JsonSchemaBuilder - ) - - local t - for t in "${NATIVE_TOOLS[@]}" ; do - pushd "${S}/tools/depends/native/$t/src" >/dev/null || die - AT_NOELIBTOOLIZE="yes" AT_TOPLEVEL_EAUTORECONF="yes" eautoreconf - popd >/dev/null || die - done - elibtoolize - fi -} - -src_configure() { - local core_platform=( - $(usev gbm) - $(usev wayland) - $(usev X x11) - ) - - local mycmakeargs=( - -Wno-dev # less noise - - -DAPP_RENDER_SYSTEM=$(usex gles gles gl) - -DCORE_PLATFORM_NAME="${core_platform[*]}" - -Ddocdir="${EPREFIX}/usr/share/doc/${PF}" - -DENABLE_TESTING=$(usex test) - -DVERBOSE=ON - - # Enforce use of configured python interpeter - -DPYTHON_PATH=$(python_get_library_path) - -DPYTHON_VER=${EPYTHON##python} # wont work for pypy - - # Toolchain - -DENABLE_CCACHE=OFF - -DENABLE_CLANGFORMAT=OFF - -DENABLE_CLANGTIDY=OFF - -DENABLE_CPPCHECK=OFF - -DENABLE_INCLUDEWHATYOUUSE=OFF - # https://bugs.gentoo.org/show_bug.cgi?id=606124 - -DENABLE_GOLD=OFF - -DENABLE_LLD=OFF - -DENABLE_MOLD=OFF - -DUSE_LTO=OFF - - # Features - -DENABLE_AIRTUNES=$(usex airplay) - -DENABLE_ALSA=$(usex alsa) - -DENABLE_AVAHI=$(usex zeroconf) - -DENABLE_BLUETOOTH=$(usex bluetooth) - -DENABLE_BLURAY=$(usex bluray) - -DENABLE_CAP=$(usex caps) - -DENABLE_CEC=$(usex cec) - -DENABLE_DBUS=$(usex dbus) - -DENABLE_DVDCSS=$(usex css) - -DENABLE_EVENTCLIENTS=ON # alway enable to have 'kodi-send' and filter extra stuff in 'src_install()' - -DENABLE_ISO9660PP=$(usex optical) - -DENABLE_LCMS2=$(usex lcms) - -DENABLE_LIRCCLIENT=$(usex lirc) - -DENABLE_MARIADBCLIENT=$(usex mariadb) - -DENABLE_MDNS=OFF # used only on Android - -DENABLE_MICROHTTPD=$(usex webserver) - -DENABLE_MYSQLCLIENT=$(usex mysql) - -DENABLE_NFS=$(usex nfs) - -DENABLE_OPENGL=$(usex !gles) - -DENABLE_OPENGLES=$(usex gles) - -DENABLE_OPTICAL=$(usex optical) - -DENABLE_PIPEWIRE=$(usex pipewire) - -DENABLE_PLIST=$(usex airplay) - -DENABLE_PULSEAUDIO=$(usex pulseaudio) - -DENABLE_SMBCLIENT=$(usex samba) - -DENABLE_SNDIO=OFF - -DENABLE_UDEV=$(usex udev) - -DENABLE_UDFREAD=$(usex udf) - -DENABLE_UPNP=$(usex upnp) - -DENABLE_VAAPI=$(usex vaapi) - -DENABLE_VDPAU=$(usex vdpau) - -DENABLE_XSLT=$(usex xslt) - - -DWITH_FFMPEG=$(usex system-ffmpeg) - - #To bundle or not - -DENABLE_INTERNAL_CROSSGUID=OFF - -DENABLE_INTERNAL_DAV1D=OFF - -DENABLE_INTERNAL_FFMPEG="$(usex !system-ffmpeg)" - -DENABLE_INTERNAL_FLATBUFFERS=OFF - -DENABLE_INTERNAL_FMT=OFF - -DENABLE_INTERNAL_FSTRCMP=OFF - -DENABLE_INTERNAL_GTEST=OFF - -DENABLE_INTERNAL_KISSFFT=OFF - -DENABLE_INTERNAL_PCRE=OFF - -DENABLE_INTERNAL_RapidJSON=OFF - -DENABLE_INTERNAL_SPDLOG=OFF - -DENABLE_INTERNAL_TAGLIB=OFF - -DENABLE_INTERNAL_UDFREAD=OFF - - -DTARBALL_DIR="${DISTDIR}" - -Dlibdvdnav_URL="${DISTDIR}/libdvdnav-${LIBDVDNAV_VERSION}.tar.gz" - -Dlibdvdread_URL="${DISTDIR}/libdvdread-${LIBDVDREAD_VERSION}.tar.gz" - -Dgroovy_SOURCE_DIR="${WORKDIR}/groovy-${GROOVY_VERSION}" - -Dapache-commons-lang_SOURCE_DIR="${WORKDIR}/commons-lang3-${APACHE_COMMON_LANG_VERSION}" - -Dapache-commons-text_SOURCE_DIR="${WORKDIR}/commons-text-${APACHE_COMMON_TEXT_VERSION}" - ) - - # Separated to avoid "Manually-specified variables were not used by the project:" - use cec && mycmakeargs+=( -DENABLE_INTERNAL_CEC=OFF ) - use css && mycmakeargs+=( -Dlibdvdcss_URL="${DISTDIR}/libdvdcss-${LIBDVDCSS_VERSION}.tar.gz" ) - use nfs && mycmakeargs+=( -DENABLE_INTERNAL_NFS=OFF ) - use !system-ffmpeg && mycmakeargs+=( - -DFFMPEG_URL="${DISTDIR}/ffmpeg-${FFMPEG_VERSION}.tar.gz" - ) - use !udev && mycmakeargs+=( -DENABLE_LIBUSB=$(usex libusb) ) - use X && use !gles && mycmakeargs+=( -DENABLE_GLX=ON ) - - for flag in ${CPU_FLAGS[@]} ; do - local name=${flag#cpu_flags_*_} - mycmakeargs+=( -DENABLE_${name^^}=$(usex ${flag}) ) - done - - if ! is-flag -DNDEBUG && ! is-flag -D_DEBUG ; then - # Kodi requires one of the 'NDEBUG' or '_DEBUG' defines - append-cflags -DNDEBUG - append-cxxflags -DNDEBUG - fi - - # Violates ODR (bug #860984) and USE_LTO does spooky stuff - # https://github.com/xbmc/xbmc/commit/cb72a22d54a91845b1092c295f84eeb48328921e - filter-lto - - if tc-is-cross-compiler; then - for t in "${NATIVE_TOOLS[@]}" ; do - pushd "${S}/tools/depends/native/$t/src" >/dev/null || die - econf_build - install -m0755 /dev/null "$t" || die # Actually build later. - mycmakeargs+=( -DWITH_${t^^}="${PWD}/$t" ) - popd >/dev/null || die - done - fi - - cmake_src_configure -} - -src_compile() { - if tc-is-cross-compiler; then - for t in "${NATIVE_TOOLS[@]}" ; do - emake -C "${S}/tools/depends/native/$t/src" - done - fi - - cmake_src_compile all - use doc && cmake_build doc - use test && cmake_build kodi-test -} - -src_test() { - local -x CMAKE_SKIP_TESTS=( - # Known failing, unreliable test - # bug #743938 - TestCPUInfo.GetCPUFrequency - # Test failure stemming from sci-libs/kissfft - # The difference between output[2i] and (i==freq1?1.0:0.0) is inf, which exceeds 1e-7, where output[2i] - # evaluates to inf,(i==freq1?1.0:0.0) evaluates to 0, and 1e-7 evaluates to 9.9999999999999995e-08. - TestRFFT.SimpleSignal - # Tries to ping localhost, naturally breaking network-sandbox - TestNetwork.PingHost - ) - - if use arm || use x86; then - # bug #779184 - # https://github.com/xbmc/xbmc/issues/18594 - CMAKE_SKIP_TESTS+=( - TestDateTime.Reset - TestDateTime.SetDateTime - TestDateTime.SetFromDBTime - ) - fi - - # see https://github.com/xbmc/xbmc/issues/17860#issuecomment-630120213 - local -x KODI_HOME="${BUILD_DIR}" - - cmake_src_test -} - -src_install() { - cmake_src_install - - # bug #457588 - pax-mark Em "${ED}"/usr/$(get_libdir)/${PN}/${PN}.bin - - newicon media/icon48x48.png kodi.png - - rm "${ED}"/usr/share/kodi/addons/skin.estuary/fonts/Roboto-Thin.ttf || die - dosym ../../../../fonts/roboto/Roboto-Thin.ttf \ - usr/share/kodi/addons/skin.estuary/fonts/Roboto-Thin.ttf - - if use !eventclients ; then - rm -f "${ED}"/usr/bin/kodi-ps3remote || die - rm -f "${D}"$(python_get_sitedir)/kodi/ps3_remote.py || die - rm -rf "${D}"$(python_get_sitedir)/kodi/ps3 || die - rm -rf "${D}"$(python_get_sitedir)/kodi/bt || die - rm -rf "${ED}"/usr/share/doc/${PF}/kodi-eventclients-dev || die - fi - - python_optimize "${D}$(python_get_sitedir)" - - einstalldocs - use doc && dodoc -r "${S}"/docs/html/ -} - -pkg_postinst() { - xdg_pkg_postinst - - if use dbus ; then - optfeature "getting battery level and active power source" sys-power/upower - optfeature "control of shutdown, reboot, suspend, and hibernate" sys-auth/elogind sys-apps/systemd - optfeature "storage management support (automounting, volume monitoring, etc)" sys-fs/udisks:2 - fi -} diff --git a/media-tv/kodi/kodi-21.9999.ebuild b/media-tv/kodi/kodi-21.9999.ebuild index 3e9e0d60425b..199e3b5cbddd 100644 --- a/media-tv/kodi/kodi-21.9999.ebuild +++ b/media-tv/kodi/kodi-21.9999.ebuild @@ -129,7 +129,7 @@ COMMON_TARGET_DEPEND="${PYTHON_DEPS} media-libs/harfbuzz:= >=media-libs/libass-0.15.0:= media-libs/mesa[egl(+),gbm(+)?,wayland?,X?] - >=media-libs/taglib-1.9.0 + media-libs/taglib:= sci-libs/kissfft virtual/libiconv virtual/ttf-fonts diff --git a/media-tv/kodi/kodi-9999.ebuild b/media-tv/kodi/kodi-9999.ebuild index 1b42bd7ce45e..588992248647 100644 --- a/media-tv/kodi/kodi-9999.ebuild +++ b/media-tv/kodi/kodi-9999.ebuild @@ -130,7 +130,7 @@ COMMON_TARGET_DEPEND="${PYTHON_DEPS} media-libs/harfbuzz:= >=media-libs/libass-0.15.0:= media-libs/mesa[egl(+),gbm(+)?,wayland?,X?] - >=media-libs/taglib-1.9.0 + media-libs/taglib:= virtual/libiconv virtual/ttf-fonts x11-libs/libdrm diff --git a/media-tv/mythtv/Manifest b/media-tv/mythtv/Manifest index 7aeac84f00db..88c397df07c6 100644 --- a/media-tv/mythtv/Manifest +++ b/media-tv/mythtv/Manifest @@ -12,5 +12,5 @@ AUX mythtv-33.1-python3.12.patch 11069 BLAKE2B c03b53e15a37cb5236248045f1b8b74b0 AUX mythtv.logrotate.d-r4 235 BLAKE2B 4f6df360f5191aaf4a2b55bd3edc7bc4aab92c46dbd7b7bc1295371b7ef451056f902d92e3209654463850d2cbca579c60d25c1f9065ac80ce3e57fa1fe8e661 SHA512 8dd8936599acabfa55ad7efb870de431e03cb86c3c96156c2c0eee6675962dcc527391260f2ba66e3d54c1d41373001ef25c9d2421e83940c686d14b5f29fff7 AUX xinitrc-r1 234 BLAKE2B 0227ea065f1c43e1b2f1583bcbc798db76e9a08d345bbd8ed8837a6ba424b187c814e3ff0d7690d2d9f7a7617f4fbcce20df926e43bc6e89aec3e352aab6de8f SHA512 885adfe395fe553f6d5cf518856be7be9a6bf6073888f8e055271ed7c3d9ad85a162e9e9ff95a68e54047948ac280796c69ef55d0b4e549eb0beabbf0fec1188 DIST mythtv-33.1.tar.gz 116920982 BLAKE2B bc784a12ee0acf3066d46896343ed15a2f7097364595d20e832da3197eb37c8d05342f82171b66ec842ec48b5829b7ace8c6043835b8de4a04afd8a4df72df1d SHA512 4dc2943915e5e3ca047edc0a005a9e0b58edf7bc51c7fb097a6715bbbb52028260065a7f52f35e4ed98559cc4f4ccca76f1cf6ae68e76b1f2d06a1befd4776e9 -EBUILD mythtv-33.1-r2.ebuild 10587 BLAKE2B 7388ab70760191ad0e24b4438cc35d0e641014b48329411310e96f79af0c2286cd2735c38cac160a2e449788fca4061e4ce7881044806b45f45fde4d1357ddb5 SHA512 506b6ffa494b30819970fe5c68a9ee19b631a44059d5fce549d1c0006866804be722312bbcd186890b540018c483ec1ad67b2794f533b5ee7f51cc63f097a5ba +EBUILD mythtv-33.1-r3.ebuild 10589 BLAKE2B 194d42a3acfb7302be1d872600f2b8b89375d0b99f648f0a9c20ac9b455bab8eaf40018fb46aebfbcc2d2f790614722bf13ac53a1f69086186e6546547eb3266 SHA512 9afe4b106f2cfb16f1c7bb7a230fd3bbe242d87a0259b4d943b021df24e2682d625b4bef54bf7ccaf70a041686e7532213774d56f155bb3872d0df3fa21fb2bb MISC metadata.xml 1983 BLAKE2B 3aad016c2964bbb51e234c8c4c91fa1945837adb30db1445a593f227eb8d1068c78e218bbdfb26591ce34bf61bcb2967653a009f9306602bcb15faeb9152635e SHA512 f369462e9e7b79c22325b3c95560cab83919c598526cd955963c97d5d3fc7764260d98a4565a9a64251119a8cc656f485a96f326881884132a0c29975319f4d7 diff --git a/media-tv/mythtv/mythtv-33.1-r2.ebuild b/media-tv/mythtv/mythtv-33.1-r2.ebuild deleted file mode 100644 index 61c42a783f0d..000000000000 --- a/media-tv/mythtv/mythtv-33.1-r2.ebuild +++ /dev/null @@ -1,386 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DISABLE_AUTOFORMATTING="yes" -PYTHON_COMPAT=( python3_{10..12} ) - -inherit edo flag-o-matic java-pkg-opt-2 python-any-r1 -inherit qmake-utils readme.gentoo-r1 systemd toolchain-funcs user-info - -DESCRIPTION="Open Source DVR and media center hub" -HOMEPAGE="https://www.mythtv.org https://github.com/MythTV/mythtv" -if [[ ${PV} == *_p* ]] ; then - MY_COMMIT="5824c588db24b4e71a7d94e829e6419f71089297" - SRC_URI="https://github.com/MythTV/mythtv/archive/${MY_COMMIT}.tar.gz -> ${P}.tar.gz" - # mythtv and mythplugins are separate builds in the github MythTV project - S="${WORKDIR}/mythtv-${MY_COMMIT}/mythtv" -else - SRC_URI="https://github.com/MythTV/mythtv/archive/v${PV}.tar.gz -> ${P}.tar.gz" - # mythtv and mythplugins are separate builds in the github mythtv project - S="${WORKDIR}/${P}/mythtv" -fi - -LICENSE="GPL-2+" -SLOT="0" -KEYWORDS="~amd64 ~x86" - -IUSE_INPUT_DEVICES="input_devices_joystick" -IUSE_VIDEO_CAPTURE_DEVICES="v4l ieee1394 hdhomerun vbox ceton" -IUSE="alsa asi autostart cdda cdr cec cpu_flags_ppc_altivec debug dvd dvb exif fftw jack java" -IUSE+=" +lame lcd libass lirc nvdec +opengl oss perl pulseaudio python raw systemd vaapi vdpau vpx" -IUSE+=" +wrapper x264 x265 +xml xmltv +xvid +X zeroconf" -IUSE+=" ${IUSE_INPUT_DEVICES} ${IUSE_VIDEO_CAPTURE_DEVICES}" -REQUIRED_USE=" - cdr? ( cdda ) -" - -RDEPEND=" - acct-user/mythtv - dev-libs/glib:2 - dev-libs/lzo - dev-libs/libzip:= - dev-qt/qtcore:5 - dev-qt/qtdbus:5 - dev-qt/qtgui:5[jpeg] - dev-qt/qtnetwork:5 - dev-qt/qtscript:5 - dev-qt/qtsql:5[mysql] - dev-qt/qtwidgets:5 - dev-qt/qtxml:5 - media-fonts/corefonts - media-fonts/dejavu - media-fonts/liberation-fonts - media-fonts/tex-gyre - media-gfx/exiv2:= - media-libs/freetype:2 - media-libs/libbluray:=[java?] - media-libs/libsamplerate - media-libs/libsoundtouch - media-libs/taglib - sys-libs/zlib - alsa? ( media-libs/alsa-lib ) - autostart? ( - net-dialup/mingetty - x11-apps/xset - x11-wm/evilwm - ) - cec? ( dev-libs/libcec ) - dvd? ( - dev-libs/libcdio:= - media-libs/libdvdcss - sys-fs/udisks:2 - ) - fftw? ( sci-libs/fftw:3.0=[threads] ) - hdhomerun? ( media-libs/libhdhomerun ) - ieee1394? ( - media-libs/libiec61883 - sys-libs/libavc1394 - sys-libs/libraw1394 - ) - jack? ( virtual/jack ) - lame? ( media-sound/lame ) - lcd? ( app-misc/lcdproc ) - libass? ( media-libs/libass:= ) - lirc? ( app-misc/lirc ) - nvdec? ( x11-drivers/nvidia-drivers ) - opengl? ( dev-qt/qtopengl:5 ) - pulseaudio? ( media-libs/libpulse ) - systemd? ( sys-apps/systemd:= ) - vaapi? ( media-libs/libva:= ) - vdpau? ( x11-libs/libvdpau ) - vpx? ( media-libs/libvpx:= ) - x264? ( media-libs/x264:= ) - X? ( - x11-apps/xinit - x11-libs/libX11:= - x11-libs/libXext:= - x11-libs/libXinerama:= - x11-libs/libXrandr:= - x11-libs/libXv:= - x11-libs/libXxf86vm:= - x11-misc/wmctrl:= - ) - x265? ( media-libs/x265 ) - xml? ( dev-libs/libxml2:2 ) - xmltv? ( - dev-perl/XML-LibXML - media-tv/xmltv - ) - xvid? ( media-libs/xvid ) - zeroconf? ( - dev-libs/openssl:= - net-dns/avahi[mdnsresponder-compat] - ) -" -DEPEND=" - ${RDEPEND} - dev-lang/yasm - sys-kernel/linux-headers - x11-base/xorg-proto - perl? ( - dev-perl/DBD-mysql - dev-perl/DBI - dev-perl/HTTP-Message - dev-perl/IO-Socket-INET6 - dev-perl/LWP-Protocol-https - dev-perl/Net-UPnP - dev-perl/XML-Simple - ) -" -BDEPEND=" - virtual/pkgconfig - java? ( >=dev-java/ant-1.10.14-r3 ) - opengl? ( virtual/opengl ) - python? ( - ${PYTHON_DEPS} - $(python_gen_any_dep ' - dev-python/python-dateutil[${PYTHON_USEDEP}] - dev-python/lxml[${PYTHON_USEDEP}] - dev-python/mysqlclient[${PYTHON_USEDEP}] - dev-python/requests-cache[${PYTHON_USEDEP}] - ') - ) -" - -PATCHES=( - "${FILESDIR}"/${PN}-33.1-libva.patch - "${FILESDIR}"/${PN}-33.1-ffmpeg-binutils-2.41.patch - "${FILESDIR}"/${PN}-33.1-linux-headers-6.5.patch -) - -python_check_deps() { - use python || return 0 - python_has_version "dev-python/python-dateutil[${PYTHON_USEDEP}]" && - python_has_version "dev-python/lxml[${PYTHON_USEDEP}]" && - python_has_version "dev-python/mysqlclient[${PYTHON_USEDEP}]" && - python_has_version "dev-python/requests-cache[${PYTHON_USEDEP}]" -} - -pkg_setup() { - use python && python-any-r1_pkg_setup -} - -src_prepare() { - default - cat > external/libmythbluray/src/libbluray/bdj/build.properties <<-EOF - java_version_asm=1.8 - java_version_bdj=1.8 - EOF - # https://github.com/MythTV/mythtv/pull/824 - # https://github.com/MythTV/mythtv/pull/838 - # https://bugs.gentoo.org/888291 - eapply -p2 "${FILESDIR}"/${PN}-33.1-python3.12.patch - - # Perl bits need to go into vendor_perl and not site_perl - sed -e "s:pure_install:pure_install INSTALLDIRS=vendor:" \ - -i "${S}"/bindings/perl/Makefile || die "Cannot convert site_perl to vendor_perl!" - -} - -src_configure() { - local -a myconf=() - - # Setup paths - myconf+=( --prefix="${EPREFIX}"/usr ) - myconf+=( --libdir="${EPREFIX}"/usr/$(get_libdir) ) - myconf+=( --libdir-name=$(get_libdir) ) - myconf+=( --mandir="${EPREFIX}"/usr/share/man ) - - if use debug; then - myconf+=( --compile-type=debug ) - myconf+=( --disable-stripping ) # FIXME: does not disable for all files, only for some - myconf+=( --enable-valgrind ) # disables timeouts for valgrind memory debugging - else - myconf+=( --compile-type=release ) - fi - - # Build boosters - has ccache "${FEATURES}" || myconf+=( --disable-ccache ) - has distcc "${FEATURES}" || myconf+=( --disable-distcc ) - - # CPU settings - # Mythtv's configure is borrowed from ffmpeg, - # Bug #172723 - # Try to get cpu type based on CFLAGS. - # We need to do this so that features of that CPU will be better used - # If they contain an unknown CPU it will not hurt since ffmpeg's configure - # will just ignore it. - local i - for i in $(get-flag march) $(get-flag mcpu) $(get-flag mtune) ; do - [[ "${i}" == "native" ]] && i="host" # bug #273421 - myconf+=( --cpu="${i}" ) - break - done - myconf+=( $(use_enable cpu_flags_ppc_altivec altivec) ) - - # Sound Output Support - myconf+=( - $(use_enable oss audio-oss) - - $(use_enable alsa audio-alsa) - $(use_enable jack audio-jack) - $(use_enable pulseaudio audio-pulseoutput) - ) - - # Input Support - myconf+=( - $(use_enable lirc) - $(use_enable input_devices_joystick joystick-menu) - $(use_enable cec libcec) - $(use_enable ieee1394 firewire) - $(use_enable hdhomerun) - $(use_enable vbox) - $(use_enable ceton) - $(use_enable v4l v4l2) - $(use_enable dvb) - $(use_enable asi) - ) - - # Video Output Support - myconf+=( - $(use_enable X x11) - ) - - # Hardware accelerators - myconf+=( - $(use_enable nvdec) - $(use_enable vaapi) - $(use_enable vdpau) - $(use_enable opengl) - $(use_enable opengl egl) - $(use_enable libass) - ) - - # System tools - myconf+=( - $(use_enable systemd systemd_notify) - $(use_enable systemd systemd_journal) - $(use_enable xml libxml2) - $(use_enable zeroconf libdns-sd) - ) - - # Bindings - if use perl && use python; then - myconf+=( --with-bindings=perl,python ) - elif use perl; then - myconf+=( --without-bindings=python ) - myconf+=( --with-bindings=perl ) - elif use python; then - myconf+=( --without-bindings=perl ) - myconf+=( --with-bindings=python ) - else - myconf+=( --without-bindings=perl,python ) - fi - use python && myconf+=( --python="${EPYTHON}" ) - myconf+=( $(use_enable java bdjava) ) - - # External codec library options (used for mythffmpeg and streaming transcode) - # lame is required for some broadcasts for silence detection of commercials - # default enable in IUSE with +lame - myconf+=( - $(use_enable lame libmp3lame) - $(use_enable xvid libxvid) - $(use_enable x264 libx264) - $(use_enable x265 libx265) - $(use_enable vpx libvpx) - ) - - # Clean up DSO load times and other compiler bits - myconf+=( --enable-symbol-visibility ) - myconf+=( --enable-pic ) - - if tc-is-cross-compiler ; then - myconf+=( --enable-cross-compile --arch=$(tc-arch-kernel) ) - myconf+=( --cross-prefix="${CHOST}"- ) - fi - - # econf sets these options that are not handled by configure: - # --build --host --infodir --localstatedir --sysconfdir - - edo ./configure \ - --prefix="${EPREFIX}/usr" \ - --cc="$(tc-getCC)" \ - --cxx="$(tc-getCXX)" \ - --ar="$(tc-getAR)" \ - --optflags="${CFLAGS}" \ - --extra-cflags="${CFLAGS}" \ - --extra-cxxflags="${CXXFLAGS}" \ - --extra-ldflags="${LDFLAGS}" \ - --qmake="$(qt5_get_bindir)"/qmake \ - "${myconf[@]}" -} - -src_install() { - emake STRIP="true" INSTALL_ROOT="${D}" install - use python && python_optimize # does all packages by default - dodoc AUTHORS README - readme.gentoo_create_doc - - insinto /usr/share/mythtv/database - doins database/* - - newinitd "${FILESDIR}"/mythbackend.init-r3 mythbackend - newconfd "${FILESDIR}"/mythbackend.conf-r1 mythbackend - if use systemd; then - systemd_newunit "${FILESDIR}"/mythbackend.service-28 mythbackend.service - fi - - # The acct-user/mythtv package creates/manages the user 'mythtv' - keepdir /etc/mythtv - fowners -R mythtv /etc/mythtv - keepdir /var/log/mythtv - fowners -R mythtv /var/log/mythtv - - insinto /etc/logrotate.d - newins "${FILESDIR}"/mythtv.logrotate.d-r4 mythtv - - insinto /usr/share/mythtv/contrib - # Ensure we don't install scripts needing the perl bindings (bug #516968) Finding none is OK. - if ! use perl; then - find contrib/ -name '*.pl' -exec rm {} \; - fi - # Ensure we don't install scripts needing the python bindings (bug #516968) Finding none is OK. - if ! use python; then - find contrib/ -name '*.py' -exec rm {} \; - fi - doins -r contrib/* - - # Install our mythfrontend wrapper which is similar to Mythbuntu's - if use wrapper; then - mv "${ED}/usr/bin/mythfrontend" "${ED}/usr/bin/mythfrontend.real" || die "Failed to install mythfrontend.real" - newbin "${FILESDIR}"/mythfrontend.wrapper mythfrontend - newconfd "${FILESDIR}"/mythfrontend.conf mythfrontend - fi - - if use autostart; then - newenvd - 95mythtv <<- _EOF_ - CONFIG_PROTECT=\"$(egethome mythtv)\" - _EOF_ - insinto $(egethome mythtv) - newins "${FILESDIR}"/bash_profile .bash_profile - newins "${FILESDIR}"/xinitrc-r1 .xinitrc - fi - - # Make Python files executable but not files named "__init__.py" - find "${ED}/usr/share/mythtv" -type f -name '*.py' -exec expr \( {} : '.*__init__.py' \) = 0 \; \ - -exec chmod a+x {} \; || die "Failed to make python file $(basename ${file}) executable" - - # Ensure that Python scripts are executed by Python 2 - use python && python_fix_shebang "${ED}/usr/share/mythtv" - - # Make shell & perl scripts executable - find "${ED}" -type f \( -name '*.sh' -o -name '*.pl' \) -exec chmod a+x {} \; \ - || die "Failed to make script executable" -} - -pkg_postinst() { - readme.gentoo_print_elog -} - -pkg_config() { - if [[ -e "${EROOT}"/usr/bin/mysql ]]; then - "${EROOT}"/usr/bin/mysql -u root -p < "${EROOT}"/usr/share/mythtv/database/mc.sql - fi -} diff --git a/media-tv/mythtv/mythtv-33.1-r3.ebuild b/media-tv/mythtv/mythtv-33.1-r3.ebuild new file mode 100644 index 000000000000..629b7169ab59 --- /dev/null +++ b/media-tv/mythtv/mythtv-33.1-r3.ebuild @@ -0,0 +1,386 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISABLE_AUTOFORMATTING="yes" +PYTHON_COMPAT=( python3_{10..12} ) + +inherit edo flag-o-matic java-pkg-opt-2 python-any-r1 +inherit qmake-utils readme.gentoo-r1 systemd toolchain-funcs user-info + +DESCRIPTION="Open Source DVR and media center hub" +HOMEPAGE="https://www.mythtv.org https://github.com/MythTV/mythtv" +if [[ ${PV} == *_p* ]] ; then + MY_COMMIT="5824c588db24b4e71a7d94e829e6419f71089297" + SRC_URI="https://github.com/MythTV/mythtv/archive/${MY_COMMIT}.tar.gz -> ${P}.tar.gz" + # mythtv and mythplugins are separate builds in the github MythTV project + S="${WORKDIR}/mythtv-${MY_COMMIT}/mythtv" +else + SRC_URI="https://github.com/MythTV/mythtv/archive/v${PV}.tar.gz -> ${P}.tar.gz" + # mythtv and mythplugins are separate builds in the github mythtv project + S="${WORKDIR}/${P}/mythtv" +fi + +LICENSE="GPL-2+" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +IUSE_INPUT_DEVICES="input_devices_joystick" +IUSE_VIDEO_CAPTURE_DEVICES="v4l ieee1394 hdhomerun vbox ceton" +IUSE="alsa asi autostart cdda cdr cec cpu_flags_ppc_altivec debug dvd dvb exif fftw jack java" +IUSE+=" +lame lcd libass lirc nvdec +opengl oss perl pulseaudio python raw systemd vaapi vdpau vpx" +IUSE+=" +wrapper x264 x265 +xml xmltv +xvid +X zeroconf" +IUSE+=" ${IUSE_INPUT_DEVICES} ${IUSE_VIDEO_CAPTURE_DEVICES}" +REQUIRED_USE=" + cdr? ( cdda ) +" + +RDEPEND=" + acct-user/mythtv + dev-libs/glib:2 + dev-libs/lzo + dev-libs/libzip:= + dev-qt/qtcore:5 + dev-qt/qtdbus:5 + dev-qt/qtgui:5[jpeg] + dev-qt/qtnetwork:5 + dev-qt/qtscript:5 + dev-qt/qtsql:5[mysql] + dev-qt/qtwidgets:5 + dev-qt/qtxml:5 + media-fonts/corefonts + media-fonts/dejavu + media-fonts/liberation-fonts + media-fonts/tex-gyre + media-gfx/exiv2:= + media-libs/freetype:2 + media-libs/libbluray:=[java?] + media-libs/libsamplerate + media-libs/libsoundtouch + media-libs/taglib:= + sys-libs/zlib + alsa? ( media-libs/alsa-lib ) + autostart? ( + net-dialup/mingetty + x11-apps/xset + x11-wm/evilwm + ) + cec? ( dev-libs/libcec ) + dvd? ( + dev-libs/libcdio:= + media-libs/libdvdcss + sys-fs/udisks:2 + ) + fftw? ( sci-libs/fftw:3.0=[threads] ) + hdhomerun? ( media-libs/libhdhomerun ) + ieee1394? ( + media-libs/libiec61883 + sys-libs/libavc1394 + sys-libs/libraw1394 + ) + jack? ( virtual/jack ) + lame? ( media-sound/lame ) + lcd? ( app-misc/lcdproc ) + libass? ( media-libs/libass:= ) + lirc? ( app-misc/lirc ) + nvdec? ( x11-drivers/nvidia-drivers ) + opengl? ( dev-qt/qtopengl:5 ) + pulseaudio? ( media-libs/libpulse ) + systemd? ( sys-apps/systemd:= ) + vaapi? ( media-libs/libva:= ) + vdpau? ( x11-libs/libvdpau ) + vpx? ( media-libs/libvpx:= ) + x264? ( media-libs/x264:= ) + X? ( + x11-apps/xinit + x11-libs/libX11:= + x11-libs/libXext:= + x11-libs/libXinerama:= + x11-libs/libXrandr:= + x11-libs/libXv:= + x11-libs/libXxf86vm:= + x11-misc/wmctrl:= + ) + x265? ( media-libs/x265 ) + xml? ( dev-libs/libxml2:2 ) + xmltv? ( + dev-perl/XML-LibXML + media-tv/xmltv + ) + xvid? ( media-libs/xvid ) + zeroconf? ( + dev-libs/openssl:= + net-dns/avahi[mdnsresponder-compat] + ) +" +DEPEND=" + ${RDEPEND} + dev-lang/yasm + sys-kernel/linux-headers + x11-base/xorg-proto + perl? ( + dev-perl/DBD-mysql + dev-perl/DBI + dev-perl/HTTP-Message + dev-perl/IO-Socket-INET6 + dev-perl/LWP-Protocol-https + dev-perl/Net-UPnP + dev-perl/XML-Simple + ) +" +BDEPEND=" + virtual/pkgconfig + java? ( >=dev-java/ant-1.10.14-r3 ) + opengl? ( virtual/opengl ) + python? ( + ${PYTHON_DEPS} + $(python_gen_any_dep ' + dev-python/python-dateutil[${PYTHON_USEDEP}] + dev-python/lxml[${PYTHON_USEDEP}] + dev-python/mysqlclient[${PYTHON_USEDEP}] + dev-python/requests-cache[${PYTHON_USEDEP}] + ') + ) +" + +PATCHES=( + "${FILESDIR}"/${PN}-33.1-libva.patch + "${FILESDIR}"/${PN}-33.1-ffmpeg-binutils-2.41.patch + "${FILESDIR}"/${PN}-33.1-linux-headers-6.5.patch +) + +python_check_deps() { + use python || return 0 + python_has_version "dev-python/python-dateutil[${PYTHON_USEDEP}]" && + python_has_version "dev-python/lxml[${PYTHON_USEDEP}]" && + python_has_version "dev-python/mysqlclient[${PYTHON_USEDEP}]" && + python_has_version "dev-python/requests-cache[${PYTHON_USEDEP}]" +} + +pkg_setup() { + use python && python-any-r1_pkg_setup +} + +src_prepare() { + default + cat > external/libmythbluray/src/libbluray/bdj/build.properties <<-EOF + java_version_asm=1.8 + java_version_bdj=1.8 + EOF + # https://github.com/MythTV/mythtv/pull/824 + # https://github.com/MythTV/mythtv/pull/838 + # https://bugs.gentoo.org/888291 + eapply -p2 "${FILESDIR}"/${PN}-33.1-python3.12.patch + + # Perl bits need to go into vendor_perl and not site_perl + sed -e "s:pure_install:pure_install INSTALLDIRS=vendor:" \ + -i "${S}"/bindings/perl/Makefile || die "Cannot convert site_perl to vendor_perl!" + +} + +src_configure() { + local -a myconf=() + + # Setup paths + myconf+=( --prefix="${EPREFIX}"/usr ) + myconf+=( --libdir="${EPREFIX}"/usr/$(get_libdir) ) + myconf+=( --libdir-name=$(get_libdir) ) + myconf+=( --mandir="${EPREFIX}"/usr/share/man ) + + if use debug; then + myconf+=( --compile-type=debug ) + myconf+=( --disable-stripping ) # FIXME: does not disable for all files, only for some + myconf+=( --enable-valgrind ) # disables timeouts for valgrind memory debugging + else + myconf+=( --compile-type=release ) + fi + + # Build boosters + has ccache "${FEATURES}" || myconf+=( --disable-ccache ) + has distcc "${FEATURES}" || myconf+=( --disable-distcc ) + + # CPU settings + # Mythtv's configure is borrowed from ffmpeg, + # Bug #172723 + # Try to get cpu type based on CFLAGS. + # We need to do this so that features of that CPU will be better used + # If they contain an unknown CPU it will not hurt since ffmpeg's configure + # will just ignore it. + local i + for i in $(get-flag march) $(get-flag mcpu) $(get-flag mtune) ; do + [[ "${i}" == "native" ]] && i="host" # bug #273421 + myconf+=( --cpu="${i}" ) + break + done + myconf+=( $(use_enable cpu_flags_ppc_altivec altivec) ) + + # Sound Output Support + myconf+=( + $(use_enable oss audio-oss) + + $(use_enable alsa audio-alsa) + $(use_enable jack audio-jack) + $(use_enable pulseaudio audio-pulseoutput) + ) + + # Input Support + myconf+=( + $(use_enable lirc) + $(use_enable input_devices_joystick joystick-menu) + $(use_enable cec libcec) + $(use_enable ieee1394 firewire) + $(use_enable hdhomerun) + $(use_enable vbox) + $(use_enable ceton) + $(use_enable v4l v4l2) + $(use_enable dvb) + $(use_enable asi) + ) + + # Video Output Support + myconf+=( + $(use_enable X x11) + ) + + # Hardware accelerators + myconf+=( + $(use_enable nvdec) + $(use_enable vaapi) + $(use_enable vdpau) + $(use_enable opengl) + $(use_enable opengl egl) + $(use_enable libass) + ) + + # System tools + myconf+=( + $(use_enable systemd systemd_notify) + $(use_enable systemd systemd_journal) + $(use_enable xml libxml2) + $(use_enable zeroconf libdns-sd) + ) + + # Bindings + if use perl && use python; then + myconf+=( --with-bindings=perl,python ) + elif use perl; then + myconf+=( --without-bindings=python ) + myconf+=( --with-bindings=perl ) + elif use python; then + myconf+=( --without-bindings=perl ) + myconf+=( --with-bindings=python ) + else + myconf+=( --without-bindings=perl,python ) + fi + use python && myconf+=( --python="${EPYTHON}" ) + myconf+=( $(use_enable java bdjava) ) + + # External codec library options (used for mythffmpeg and streaming transcode) + # lame is required for some broadcasts for silence detection of commercials + # default enable in IUSE with +lame + myconf+=( + $(use_enable lame libmp3lame) + $(use_enable xvid libxvid) + $(use_enable x264 libx264) + $(use_enable x265 libx265) + $(use_enable vpx libvpx) + ) + + # Clean up DSO load times and other compiler bits + myconf+=( --enable-symbol-visibility ) + myconf+=( --enable-pic ) + + if tc-is-cross-compiler ; then + myconf+=( --enable-cross-compile --arch=$(tc-arch-kernel) ) + myconf+=( --cross-prefix="${CHOST}"- ) + fi + + # econf sets these options that are not handled by configure: + # --build --host --infodir --localstatedir --sysconfdir + + edo ./configure \ + --prefix="${EPREFIX}/usr" \ + --cc="$(tc-getCC)" \ + --cxx="$(tc-getCXX)" \ + --ar="$(tc-getAR)" \ + --optflags="${CFLAGS}" \ + --extra-cflags="${CFLAGS}" \ + --extra-cxxflags="${CXXFLAGS}" \ + --extra-ldflags="${LDFLAGS}" \ + --qmake="$(qt5_get_bindir)"/qmake \ + "${myconf[@]}" +} + +src_install() { + emake STRIP="true" INSTALL_ROOT="${D}" install + use python && python_optimize # does all packages by default + dodoc AUTHORS README + readme.gentoo_create_doc + + insinto /usr/share/mythtv/database + doins database/* + + newinitd "${FILESDIR}"/mythbackend.init-r3 mythbackend + newconfd "${FILESDIR}"/mythbackend.conf-r1 mythbackend + if use systemd; then + systemd_newunit "${FILESDIR}"/mythbackend.service-28 mythbackend.service + fi + + # The acct-user/mythtv package creates/manages the user 'mythtv' + keepdir /etc/mythtv + fowners -R mythtv /etc/mythtv + keepdir /var/log/mythtv + fowners -R mythtv /var/log/mythtv + + insinto /etc/logrotate.d + newins "${FILESDIR}"/mythtv.logrotate.d-r4 mythtv + + insinto /usr/share/mythtv/contrib + # Ensure we don't install scripts needing the perl bindings (bug #516968) Finding none is OK. + if ! use perl; then + find contrib/ -name '*.pl' -exec rm {} \; + fi + # Ensure we don't install scripts needing the python bindings (bug #516968) Finding none is OK. + if ! use python; then + find contrib/ -name '*.py' -exec rm {} \; + fi + doins -r contrib/* + + # Install our mythfrontend wrapper which is similar to Mythbuntu's + if use wrapper; then + mv "${ED}/usr/bin/mythfrontend" "${ED}/usr/bin/mythfrontend.real" || die "Failed to install mythfrontend.real" + newbin "${FILESDIR}"/mythfrontend.wrapper mythfrontend + newconfd "${FILESDIR}"/mythfrontend.conf mythfrontend + fi + + if use autostart; then + newenvd - 95mythtv <<- _EOF_ + CONFIG_PROTECT=\"$(egethome mythtv)\" + _EOF_ + insinto $(egethome mythtv) + newins "${FILESDIR}"/bash_profile .bash_profile + newins "${FILESDIR}"/xinitrc-r1 .xinitrc + fi + + # Make Python files executable but not files named "__init__.py" + find "${ED}/usr/share/mythtv" -type f -name '*.py' -exec expr \( {} : '.*__init__.py' \) = 0 \; \ + -exec chmod a+x {} \; || die "Failed to make python file $(basename ${file}) executable" + + # Ensure that Python scripts are executed by Python 2 + use python && python_fix_shebang "${ED}/usr/share/mythtv" + + # Make shell & perl scripts executable + find "${ED}" -type f \( -name '*.sh' -o -name '*.pl' \) -exec chmod a+x {} \; \ + || die "Failed to make script executable" +} + +pkg_postinst() { + readme.gentoo_print_elog +} + +pkg_config() { + if [[ -e "${EROOT}"/usr/bin/mysql ]]; then + "${EROOT}"/usr/bin/mysql -u root -p < "${EROOT}"/usr/share/mythtv/database/mc.sql + fi +} -- cgit v1.2.3