diff options
author | Martin Väth <martin@mvath.de> | 2021-08-28 20:46:32 +0200 |
---|---|---|
committer | Martin Väth <martin@mvath.de> | 2021-08-28 20:46:32 +0200 |
commit | 433c62b96163d0398869d6dafdba5e5e57170b93 (patch) | |
tree | a19a247a55ed4b9ae8b9c48fb9da91506ea4d3e3 | |
parent | app-text/lesspipe: Version bump (diff) | |
download | mv-433c62b96163d0398869d6dafdba5e5e57170b93.tar.gz mv-433c62b96163d0398869d6dafdba5e5e57170b93.tar.bz2 mv-433c62b96163d0398869d6dafdba5e5e57170b93.zip |
eclass/meson.eclass media-video/pipewire: bump. app-portage/getdelta remove
Signed-off-by: Martin Väth <martin@mvath.de>
-rw-r--r-- | app-portage/getdelta/Manifest | 1 | ||||
-rw-r--r-- | app-portage/getdelta/files/eapi2.patch | 315 | ||||
-rw-r--r-- | app-portage/getdelta/getdelta-0.7.9-r2.ebuild | 45 | ||||
-rw-r--r-- | app-portage/getdelta/metadata.xml | 21 | ||||
-rw-r--r-- | eclass/ChangeLog | 3 | ||||
-rw-r--r-- | eclass/meson.eclass | 280 | ||||
-rw-r--r-- | media-video/pipewire/Manifest | 3 | ||||
-rw-r--r-- | media-video/pipewire/files/pipewire-0.3.33-revert-libfreeaptx-switch.patch | 38 | ||||
-rw-r--r-- | media-video/pipewire/metadata.xml | 7 | ||||
-rw-r--r-- | media-video/pipewire/pipewire-0.3.34.ebuild | 275 | ||||
-rw-r--r-- | metadata/pkg_desc_index | 3 | ||||
-rw-r--r-- | profiles/use.local.desc | 7 |
12 files changed, 528 insertions, 470 deletions
diff --git a/app-portage/getdelta/Manifest b/app-portage/getdelta/Manifest deleted file mode 100644 index dfe42efd..00000000 --- a/app-portage/getdelta/Manifest +++ /dev/null @@ -1 +0,0 @@ -DIST getdelta-0.7.8.tar.bz2 10335 SHA512 66374ce1a0ec5492d11478ddcaeb67b497a44357605f3cd1b9176796ca9f69d8c6865f9db188a6d7722c4ab372a5a317dfa6fafe97d9f08f76f332469f1ee2b2 diff --git a/app-portage/getdelta/files/eapi2.patch b/app-portage/getdelta/files/eapi2.patch deleted file mode 100644 index 5a8ce304..00000000 --- a/app-portage/getdelta/files/eapi2.patch +++ /dev/null @@ -1,315 +0,0 @@ ---- 1/getdelta.sh -+++ 1/getdelta.sh -@@ -25,6 +25,17 @@ - VERSION="0.7" - - # Changelog -+# Changes since 2008 are by Martin V\"ath <martin@mvath.de> -+# version 0.7.12 2010/09/27 -+# - Improve treatment of fetch errors -+# version 0.7.11 2010/09/14 -+# - Support alternative location of make.global and -+# both locations of make.conf -+# version 0.7.10 2010/08/27 -+# - Use alternative to "deltup-queued" file -+# version 0.7.9 2008/10/08 -+# - add second parameter for destination name (EAPI=2) -+# - quote more carefully - # version 0.7.8 2007/07/13 - # - added option -O to call of emerge when finding mirrors - # - replaced some calls of coreutils with bash-internals -@@ -292,6 +303,12 @@ - echo $vser - } - -+GotFile() { -+ [ -n "${1}" ] && test -s "${1}" && { -+ [ "$(head -c5 -- "${1}")" = "sorry" ] || \ -+ [ "$(file -bi -- "${1}" | cut -d"/" -f1)" = "application" ] -+ } -+} - - # some colors for colored output - output() { -@@ -326,13 +343,13 @@ - - remove() { - output "${GREEN}You have chosen to remove ${CYAN}$1\n" -- pushd ${DISTDIR} >/dev/null 2>&1 -+ pushd -- "${DISTDIR}" >/dev/null 2>&1 - removeme=true - for n in $(grep -v "^#" ${DO_NOT_REMOVE}) - do - grep -q $n <<< "$1" && removeme=false && output "${CYAN}${1}${RED} is not deleted, since it matches ${n} in ${DO_NOT_REMOVE}" - done -- $removeme && rm -f $1 -+ $removeme && rm -f -- "$1" - popd >/dev/null 2>&1 - } - -@@ -349,7 +366,7 @@ - -e "s/src4/srcDDD/g" \ - -e "s/src5/srcEEE/g" \ - -e "s/src6/srcFFF/g" \ -- -e "s/src7/srcGGG/g" <<< $MASK_FILENAME) -+ -e "s/src7/srcGGG/g" <<< "$MASK_FILENAME") - fi - - # ignore PR for src-files of firefox -@@ -375,7 +392,7 @@ - -e "s/rc//g" \ - -e "s/[\._-]//g" \ - -e "s/\+//g" \ -- -e "s/ //g" <<< $MASK_FILENAME) -+ -e "s/ //g" <<< "$MASK_FILENAME") - } - - # create or update a config-file -@@ -384,6 +401,7 @@ - add_to_configfile LOCAL_MIRROR "" "set this to one or more (space separated) URI ending with '/' if you want to check one or more local mirror(s) first\n# most people just leave it empty." - add_to_configfile DELTUP_SERVER "http://linux01.gwdg.de/~nlissne/deltup.php" "deltup-server to use" - add_to_configfile FETCH "/usr/bin/wget -t 1 --passive-ftp" "command to use for downloading" -+add_to_configfile FETCHNAME "\$FETCH -O" "command to use for downloading; first parameter is the filename, second the url" - add_to_configfile QUEUERETRY 15 "number of seconds to wait before a queued request is retried" - add_to_configfile MAXIMUM_ACCEPTABLE_QUEUEPOS "15" "the maximum queuepos you would accept (if higher download full archive instead)" - add_to_configfile QUEUETIMEOUT 900 "when a dtu-request is queued - how long should we wait max. before downloading the original archive instead (in seconds)" -@@ -424,21 +442,26 @@ - add_to_donotremove "^rp-pppoe" - - --if [ -z $1 ] -+if [ -z "$1" ] - then - COLOR=true - echo -e "${YELLOW}getdelta.sh version ${VERSION}" - echo "This script has to be called like this:" - echo -e "${CYAN}$0 <URI>" - echo -e "\n${YELLOW}To use it, you should just put the following line into your /etc/make.conf" -- echo -e "${GREEN}FETCHCOMMAND=\"$0 \\\${URI}\"" -+ echo -e "${GREEN}FETCHCOMMAND=\"$0 \\\"\\\${URI}\\\" \\\"\\\${FILE}\\\"\"" - echo -e "\n${YELLOW}There is a config-file ${CYAN}${GETDELTA_CONFIGFILE}${YELLOW} with some variables to control the behaviour of this script." - echo -e "Edit it to your needs.${NORMAL}" - exit 1 - fi - # include variables from gentoo make.globals and make.conf --source /etc/make.globals --source /etc/make.conf -+if test -f /etc/make.globals -+then source /etc/make.globals -+elif test -f /usr/share/portage/config/make.globals -+then source /usr/share/portage/config/make.globals -+fi -+test -f /etc/make.conf && source /etc/make.conf -+test -f /etc/portage/make.conf && source /etc/portage/make.conf - - - if ${COLOR} -@@ -464,9 +487,10 @@ - output "use getdelta.sh for your FETCHCOMMAND, only." && - sleep 5 && exit 1 - --pushd $DISTDIR >/dev/null 2>/dev/null -+pushd -- "$DISTDIR" >/dev/null 2>/dev/null - ORIG_URI=$1 --NEW_FILE=$(basename $ORIG_URI) -+NEW_FILE=$2 -+[ -z "${NEW_FILE}" ] && NEW_FILE=${ORIG_URI##*/} - - # repoman downloads metadata.dtd with FETCHCOMMAND - # this should not be done with getdelta - so just fetch the file and exit -@@ -475,7 +499,7 @@ - # dtu files. - if [ "${NEW_FILE}" = "metadata.dtd" ] || [ "$GETDELTA" = "0" ] - then -- $FETCH $@ -+ $FETCHNAME "$NEW_FILE" "$ORIG_URI" - exit $? - fi - -@@ -516,7 +540,7 @@ - # - output "${GREEN}Searching for a previously downloaded file in ${YELLOW}${DISTDIR}\n" - --first_chars=$(sed 's/[[:digit:]][[:print:]]*$//' <<< $NEW_FILE) -+first_chars=$(sed 's/[[:digit:]][[:print:]]*$//' <<< "$NEW_FILE") - length_first_chars=${#first_chars} - [ $length_first_chars -lt 3 ] && first_chars="${NEW_FILE:0:2}" - -@@ -527,7 +551,7 @@ - let len1=${#mask} - filelist="" - --for name in $( ls ${first_chars}* 2>/dev/null ) -+for name in $( ls -- "${first_chars}"* 2>/dev/null ) - do - mask2=$(mask_name "${name}") - # add any file, that results in the same mask or differ not more than two letters -@@ -582,7 +606,7 @@ - - # find matching part of filename - first: frontmatch - x=0; -- a=($NEW_FILE $filelist) -+ a=("$NEW_FILE" $filelist) - match="" - while [ -z "$match" ] - do -@@ -657,7 +681,7 @@ - FILE_IS_CORRUPT=false - if $CHECK_OLD_FILE - then -- file_digest=$(grep -h ${best_candidate} ${FILESDIR}/digest-* | sed -n 1p) -+ file_digest=$(grep -h ${best_candidate} "${FILESDIR}"/digest-* | sed -n 1p) - if [ "$file_digest" ] - then - file_md5=$(cut -d ' ' -f2 <<< "$file_digest") -@@ -669,7 +693,7 @@ - FILE_IS_CORRUPT=true - fi - else -- if [ $(rev <<< ${best_candidate} | cut -d. -f2 | rev) = "tar" ] -+ if [ $(rev <<< "${best_candidate}" | cut -d. -f2 | rev) = "tar" ] - then - output "${YELLOW}Could not find a digest-file for ${CYAN}${best_candidate}${YELLOW}. Testing file integrity with tar.\n" - if ! tar -tf ${best_candidate} >/dev/null -@@ -694,21 +718,23 @@ - sed -e "s/ /\\n/g" | egrep "(http|ftp)://" | - grep "${NEW_FILE}" | tail -n 1) - query="?have=${best_candidate}&want=${NEW_FILE}&url=${QUERY_URL}&version=${VERSION}&time=$(date +%s)" -- output "${GREEN}Trying to download ${YELLOW}${best_candidate}-${NEW_FILE}.dtu\n" -+ dtubase="${best_candidate}-${NEW_FILE}" -+ dtufile="${dtubase}.dtu" -+ output "${GREEN}Trying to download ${YELLOW}${dtufile}\n" - - # Remember where we are, and go to a new dir there we can work - tmp_dwn_dest="${DISTDIR}/.getdelta-`date +%N`-tmp" -- mkdir ${tmp_dwn_dest} -+ mkdir -- "${tmp_dwn_dest}" - # If user abort Ctrl+C (signal 2), remove tmp-dir; enabable trap again and send it again to stop wget -- trap "rm -r ${tmp_dwn_dest}; trap 2; kill -2 $$" 2 -- pushd ${tmp_dwn_dest} >/dev/null 2>&1 -+ trap 'rm -r -- "${tmp_dwn_dest}"; trap 2; kill -2 '$$ 2 -+ pushd -- "${tmp_dwn_dest}" >/dev/null 2>&1 - - # thanks to MATSUI Fe2+ Tetsushi for idea and patch - FILESIZE=$(stat -c %s "${DISTDIR}/${best_candidate}") - let TIMELIMIT=${FILESIZE}/${BANDWIDTH} - [[ $TIMELIMIT -lt $QUEUETIMEOUT ]] && QUEUETIMEOUT=$TIMELIMIT - -- if $FETCH "${DELTUP_SERVER}${query}" -+ if $FETCHNAME "${dtufile}" "${DELTUP_SERVER}${query}" - then - # thanks to deelkar for this much more elegant solution to the "broken pipe" problem with "head -n1" - GOTFILE=$(ls -c | sed -n 1p) -@@ -718,14 +744,14 @@ - # may have sento to us. - - # first: the request have been queued -- if [ "${GOTFILE}" = "deltup-queued" ] -+ if [ "${GOTFILE}" = "deltup-queued" ] || ! GotFile "${GOTFILE}" - then - let QTMOUT=$(date +%s)+QUEUETIMEOUT -- while [ -f deltup-queued ] -+ while [ -f deltup-queued ] || ! GotFile "${GOTFILE}" - do - output "${GREEN}destination file: ${CYAN}${NEW_FILE}\n" -- output "${YELLOW}$(cat deltup-queued)" -- QUEUEPOS=$(grep "has been queued" deltup-queued | cut -d. -f2 | cut -d")" -f1) -+ output "${YELLOW}$(cat -- "${GOTFILE}")" -+ QUEUEPOS=$(grep "has been queued" -- "${GOTFILE}" | cut -d. -f2 | cut -d")" -f1) - rm -f deltup-queued - TSTAMP=$(date +%s) - if ((TSTAMP<QTMOUT)) && ((QUEUEPOS<=MAXIMUM_ACCEPTABLE_QUEUEPOS)) -@@ -741,18 +767,18 @@ - sleep 1 - done - echo -n -e "${NORMAL}" -- $FETCH "${DELTUP_SERVER}${query}" -+ $FETCHNAME "${dtufile}" "${DELTUP_SERVER}${query}" - GOTFILE=$(ls -c | sed -n 1p) - else - if ((TSTAMP>=QTMOUT)) - then -- GOTFILE="timeout" -+ GOTFILE='' - output "\n${RED}TIMEOUT exceeded.\n" - break - fi - if ((QUEUEPOS>MAXIMUM_ACCEPTABLE_QUEUEPOS)) - then -- GOTFILE="unacceptable" -+ GOTFILE='' - output "\n${RED}You have configured getdelta.sh not to accept this queue-position.\n" - output "${YELLOW}We are going to download the ${RED}full archive${YELLOW} instead.\n" - break -@@ -761,21 +787,31 @@ - done - fi - -- if [ -f ${best_candidate}-${NEW_FILE}.failed ] -+ [ -n "${GOTFILE}" ] && test -f "${GOTFILE}" || GOTFILE="" -+ newfile_failed="${dtubase}.failed" -+ test -f "${newfile_failed}" || newfile_failed="" -+ if [ -n "${newfile_failed}" ] || { -+ [ -n "${GOTFILE}" ] && [ "$(head -c5 -- "${GOTFILE}")" = "sorry" ] -+ } - then - output "\n${RED}The server could not build the dtu-file for ${NEW_FILE}\n" -- output "${YELLOW}reason:\n${RED}$(cat ${best_candidate}-${NEW_FILE}.failed)\n" -- rm -rf ${best_candidate}-${NEW_FILE}.failed -+ output "${YELLOW}reason:\n${RED}$( -+ [ -n "${newfile_failed}" ] && cat -- "${newfile_failed}" -+ [ -n "${GOTFILE}" ] && cat -- "${GOTFILE}")\n" -+ rm -f -- "${newfile_failed}" "${GOTFILE}" - fi - -- if [ -f ${best_candidate}-${NEW_FILE}.dtu ] -+ [ -n "${dtufile}" ] && test -f "${dtufile}" || dtufile="" -+ if test -f "${dtufile}" - then - output "${GREEN}Successfully fetched the dtu-file - let's build ${NEW_FILE}...\n" -- downloadsize=$(stat -c %s ${best_candidate}-${NEW_FILE}.dtu) -- if deltup -p -v -D ${DISTDIR} ${best_candidate}-${NEW_FILE}.dtu -+ downloadsize=$(stat -c %s -- "${dtufile}") -+ if deltup -p -v -D "${DISTDIR}" "${dtufile}" - then -- newsize=$(stat -c %s ${NEW_FILE}) -+ newsize=$(stat -c %s -- "${NEW_FILE}") -+ : ${newsize:=0} - let savedsize=${newsize}-${downloadsize} -+ [ ${newsize} -eq 0 ] && percent=-100 || \ - let percent=${savedsize}*100/${newsize} - unit="bytes" - [ $savedsize -gt 1024 ] && let savedsize=$savedsize/1024 && unit="kB" -@@ -791,8 +827,8 @@ - esac - output "${YELLOW}This dtu-file saved ${UCOLOR}${savedsize} ${unit} (${percent}%)${YELLOW} download size.\n" - fi -- mv -f ${NEW_FILE} ${DISTDIR} && -- ${REMOVE_OLD} && remove "${best_candidate}" -+ mv -f -- "${NEW_FILE}" "${DISTDIR}" && -+ ${REMOVE_OLD} && remove ${best_candidate} - fi - - fi # if $FETCH "${DELTUP_SERVER}${query}" -@@ -812,7 +848,7 @@ - read - fi - popd >/dev/null 2>&1 -- rm -rf ${tmp_dwn_dest} -+ rm -rf -- "${tmp_dwn_dest}" - #stop respond to trap2 - trap 2 - fi # if ! FILE_IS_CORRUPT -@@ -824,10 +860,10 @@ - - # Ok, once we are here, we should have got the delta (and used it) - # or we still have to download the full file --if ! [ -f ${DISTDIR}/${NEW_FILE} ] -+if ! [ -f "${DISTDIR}/${NEW_FILE}" ] - then - output "${RED}The dtu could not be fetched,${YELLOW} downloading full file from original URL\n" -- $FETCH $ORIG_URI -+ $FETCHNAME "$NEW_FILE" "$ORIG_URI" - # remember we had a fallback to use correct exitcode for portage - FALLBACK=$? - fi diff --git a/app-portage/getdelta/getdelta-0.7.9-r2.ebuild b/app-portage/getdelta/getdelta-0.7.9-r2.ebuild deleted file mode 100644 index 8d81a2e9..00000000 --- a/app-portage/getdelta/getdelta-0.7.9-r2.ebuild +++ /dev/null @@ -1,45 +0,0 @@ -# Copyright 1999-2018 Martin V\"ath and others -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 -inherit readme.gentoo-r1 - -DESCRIPTION="dynamic deltup client" -HOMEPAGE="http://linux01.gwdg.de/~nlissne/" -SRC_URI="http://linux01.gwdg.de/~nlissne/${PN}-0.7.8.tar.bz2" -SLOT="0" -IUSE="" -LICENSE="GPL-2" -KEYWORDS="~alpha ~amd64 ~sparc ~x86" -S="${WORKDIR}" - -RDEPEND="app-portage/deltup - dev-util/bdelta" - -src_prepare() { - eapply "${FILESDIR}/eapi2.patch" - sed -i -e "s:/bin/sh:/bin/bash:" getdelta.sh || die - default -} - -src_install() { - local DISABLE_AUTOFORMATTING DOC_CONTENTS - dobin "${WORKDIR}"/getdelta.sh - DISABLE_AUTOFORMATTING="true" - DOC_CONTENTS="You need to put -FETCHCOMMAND=\"/usr/bin/getdelta.sh \\\"\\\${URI}\\\" \\\"\\\${FILE}\\\"\" -into your /etc/make.conf to make use of getdelta" - readme.gentoo_create_doc -} - -pkg_postinst() { - local a b - # make sure permissions are ok - a="${EROOT}"/var/log/getdelta.log - b="${EROOT}"/etc/deltup - test -f "${a}" || touch -- "${a}" - mkdir -p -- "${b}" - use prefix || chown -R portage:portage -- "${a}" "${b}" - chmod -R ug+rwX -- "${a}" "${b}" - readme.gentoo_print_elog -} diff --git a/app-portage/getdelta/metadata.xml b/app-portage/getdelta/metadata.xml deleted file mode 100644 index 9550c8c1..00000000 --- a/app-portage/getdelta/metadata.xml +++ /dev/null @@ -1,21 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> -<pkgmetadata> - <maintainer type="person"> - <email>martin@mvath.de</email> - <name>Martin Väth</name> - <description>maintainer of the updates in the mv overlay</description> - </maintainer> - <maintainer type="person"> - <email>patrick@gentoo.org</email> - <name>Patrick Lauer</name> - </maintainer> - <maintainer type="person"> - <email>nlissne@linux01.gwdg.de</email> - <name>Nicolai Lissner</name> - </maintainer> -<maintainer type="project"> - <email>proxy-maint@gentoo.org</email> - <name>Proxy Maintainers</name> - </maintainer> -</pkgmetadata> diff --git a/eclass/ChangeLog b/eclass/ChangeLog index 4ff3f1a4..74c9cbb6 100644 --- a/eclass/ChangeLog +++ b/eclass/ChangeLog @@ -88,3 +88,6 @@ 12 Aug 2018; Martin Väth <martin@mvath.de>: Add @SUPPORTED_EAPIS + + 28 Aug 2021; Martin Väth <martin@mvath.de>: + Update meson eclass diff --git a/eclass/meson.eclass b/eclass/meson.eclass index 501be73a..4cca2fd1 100644 --- a/eclass/meson.eclass +++ b/eclass/meson.eclass @@ -1,11 +1,11 @@ -# Copyright 2017-2020 Gentoo Authors +# Copyright 2017-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 # @ECLASS: meson.eclass # @MAINTAINER: # William Hubbs <williamh@gentoo.org> # Mike Gilbert <floppym@gentoo.org> -# @SUPPORTED_EAPIS: 6 7 +# @SUPPORTED_EAPIS: 6 7 8 # @BLURB: common ebuild functions for meson-based packages # @DESCRIPTION: # This eclass contains the default phase functions for packages which @@ -15,7 +15,7 @@ # Typical ebuild using meson.eclass: # # @CODE -# EAPI=6 +# EAPI=8 # # inherit meson # @@ -23,9 +23,9 @@ # # src_configure() { # local emesonargs=( -# -Dqt4=$(usex qt4 true false) -# -Dthreads=$(usex threads true false) -# -Dtiff=$(usex tiff true false) +# $(meson_use qt5) +# $(meson_feature threads) +# $(meson_use bindist official_branding) # ) # meson_src_configure # } @@ -34,11 +34,6 @@ # # @CODE -case ${EAPI:-0} in - 6|7) ;; - *) die "EAPI=${EAPI} is not supported" ;; -esac - if [[ ${__MESON_AUTO_DEPEND+set} == "set" ]] ; then # See if we were included already, but someone changed the value # of MESON_AUTO_DEPEND on us. We could reload the entire @@ -50,18 +45,17 @@ if [[ ${__MESON_AUTO_DEPEND+set} == "set" ]] ; then fi if [[ -z ${_MESON_ECLASS} ]]; then +_MESON_ECLASS=1 +[[ ${EAPI} == 6 ]] && inherit eapi7-ver inherit multiprocessing ninja-utils python-utils-r1 toolchain-funcs -fi - EXPORT_FUNCTIONS src_configure src_compile src_test src_install -if [[ -z ${_MESON_ECLASS} ]]; then -_MESON_ECLASS=1 - -MESON_DEPEND=">=dev-util/meson-0.51.2 - >=dev-util/ninja-1.8.2" +_MESON_DEPEND=">=dev-util/meson-0.56.0 + >=dev-util/ninja-1.8.2 + dev-util/meson-format-array +" # @ECLASS-VARIABLE: MESON_AUTO_DEPEND # @DESCRIPTION: @@ -71,9 +65,9 @@ MESON_DEPEND=">=dev-util/meson-0.51.2 : ${MESON_AUTO_DEPEND:=yes} if [[ ${MESON_AUTO_DEPEND} != "no" ]] ; then if [[ ${EAPI:-0} == [0123456] ]]; then - DEPEND=${MESON_DEPEND} + DEPEND=${_MESON_DEPEND} else - BDEPEND=${MESON_DEPEND} + BDEPEND=${_MESON_DEPEND} fi fi __MESON_AUTO_DEPEND=${MESON_AUTO_DEPEND} # See top of eclass @@ -97,25 +91,11 @@ __MESON_AUTO_DEPEND=${MESON_AUTO_DEPEND} # See top of eclass # Optional meson arguments as Bash array; this should be defined before # calling meson_src_configure. -# @VARIABLE: emesontestargs +# @VARIABLE: MYMESONARGS # @DEFAULT_UNSET # @DESCRIPTION: -# Optional meson test arguments as Bash array; this should be defined before -# calling meson_src_test. - - -read -d '' __MESON_ARRAY_PARSER <<"EOF" -import shlex -import sys - -# See http://mesonbuild.com/Syntax.html#strings -def quote(str): - escaped = str.replace("\\\\", "\\\\\\\\").replace("'", "\\\\'") - return "'{}'".format(escaped) - -print("[{}]".format( - ", ".join([quote(x) for x in shlex.split(" ".join(sys.argv[1:]))]))) -EOF +# User-controlled environment variable containing arguments to be passed to +# meson in meson_src_configure. # @FUNCTION: _meson_env_array # @INTERNAL @@ -136,20 +116,20 @@ EOF # '--unicode-16=𐐷', '--unicode-32=𐤅'] # _meson_env_array() { - python -c "${__MESON_ARRAY_PARSER}" "$@" + meson-format-array "$@" } -# @FUNCTION: _meson_create_cross_file +# @FUNCTION: _meson_get_machine_info +# @USAGE: <tuple> +# @RETURN: system/cpu_family/cpu variables # @INTERNAL # @DESCRIPTION: -# Creates a cross file. meson uses this to define settings for -# cross-compilers. This function is called from meson_src_configure. -_meson_create_cross_file() { - # Reference: http://mesonbuild.com/Cross-compilation.html +# Translate toolchain tuple into machine values for meson. +_meson_get_machine_info() { + local tuple=$1 # system roughly corresponds to uname -s (lowercase) - local system=unknown - case ${CHOST} in + case ${tuple} in *-aix*) system=aix ;; *-cygwin*) system=cygwin ;; *-darwin*) system=darwin ;; @@ -159,29 +139,49 @@ _meson_create_cross_file() { *-solaris*) system=sunos ;; esac - local cpu_family=$(tc-arch) + cpu_family=$(tc-arch "${tuple}") case ${cpu_family} in amd64) cpu_family=x86_64 ;; arm64) cpu_family=aarch64 ;; + riscv) + case ${tuple} in + riscv32*) cpu_family=riscv32 ;; + riscv64*) cpu_family=riscv64 ;; + esac ;; esac # This may require adjustment based on CFLAGS - local cpu=${CHOST%%-*} + cpu=${tuple%%-*} +} + +# @FUNCTION: _meson_create_cross_file +# @RETURN: path to cross file +# @INTERNAL +# @DESCRIPTION: +# Creates a cross file. meson uses this to define settings for +# cross-compilers. This function is called from meson_src_configure. +_meson_create_cross_file() { + local system cpu_family cpu + _meson_get_machine_info "${CHOST}" + + local fn=${T}/meson.${CHOST}.${ABI}.ini - cat > "${T}/meson.${CHOST}.${ABI}" <<-EOF + cat > "${fn}" <<-EOF [binaries] ar = $(_meson_env_array "$(tc-getAR)") c = $(_meson_env_array "$(tc-getCC)") cpp = $(_meson_env_array "$(tc-getCXX)") fortran = $(_meson_env_array "$(tc-getFC)") llvm-config = '$(tc-getPROG LLVM_CONFIG llvm-config)' + nm = $(_meson_env_array "$(tc-getNM)") objc = $(_meson_env_array "$(tc-getPROG OBJC cc)") + objcopy = $(_meson_env_array "$(tc-getOBJCOPY)") objcpp = $(_meson_env_array "$(tc-getPROG OBJCXX c++)") pkgconfig = '$(tc-getPKG_CONFIG)' strip = $(_meson_env_array "$(tc-getSTRIP)") windres = $(_meson_env_array "$(tc-getRC)") - [properties] + [built-in options] c_args = $(_meson_env_array "${CFLAGS} ${CPPFLAGS}") c_link_args = $(_meson_env_array "${CFLAGS} ${LDFLAGS}") cpp_args = $(_meson_env_array "${CXXFLAGS} ${CPPFLAGS}") @@ -193,12 +193,72 @@ _meson_create_cross_file() { objcpp_args = $(_meson_env_array "${OBJCXXFLAGS} ${CPPFLAGS}") objcpp_link_args = $(_meson_env_array "${OBJCXXFLAGS} ${LDFLAGS}") + [properties] + needs_exe_wrapper = true + sys_root = '${SYSROOT}' + pkg_config_libdir = '${PKG_CONFIG_LIBDIR:-${EPREFIX}/usr/$(get_libdir)/pkgconfig}' + [host_machine] system = '${system}' cpu_family = '${cpu_family}' cpu = '${cpu}' - endian = '$(tc-endian)' + endian = '$(tc-endian "${CHOST}")' + EOF + + echo "${fn}" +} + +# @FUNCTION: _meson_create_native_file +# @RETURN: path to native file +# @INTERNAL +# @DESCRIPTION: +# Creates a native file. meson uses this to define settings for +# native compilers. This function is called from meson_src_configure. +_meson_create_native_file() { + local system cpu_family cpu + _meson_get_machine_info "${CBUILD}" + + local fn=${T}/meson.${CBUILD}.${ABI}.ini + + cat > "${fn}" <<-EOF + [binaries] + ar = $(_meson_env_array "$(tc-getBUILD_AR)") + c = $(_meson_env_array "$(tc-getBUILD_CC)") + cpp = $(_meson_env_array "$(tc-getBUILD_CXX)") + fortran = $(_meson_env_array "$(tc-getBUILD_PROG FC gfortran)") + llvm-config = '$(tc-getBUILD_PROG LLVM_CONFIG llvm-config)' + nm = $(_meson_env_array "$(tc-getBUILD_NM)") + objc = $(_meson_env_array "$(tc-getBUILD_PROG OBJC cc)") + objcopy = $(_meson_env_array "$(tc-getBUILD_OBJCOPY)") + objcpp = $(_meson_env_array "$(tc-getBUILD_PROG OBJCXX c++)") + pkgconfig = '$(tc-getBUILD_PKG_CONFIG)' + strip = $(_meson_env_array "$(tc-getBUILD_STRIP)") + windres = $(_meson_env_array "$(tc-getBUILD_PROG RC windres)") + + [built-in options] + c_args = $(_meson_env_array "${BUILD_CFLAGS} ${BUILD_CPPFLAGS}") + c_link_args = $(_meson_env_array "${BUILD_CFLAGS} ${BUILD_LDFLAGS}") + cpp_args = $(_meson_env_array "${BUILD_CXXFLAGS} ${BUILD_CPPFLAGS}") + cpp_link_args = $(_meson_env_array "${BUILD_CXXFLAGS} ${BUILD_LDFLAGS}") + fortran_args = $(_meson_env_array "${BUILD_FCFLAGS}") + fortran_link_args = $(_meson_env_array "${BUILD_FCFLAGS} ${BUILD_LDFLAGS}") + objc_args = $(_meson_env_array "${BUILD_OBJCFLAGS} ${BUILD_CPPFLAGS}") + objc_link_args = $(_meson_env_array "${BUILD_OBJCFLAGS} ${BUILD_LDFLAGS}") + objcpp_args = $(_meson_env_array "${BUILD_OBJCXXFLAGS} ${BUILD_CPPFLAGS}") + objcpp_link_args = $(_meson_env_array "${BUILD_OBJCXXFLAGS} ${BUILD_LDFLAGS}") + + [properties] + needs_exe_wrapper = false + pkg_config_libdir = '${BUILD_PKG_CONFIG_LIBDIR:-${EPREFIX}/usr/$(get_libdir)/pkgconfig}' + + [build_machine] + system = '${system}' + cpu_family = '${cpu_family}' + cpu = '${cpu}' + endian = '$(tc-endian "${CBUILD}")' EOF + + echo "${fn}" } # @FUNCTION: meson_use @@ -234,32 +294,90 @@ meson_feature() { meson_src_configure() { debug-print-function ${FUNCNAME} "$@" - # Common args + local BUILD_CFLAGS=${BUILD_CFLAGS} + local BUILD_CPPFLAGS=${BUILD_CPPFLAGS} + local BUILD_CXXFLAGS=${BUILD_CXXFLAGS} + local BUILD_FCFLAGS=${BUILD_FCFLAGS} + local BUILD_OBJCFLAGS=${BUILD_OBJCFLAGS} + local BUILD_OBJCXXFLAGS=${BUILD_OBJCXXFLAGS} + local BUILD_LDFLAGS=${BUILD_LDFLAGS} + local BUILD_PKG_CONFIG_LIBDIR=${BUILD_PKG_CONFIG_LIBDIR} + local BUILD_PKG_CONFIG_PATH=${BUILD_PKG_CONFIG_PATH} + + if tc-is-cross-compiler; then + : ${BUILD_CFLAGS:=-O1 -pipe} + : ${BUILD_CXXFLAGS:=-O1 -pipe} + : ${BUILD_FCFLAGS:=-O1 -pipe} + : ${BUILD_OBJCFLAGS:=-O1 -pipe} + : ${BUILD_OBJCXXFLAGS:=-O1 -pipe} + else + : ${BUILD_CFLAGS:=${CFLAGS}} + : ${BUILD_CPPFLAGS:=${CPPFLAGS}} + : ${BUILD_CXXFLAGS:=${CXXFLAGS}} + : ${BUILD_FCFLAGS:=${FCFLAGS}} + : ${BUILD_LDFLAGS:=${LDFLAGS}} + : ${BUILD_OBJCFLAGS:=${OBJCFLAGS}} + : ${BUILD_OBJCXXFLAGS:=${OBJCXXFLAGS}} + : ${BUILD_PKG_CONFIG_LIBDIR:=${PKG_CONFIG_LIBDIR}} + : ${BUILD_PKG_CONFIG_PATH:=${PKG_CONFIG_PATH}} + fi + local mesonargs=( + meson setup --buildtype plain --libdir "$(get_libdir)" --localstatedir "${EPREFIX}/var/lib" --prefix "${EPREFIX}/usr" --sysconfdir "${EPREFIX}/etc" --wrap-mode nodownload - ) + --build.pkg-config-path "${BUILD_PKG_CONFIG_PATH}${BUILD_PKG_CONFIG_PATH:+:}${EPREFIX}/usr/share/pkgconfig" + --pkg-config-path "${PKG_CONFIG_PATH}${PKG_CONFIG_PATH:+:}${EPREFIX}/usr/share/pkgconfig" + --native-file "$(_meson_create_native_file)" + ) - if tc-is-cross-compiler || [[ ${ABI} != ${DEFAULT_ABI-${ABI}} ]]; then - _meson_create_cross_file || die "unable to write meson cross file" - mesonargs+=( --cross-file "${T}/meson.${CHOST}.${ABI}" ) + if tc-is-cross-compiler; then + mesonargs+=( --cross-file "$(_meson_create_cross_file)" ) fi + BUILD_DIR="${BUILD_DIR:-${WORKDIR}/${P}-build}" + + # Handle quoted whitespace + eval "local -a MYMESONARGS=( ${MYMESONARGS} )" + + mesonargs+=( + # Arguments from ebuild + "${emesonargs[@]}" + + # Arguments passed to this function + "$@" + + # Arguments from user + "${MYMESONARGS[@]}" + + # Source directory + "${EMESON_SOURCE:-${S}}" + + # Build directory + "${BUILD_DIR}" + ) + + # Used by symbolextractor.py + # https://bugs.gentoo.org/717720 + tc-export NM + tc-getPROG READELF readelf >/dev/null + # https://bugs.gentoo.org/625396 python_export_utf8_locale - # Append additional arguments from ebuild - mesonargs+=("${emesonargs[@]}") + # https://bugs.gentoo.org/721786 + local -x BOOST_INCLUDEDIR="${BOOST_INCLUDEDIR-${EPREFIX}/usr/include}" + local -x BOOST_LIBRARYDIR="${BOOST_LIBRARYDIR-${EPREFIX}/usr/$(get_libdir)}" - BUILD_DIR="${BUILD_DIR:-${WORKDIR}/${P}-build}" - set -- meson "${mesonargs[@]}" "$@" \ - "${EMESON_SOURCE:-${S}}" "${BUILD_DIR}" - echo "$@" - tc-env_build "$@" || die + ( + export -n {C,CPP,CXX,F,OBJC,OBJCXX,LD}FLAGS PKG_CONFIG_{LIBDIR,PATH} + echo "${mesonargs[@]}" >&2 + "${mesonargs[@]}" + ) || die } # @FUNCTION: meson_src_compile @@ -269,7 +387,17 @@ meson_src_configure() { meson_src_compile() { debug-print-function ${FUNCNAME} "$@" - eninja -C "${BUILD_DIR}" "$@" + local mesoncompileargs=( + -C "${BUILD_DIR}" + --jobs "$(makeopts_jobs "${MAKEOPTS}" 0)" + --load-average "$(makeopts_loadavg "${MAKEOPTS}" 0)" + --verbose + "$@" + ) + + set -- meson compile "${mesoncompileargs[@]}" + echo "$@" >&2 + "$@" || die "compile failed" } # @FUNCTION: meson_src_test @@ -281,29 +409,35 @@ meson_src_test() { local mesontestargs=( -C "${BUILD_DIR}" + --num-processes "$(makeopts_jobs "${MAKEOPTS}")" + "$@" ) - [[ -n ${NINJAOPTS} || -n ${MAKEOPTS} ]] && - mesontestargs+=( - --num-processes "$(makeopts_jobs ${NINJAOPTS:-${MAKEOPTS}})" - ) - # Append additional arguments from ebuild - mesontestargs+=("${emesontestargs[@]}") - - set -- meson test "${mesontestargs[@]}" "$@" + set -- meson test "${mesontestargs[@]}" echo "$@" >&2 "$@" || die "tests failed" } # @FUNCTION: meson_src_install -# @USAGE: [extra ninja install arguments] +# @USAGE: [extra meson install arguments] # @DESCRIPTION: # This is the meson_src_install function. meson_src_install() { debug-print-function ${FUNCNAME} "$@" - DESTDIR="${D}" eninja -C "${BUILD_DIR}" install "$@" + local mesoninstallargs=( + -C "${BUILD_DIR}" + --destdir "${D}" + "$@" + ) + + set -- meson install "${mesoninstallargs[@]}" + echo "$@" >&2 + "$@" || die "install failed" + + pushd "${S}" > /dev/null || die einstalldocs + popd > /dev/null || die } fi diff --git a/media-video/pipewire/Manifest b/media-video/pipewire/Manifest index f9fd7cea..02193826 100644 --- a/media-video/pipewire/Manifest +++ b/media-video/pipewire/Manifest @@ -1 +1,2 @@ -DIST pipewire-0.3.32.tar.gz 1604622 BLAKE2B cab83a17a2b27f710e1377a2ad2ad7003053ef3e8b55423362f0b428e22d52c2ce564da00aab71cc93262d4cb21f239fffea195d05937fdf3489dc540b77d58d SHA512 8a7fe26a78071fdd8d4c9e2d9bf3791af8e0cb53b976b45d39dcab4ad08196808f416911fb1b366cc85e3fa80592ec79c4e4556bb3a390f4a10229b4bf9893f7 +DIST pipewire-0.3.32.tar.gz 1604622 SHA512 8a7fe26a78071fdd8d4c9e2d9bf3791af8e0cb53b976b45d39dcab4ad08196808f416911fb1b366cc85e3fa80592ec79c4e4556bb3a390f4a10229b4bf9893f7 +DIST pipewire-0.3.34.tar.gz 1682396 SHA512 cbf8eb410d2cd1923e67ac9ee9eca0e74567bb7e8ea407a536e64b3ec27b5bbb1e7fdd74a5a7cbffbac3f9996d8a08f8c723401fb44cb2920f044a3a2f3a6c18 diff --git a/media-video/pipewire/files/pipewire-0.3.33-revert-libfreeaptx-switch.patch b/media-video/pipewire/files/pipewire-0.3.33-revert-libfreeaptx-switch.patch new file mode 100644 index 00000000..94d4b7dc --- /dev/null +++ b/media-video/pipewire/files/pipewire-0.3.33-revert-libfreeaptx-switch.patch @@ -0,0 +1,38 @@ +commit f405a4e6069725934f9ae0f1b978497a34197d8d +Author: Thomas Deutschmann <whissi@gentoo.org> +AuthorDate: Tue Aug 24 14:22:36 2021 +0200 +Commit: Thomas Deutschmann <whissi@gentoo.org> +CommitDate: Tue Aug 24 14:22:43 2021 +0200 + + Revert "bluez5: Use libfreeaptx instead of libopenaptx" + + This reverts commit 1216371f8c06f548f8ade6468b66612f43df1436. + + Delay decision for now since both aptx libs haven't diverged yet. + +diff --git a/spa/meson.build b/spa/meson.build +index 483536b54..e13802e94 100644 +--- a/spa/meson.build ++++ b/spa/meson.build +@@ -28,7 +28,7 @@ if not get_option('spa-plugins').disabled() + summary({'LDAC': ldac_dep.found()}, bool_yn: true, section: 'Bluetooth audio codecs') + ldac_abr_dep = dependency('ldacBT-abr', required : get_option('bluez5-codec-ldac')) + summary({'LDAC ABR': ldac_abr_dep.found()}, bool_yn: true, section: 'Bluetooth audio codecs') +- aptx_dep = dependency('libfreeaptx', required : get_option('bluez5-codec-aptx')) ++ aptx_dep = dependency('libopenaptx', version : '< 0.2.1', required : get_option('bluez5-codec-aptx')) + summary({'aptX': aptx_dep.found()}, bool_yn: true, section: 'Bluetooth audio codecs') + fdk_aac_dep = dependency('fdk-aac', required : get_option('bluez5-codec-aac')) + summary({'AAC': fdk_aac_dep.found()}, bool_yn: true, section: 'Bluetooth audio codecs') +diff --git a/spa/plugins/bluez5/a2dp-codec-aptx.c b/spa/plugins/bluez5/a2dp-codec-aptx.c +index f8d7d6dd8..62ecde348 100644 +--- a/spa/plugins/bluez5/a2dp-codec-aptx.c ++++ b/spa/plugins/bluez5/a2dp-codec-aptx.c +@@ -32,7 +32,7 @@ + + #include <sbc/sbc.h> + +-#include <freeaptx.h> ++#include <openaptx.h> + + #include "defs.h" + #include "rtp.h" diff --git a/media-video/pipewire/metadata.xml b/media-video/pipewire/metadata.xml index f36452d6..0eeee3aa 100644 --- a/media-video/pipewire/metadata.xml +++ b/media-video/pipewire/metadata.xml @@ -19,16 +19,11 @@ <doc>https://gitlab.freedesktop.org/pipewire/pipewire/-/wikis/home</doc> </upstream> <use> - <flag name="aac">AAC over Bluetooth (iPhone compatible headphones)</flag> <flag name="alsa">Whether to depend on pulseaudio plugin for alsa when not using pipewire-alsa</flag> - <flag name="aptx">aptX (HD) over Bluetooth (many Android compatible headphones)</flag> + <flag name="echo-cancel">Enable WebRTC-based echo canceller via <pkg>media-libs/webrtc-audio-processing</pkg></flag> <flag name="extra">Build pw-cat/pw-play/pw-record</flag> - <flag name="ffmpeg">Builds an unsupported SPA (file a Gentoo bug if you need this)</flag> - <flag name="jack">Enable SPA JACK plugin and emulation to be able to run JACK applications on top of PipeWire</flag> <flag name="jack-client">Install a plugin for running PipeWire as a JACK client</flag> <flag name="jack-sdk">Use PipeWire as JACK replacement</flag> - <flag name="ldac">LDAC over Bluetooth (primarily Sony headphones)</flag> <flag name="pipewire-alsa">Replace PulseAudio's ALSA plugin with PipeWire's plugin</flag> - <flag name="vulkan">Uses Vulkan compute shaders to provide a CGI video source</flag> </use> </pkgmetadata> diff --git a/media-video/pipewire/pipewire-0.3.34.ebuild b/media-video/pipewire/pipewire-0.3.34.ebuild new file mode 100644 index 00000000..61dd49ce --- /dev/null +++ b/media-video/pipewire/pipewire-0.3.34.ebuild @@ -0,0 +1,275 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +PYTHON_COMPAT=( python3_{7..10} ) + +inherit meson-multilib optfeature python-any-r1 udev + +if [[ ${PV} == 9999 ]]; then + EGIT_REPO_URI="https://gitlab.freedesktop.org/${PN}/${PN}.git" + inherit git-r3 +else + SRC_URI="https://gitlab.freedesktop.org/${PN}/${PN}/-/archive/${PV}/${P}.tar.gz" + KEYWORDS="amd64 arm arm64 ~ppc ~ppc64 ~riscv x86" +fi + +DESCRIPTION="Multimedia processing graphs" +HOMEPAGE="https://pipewire.org/" + +LICENSE="MIT LGPL-2.1+ GPL-2" +SLOT="0/0.3" +IUSE="alsa bluetooth doc echo-cancel extra gstreamer jack-client jack-sdk pipewire-alsa systemd test v4l" + +# Once replacing system JACK libraries is possible, it's likely that +# jack-client IUSE will need blocking to avoid users accidentally +# configuring their systems to send PW sink output to the emulated +# JACK's sink - doing so is likely to yield no audio, cause a CPU +# cycles consuming loop (and may even cause GUI crashes)! + +REQUIRED_USE="jack-sdk? ( !jack-client )" + +RESTRICT="!test? ( test )" + +BDEPEND=" + app-doc/xmltoman + virtual/pkgconfig + ${PYTHON_DEPS} + doc? ( + app-doc/doxygen + media-gfx/graphviz + ) +" +RDEPEND=" + acct-group/audio + media-libs/alsa-lib + sys-apps/dbus[${MULTILIB_USEDEP}] + sys-libs/ncurses:=[unicode(+)] + virtual/libintl[${MULTILIB_USEDEP}] + virtual/libudev[${MULTILIB_USEDEP}] + bluetooth? ( + media-libs/fdk-aac + media-libs/libldac + media-libs/libopenaptx + media-libs/sbc + >=net-wireless/bluez-4.101:= + ) + echo-cancel? ( media-libs/webrtc-audio-processing ) + extra? ( + >=media-libs/libsndfile-1.0.20 + ) + gstreamer? ( + >=dev-libs/glib-2.32.0:2 + >=media-libs/gstreamer-1.10.0:1.0 + media-libs/gst-plugins-base:1.0 + ) + jack-client? ( >=media-sound/jack2-1.9.10:2[dbus] ) + jack-sdk? ( + !media-sound/jack-audio-connection-kit + !media-sound/jack2 + ) + pipewire-alsa? ( + >=media-libs/alsa-lib-1.1.7[${MULTILIB_USEDEP}] + || ( + media-plugins/alsa-plugins[-pulseaudio] + !media-plugins/alsa-plugins + ) + ) + !pipewire-alsa? ( alsa? ( media-plugins/alsa-plugins[${MULTILIB_USEDEP},pulseaudio] ) ) + systemd? ( sys-apps/systemd ) + v4l? ( media-libs/libv4l ) +" + +DEPEND="${RDEPEND}" + +# Present RDEPEND that are currently always disabled due to the PW +# code using them being required to be disabled by Gentoo guidelines +# (i.e. developer binaries not meant for users) and unready code +# media-video/ffmpeg:= +# media-libs/libsdl2 +# >=media-libs/vulkan-loader-1.1.69 +# +# Ditto for DEPEND +# >=dev-util/vulkan-headers-1.1.69 + +DOCS=( {README,INSTALL}.md NEWS ) + +PATCHES=( + "${FILESDIR}"/${PN}-0.3.25-enable-failed-mlock-warning.patch + "${FILESDIR}"/${PN}-0.3.33-revert-libfreeaptx-switch.patch + "${FILESDIR}"/${PN}-0.3.31-revert-openaptx-restriction.patch +) + +# limitsdfile related code taken from =sys-auth/realtime-base-0.1 +# with changes as necessary. +limitsdfile=40-${PN}.conf + +src_prepare() { + default + + if ! use systemd; then + # This can be applied non-conditionally but would make for a + # significantly worse user experience on systemd then. + eapply "${FILESDIR}"/${PN}-0.3.31-non-systemd-integration.patch + fi + + einfo "Generating ${limitsdfile}" + cat > ${limitsdfile} <<- EOF || die + # Start of ${limitsdfile} from ${P} + + @audio - memlock 256 + + # End of ${limitsdfile} from ${P} + EOF +} + +multilib_src_configure() { + local emesonargs=( + -Ddocdir="${EPREFIX}"/usr/share/doc/${PF} + $(meson_native_use_feature doc docs) + $(meson_native_enabled examples) # Disabling this implicitly disables -Dmedia-session + $(meson_native_enabled media-session) + $(meson_native_enabled man) + $(meson_feature test tests) + -Dinstalled_tests=disabled # Matches upstream; Gentoo never installs tests + $(meson_native_use_feature gstreamer) + $(meson_native_use_feature gstreamer gstreamer-device-provider) + $(meson_native_use_feature systemd) + -Dsystemd-system-service=disabled # Matches upstream + $(meson_native_use_feature systemd systemd-user-service) + $(meson_feature pipewire-alsa) # Allows integrating ALSA apps into PW graph + -Dspa-plugins=enabled + -Dalsa=enabled # Allows using kernel ALSA for sound I/O (-Dmedia-session depends on this) + -Daudiomixer=enabled # Matches upstream + -Daudioconvert=enabled # Matches upstream + $(meson_native_use_feature bluetooth bluez5) + $(meson_native_use_feature bluetooth bluez5-backend-hsp-native) + $(meson_native_use_feature bluetooth bluez5-backend-hfp-native) + $(meson_native_use_feature bluetooth bluez5-backend-ofono) + $(meson_native_use_feature bluetooth bluez5-backend-hsphfpd) + $(meson_native_use_feature bluetooth bluez5-codec-aac) + $(meson_native_use_feature bluetooth bluez5-codec-aptx) + $(meson_native_use_feature bluetooth bluez5-codec-ldac) + $(meson_native_use_feature echo-cancel echo-cancel-webrtc) #807889 + -Dcontrol=enabled # Matches upstream + -Daudiotestsrc=enabled # Matches upstream + -Dffmpeg=disabled # Disabled by upstream and no major developments to spa/plugins/ffmpeg/ since May 2020 + -Dpipewire-jack=enabled # Allows integrating JACK apps into PW graph + $(meson_native_use_feature jack-client jack) # Allows PW to act as a JACK client + $(meson_use jack-sdk jack-devel) + $(usex jack-sdk "-Dlibjack-path=${EPREFIX}/usr/$(get_libdir)" '') + -Dsupport=enabled # Miscellaneous/common plugins, such as null sink + -Devl=disabled # Matches upstream + -Dtest=disabled # fakesink and fakesource plugins + $(meson_native_use_feature v4l v4l2) + -Dlibcamera=disabled # libcamera is not in Portage tree + -Dvideoconvert=enabled # Matches upstream + -Dvideotestsrc=enabled # Matches upstream + -Dvolume=enabled # Matches upstream + -Dvulkan=disabled # Uses pre-compiled Vulkan compute shader to provide a CGI video source (dev thing; disabled by upstream) + $(meson_native_use_feature extra pw-cat) + -Dudev=enabled + -Dudevrulesdir="${EPREFIX}$(get_udevdir)/rules.d" + -Dsdl2=disabled # Controls SDL2 dependent code (currently only examples when -Dinstalled_tests=enabled which we never install) + $(meson_native_use_feature extra sndfile) # Enables libsndfile dependent code (currently only pw-cat) + ) + + meson_src_configure +} + +multilib_src_install() { + # Our customs DOCS do not exist in multilib source directory + DOCS= meson_src_install +} + +multilib_src_install_all() { + einstalldocs + + insinto /etc/security/limits.d + doins ${limitsdfile} + + if use pipewire-alsa; then + dodir /etc/alsa/conf.d + # These will break if someone has /etc that is a symbol link to a subfolder! See #724222 + # And the current dosym8 -r implementation is likely affected by the same issue, too. + dosym ../../../usr/share/alsa/alsa.conf.d/50-pipewire.conf /etc/alsa/conf.d/50-pipewire.conf + dosym ../../../usr/share/alsa/alsa.conf.d/99-pipewire-default.conf /etc/alsa/conf.d/99-pipewire-default.conf + fi + + if ! use systemd; then + insinto /etc/xdg/autostart + newins "${FILESDIR}"/pipewire.desktop pipewire.desktop + + exeinto /usr/libexec + newexe "${FILESDIR}"/pipewire-launcher.sh pipewire-launcher + fi +} + +pkg_postinst() { + elog "It is recommended to raise RLIMIT_MEMLOCK to 256 for users" + elog "using PipeWire. Do it either manually or add yourself" + elog "to the 'audio' group:" + elog + elog " usermod -aG audio <youruser>" + elog + + if ! use jack-sdk; then + elog "JACK emulation is incomplete and not all programs will work. PipeWire's" + elog "alternative libraries have been installed to a non-default location." + elog "To use them, put pw-jack <application> before every JACK application." + elog "When using pw-jack, do not run jackd/jackdbus. However, a virtual/jack" + elog "provider is still needed to compile the JACK applications themselves." + elog + fi + + if use systemd; then + elog "To use PipeWire for audio, the user units must be manually enabled:" + elog + elog " systemctl --user enable pipewire.socket pipewire-pulse.socket" + elog + elog "When switching from PulseAudio, do not forget to disable PulseAudio:" + elog + elog " systemctl --user disable pulseaudio.service pulseaudio.socket" + elog + elog "A reboot is recommended to avoid interferences from still running" + elog "PulseAudio daemon." + elog + elog "Both, new users and those upgrading, need to enable pipewire-media-session:" + elog + elog " systemctl --user enable pipewire-media-session.service" + elog + else + elog "This ebuild auto-enables PulseAudio replacement. Because of that, users" + elog "are recommended to edit: ${EROOT}/etc/pulse/client.conf and disable " + elog "autospawn'ing of the original daemon by setting:" + elog + elog " autospawn = no" + elog + elog "Please note that the semicolon (;) must _NOT_ be at the beginning of the line!" + elog + elog "Alternatively, if replacing PulseAudio daemon is not desired, edit" + elog "${EROOT}/etc/pipewire/pipewire.conf by commenting out the relevant" + elog "command near the end of the file:" + elog + elog "#\"/usr/bin/pipewire\" = { args = \"-c pipewire-pulse.conf\" }" + elog + elog "NOTE:" + elog "Starting with PipeWire-0.3.30, package is no longer installing config" + elog "into ${EROOT}/etc/pipewire by default. In case you need to change" + elog "config, please start by copying default config from ${EROOT}/usr/share/pipewire" + elog "and just override sections you want to change." + fi + + elog "For latest tips and tricks, troubleshooting information and documentation" + elog "in general, please refer to https://wiki.gentoo.org/wiki/PipeWire" + elog + + optfeature_header "The following can be installed for optional runtime features:" + optfeature "restricted realtime capabilities vai D-Bus" sys-auth/rtkit + # Once hsphfpd lands in tree, both it and ofono will need to be checked for presence here! + if use bluetooth; then + optfeature "better BT headset support (daemon startup required)" net-misc/ofono + #optfeature "an oFono alternative (not packaged)" foo-bar/hsphfpd + fi +} diff --git a/metadata/pkg_desc_index b/metadata/pkg_desc_index index 19492cca..26ad45a3 100644 --- a/metadata/pkg_desc_index +++ b/metadata/pkg_desc_index @@ -25,7 +25,6 @@ app-portage/changelog-gitrepo 1.1: Create ChangeLog data for gentoo repositories app-portage/eix 0.35.3_alpha210825 0.35.3 99999999: Search and query ebuilds app-portage/etcat 1.0.2 99999999: Updated version of an old Portage information extractor app-portage/find_cruft 5.2: find cruft files not managed by portage -app-portage/getdelta 0.7.9-r2: dynamic deltup client app-portage/logclean 18.4.1: Keep only (compressed) logs of installed packages and cleanup emerge.log app-portage/portage-bashrc-mv 20.3: Provide support for /etc/portage/bashrc.d and /etc/portage/package.cflags app-portage/portage-postsyncd-mv 8.4: postsync hooks for portage to sync from git @@ -85,7 +84,7 @@ media-tv/w_scan 20170107-r1: Scan for DVB-C/DVB-T/DVB-S channels without prior k media-video/avidemux 2.7.8: Video editor designed for simple cutting, filtering and encoding tasks media-video/avinfo 1.0_alpha15_p1-r1: Utility for displaying AVI information media-video/handbrake 1.3.3-r1: Open-source, GPL-licensed, multiplatform, multithreaded video transcoder -media-video/pipewire 0.3.32: Multimedia processing graphs +media-video/pipewire 0.3.32 0.3.34: Multimedia processing graphs media-video/video-mv 17.1: Frontends for using mplayer/mencoder, ffmpeg/libav, or tzap as video recorder net-dialup/accounting 1.60.45.3.1-r1: Give statistics about dialup connections. Originally part of SuSE's smpppd net-dialup/martian-modem 20100123-r3: ltmodem alternative driver providing support for Agere Systems winmodems diff --git a/profiles/use.local.desc b/profiles/use.local.desc index 4b369f5b..ca84c5b5 100644 --- a/profiles/use.local.desc +++ b/profiles/use.local.desc @@ -197,17 +197,12 @@ media-video/handbrake:libav-aac - Support for encoding AAC using libav's interna media-video/handbrake:numa - Adds support for x265's NUMA capabilities. media-video/handbrake:nvenc - Adds support for NVIDIA Encoder (NVENC) API for hardware accelerated encoding on NVIDIA cards. media-video/handbrake:x265 - Support for encoding h265 using media-libs/x265. -media-video/pipewire:aac - AAC over Bluetooth (iPhone compatible headphones) media-video/pipewire:alsa - Whether to depend on pulseaudio plugin for alsa when not using pipewire-alsa -media-video/pipewire:aptx - aptX (HD) over Bluetooth (many Android compatible headphones) +media-video/pipewire:echo-cancel - Enable WebRTC-based echo canceller via media-libs/webrtc-audio-processing media-video/pipewire:extra - Build pw-cat/pw-play/pw-record -media-video/pipewire:ffmpeg - Builds an unsupported SPA (file a Gentoo bug if you need this) -media-video/pipewire:jack - Enable SPA JACK plugin and emulation to be able to run JACK applications on top of PipeWire media-video/pipewire:jack-client - Install a plugin for running PipeWire as a JACK client media-video/pipewire:jack-sdk - Use PipeWire as JACK replacement -media-video/pipewire:ldac - LDAC over Bluetooth (primarily Sony headphones) media-video/pipewire:pipewire-alsa - Replace PulseAudio's ALSA plugin with PipeWire's plugin -media-video/pipewire:vulkan - Uses Vulkan compute shaders to provide a CGI video source net-dns/noip-updater:ezipupd - Use user/group ezipupd instead of nobody: Useful if you restrict outgoing network traffic for user nobody net-print/foo2zjs:foomaticdb - Add support for the foomatic printing driver database sci-geosciences/googleearth:bundled-libs - Use bundled libraries. |