From ceeeb463cc1eef97fd62eaee8bf2196ba04bc384 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 29 Feb 2020 18:01:47 +0000 Subject: gentoo (leap year) resync : 29.02.2020 --- eclass/Manifest.gz | Bin 36459 -> 36295 bytes eclass/acct-user.eclass | 10 ++++++++ eclass/distutils-r1.eclass | 29 +++++++++++++++++++++++ eclass/eapi7-ver.eclass | 8 +++---- eclass/elisp-common.eclass | 14 ++++------- eclass/elisp.eclass | 4 ++-- eclass/epunt-cxx.eclass | 51 ---------------------------------------- eclass/libretro-core.eclass | 12 +++++----- eclass/php-ext-source-r3.eclass | 2 +- eclass/portability.eclass | 4 ++-- eclass/postgres-multi.eclass | 8 +++---- eclass/postgres.eclass | 6 ++--- eclass/savedconfig.eclass | 20 ++++++++-------- eclass/tests/python-utils-r1.sh | 6 +++++ eclass/texlive-module.eclass | 6 ++++- eclass/toolchain.eclass | 11 ++++++++- eclass/user.eclass | 42 ++++++++++++++++----------------- eclass/vdr-plugin-2.eclass | 21 +++++++---------- 18 files changed, 126 insertions(+), 128 deletions(-) delete mode 100644 eclass/epunt-cxx.eclass (limited to 'eclass') diff --git a/eclass/Manifest.gz b/eclass/Manifest.gz index 98c03602c807..2794fb0adf40 100644 Binary files a/eclass/Manifest.gz and b/eclass/Manifest.gz differ diff --git a/eclass/acct-user.eclass b/eclass/acct-user.eclass index be6b3dd3e600..e3ec3966035d 100644 --- a/eclass/acct-user.eclass +++ b/eclass/acct-user.eclass @@ -360,6 +360,11 @@ acct-user_pkg_preinst() { acct-user_pkg_postinst() { debug-print-function ${FUNCNAME} "${@}" + if [[ ${EUID} != 0 ]] ; then + einfo "Insufficient privileges to execute ${FUNCNAME[0]}" + return 0 + fi + # NB: eset* functions check current value esethome "${ACCT_USER_NAME}" "${ACCT_USER_HOME}" esetshell "${ACCT_USER_NAME}" "${ACCT_USER_SHELL}" @@ -376,6 +381,11 @@ acct-user_pkg_postinst() { acct-user_pkg_prerm() { debug-print-function ${FUNCNAME} "${@}" + if [[ ${EUID} != 0 ]] ; then + einfo "Insufficient privileges to execute ${FUNCNAME[0]}" + return 0 + fi + if [[ -z ${REPLACED_BY_VERSION} ]]; then if [[ -z $(egetent passwd "${ACCT_USER_NAME}") ]]; then ewarn "User account not found: ${ACCT_USER_NAME}" diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass index e546aadfa4a7..27ca236ccf5f 100644 --- a/eclass/distutils-r1.eclass +++ b/eclass/distutils-r1.eclass @@ -86,6 +86,8 @@ esac # - no -- do not add the dependency (pure distutils package) # - bdepend -- add it to BDEPEND (the default) # - rdepend -- add it to BDEPEND+RDEPEND (when using entry_points) +# - pyproject.toml -- use pyproject2setuptools to install a project +# using pyproject.toml (flit, poetry...) # - manual -- do not add the depedency and suppress the checks # (assumes you will take care of doing it correctly) # @@ -135,6 +137,9 @@ _distutils_set_globals() { bdep+=" ${sdep}" rdep+=" ${sdep}" ;; + pyproject.toml) + bdep+=" dev-python/pyproject2setuppy[${PYTHON_USEDEP}]" + ;; *) die "Invalid DISTUTILS_USE_SETUPTOOLS=${DISTUTILS_USE_SETUPTOOLS}" ;; @@ -457,6 +462,7 @@ distutils_enable_tests() { _distutils_verify_use_setuptools() { [[ ${DISTUTILS_OPTIONAL} ]] && return [[ ${DISTUTILS_USE_SETUPTOOLS} == manual ]] && return + [[ ${DISTUTILS_USE_SETUPTOOLS} == pyproject.toml ]] && return # ok, those are cheap greps. we can try toimprove them if we hit # false positives. @@ -580,6 +586,28 @@ _distutils-r1_disable_ez_setup() { fi } +# @FUNCTION: _distutils-r1_handle_pyproject_toml +# @INTERNAL +# @DESCRIPTION: +# Generate setup.py for pyproject.toml if requested. +_distutils-r1_handle_pyproject_toml() { + if [[ ! -f setup.py && -f pyproject.toml ]]; then + if [[ ${DISTUTILS_USE_SETUPTOOLS} == pyproject.toml ]]; then + cat > setup.py <<-EOF || die + #!/usr/bin/env python + from pyproject2setuppy.main import main + main() + EOF + chmod +x setup.py || die + else + eerror "No setup.py found but pyproject.toml is present. In order to enable" + eerror "pyproject.toml support in distutils-r1, set:" + eerror " DISTUTILS_USE_SETUPTOOLS=pyproject.toml" + die "No setup.py found and DISTUTILS_USE_SETUPTOOLS!=pyproject.toml" + fi + fi +} + # @FUNCTION: distutils-r1_python_prepare_all # @DESCRIPTION: # The default python_prepare_all(). It applies the patches from PATCHES @@ -608,6 +636,7 @@ distutils-r1_python_prepare_all() { fi _distutils-r1_disable_ez_setup + _distutils-r1_handle_pyproject_toml if [[ ${DISTUTILS_IN_SOURCE_BUILD} && ! ${DISTUTILS_SINGLE_IMPL} ]] then diff --git a/eclass/eapi7-ver.eclass b/eclass/eapi7-ver.eclass index b7f9715bc421..8f13fc9af762 100644 --- a/eclass/eapi7-ver.eclass +++ b/eclass/eapi7-ver.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2018 Gentoo Foundation +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 # @ECLASS: eapi7-ver.eclass @@ -17,8 +17,7 @@ # # https://bugs.gentoo.org/482170 # -# @ROFF .SS -# Version strings +# @SUBSECTION Version strings # # The functions support arbitrary version strings consisting of version # components interspersed with (possibly empty) version separators. @@ -50,8 +49,7 @@ # 0 1 1 # @CODE # -# @ROFF .SS -# Ranges +# @SUBSECTION Ranges # # A range can be specified as 'm' for m-th version component, 'm-' # for all components starting with m-th or 'm-n' for components starting diff --git a/eclass/elisp-common.eclass b/eclass/elisp-common.eclass index b5ea21cb22bf..6fa2bbea614b 100644 --- a/eclass/elisp-common.eclass +++ b/eclass/elisp-common.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2019 Gentoo Authors +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 # @ECLASS: elisp-common.eclass @@ -43,8 +43,7 @@ # Please note that this should be done only for packages that are known # to fail with lower Emacs versions. # -# @ROFF .SS -# src_compile() usage: +# @SUBSECTION src_compile() usage: # # An elisp file is compiled by the elisp-compile() function defined # here and simply takes the source files as arguments. The case of @@ -64,8 +63,7 @@ # comments. See the Emacs Lisp Reference Manual (node "Autoload") for # a detailed explanation. # -# @ROFF .SS -# src_install() usage: +# @SUBSECTION src_install() usage: # # The resulting compiled files (.elc) should be put in a subdirectory of # /usr/share/emacs/site-lisp/ which is named after the first argument @@ -132,8 +130,7 @@ # "50${PN}-gentoo.el". If your subdirectory is not named ${PN}, give # the differing name as second argument. # -# @ROFF .SS -# pkg_setup() usage: +# @SUBSECTION pkg_setup() usage: # # If your ebuild uses the elisp-compile eclass function to compile # its elisp files (see above), then you don't need a pkg_setup phase, @@ -149,8 +146,7 @@ # When having optional Emacs support, you should prepend "use emacs &&" # to above call of elisp-check-emacs-version(). # -# @ROFF .SS -# pkg_postinst() / pkg_postrm() usage: +# @SUBSECTION pkg_postinst() / pkg_postrm() usage: # # After that you need to recreate the start-up file of Emacs after # emerging and unmerging by using diff --git a/eclass/elisp.eclass b/eclass/elisp.eclass index a411f602cf7c..7876928c7fb2 100644 --- a/eclass/elisp.eclass +++ b/eclass/elisp.eclass @@ -1,4 +1,4 @@ -# Copyright 2002-2019 Gentoo Authors +# Copyright 2002-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 # @ECLASS: elisp.eclass @@ -173,7 +173,7 @@ elisp_src_install() { # install documentation only when explicitly requested case ${EAPI} in 4|5) [[ -n ${DOCS} ]] && dodoc ${DOCS} ;; - *) declare -p DOCS &>/dev/null && einstalldocs ;; + *) [[ $(declare -p DOCS 2>/dev/null) == *=* ]] && einstalldocs ;; esac if declare -f readme.gentoo_create_doc >/dev/null; then readme.gentoo_create_doc diff --git a/eclass/epunt-cxx.eclass b/eclass/epunt-cxx.eclass deleted file mode 100644 index 91406ed86f05..000000000000 --- a/eclass/epunt-cxx.eclass +++ /dev/null @@ -1,51 +0,0 @@ -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -# @DEAD -# No consumers, this eclass is not useful anymore, as a functioning -# C++ compiler is required nowadays. Removal in 15 days. - -# @ECLASS: epunt-cxx.eclass -# @MAINTAINER: -# base-system@gentoo.org -# @BLURB: A function to punt C++ compiler checks from autoconf -# @DESCRIPTION: -# Support for punting C++ compiler checks from autoconf (based -# on ELT-patches). - -if [[ -z ${_EPUNT_CXX_ECLASS} ]]; then - -# eutils for eqawarn -inherit eutils - -DEPEND=">=app-portage/elt-patches-20170317" - -# @FUNCTION: epunt_cxx -# @USAGE: [dir to scan] -# @DESCRIPTION: -# Many configure scripts wrongly bail when a C++ compiler could not be -# detected. If dir is not specified, then it defaults to ${S}. -# -# https://bugs.gentoo.org/73450 -epunt_cxx() { - local dir=$1 - [[ -z ${dir} ]] && dir=${S} - ebegin "Removing useless C++ checks" - local f p any_found - while IFS= read -r -d '' f; do - for p in "${EPREFIX}/usr/share/elt-patches"/nocxx/*.patch ; do - if patch --no-backup-if-mismatch -p1 "${f}" "${p}" >/dev/null ; then - any_found=1 - break - fi - done - done < <(find "${dir}" -name configure -print0) - - if [[ -z ${any_found} ]]; then - eqawarn "epunt_cxx called unnecessarily (no C++ checks to punt)." - fi - eend 0 -} - -_EPUNT_CXX_ECLASS=1 -fi #_EPUNT_CXX_ECLASS diff --git a/eclass/libretro-core.eclass b/eclass/libretro-core.eclass index 768c4701827b..f5f63065f223 100644 --- a/eclass/libretro-core.eclass +++ b/eclass/libretro-core.eclass @@ -126,12 +126,12 @@ libretro-core_src_prepare() { # * Add short-rev to Makefile sed \ -e 's/\r$//g' \ - -e "/flags.*=/s:-O[[:digit:]]:${CFLAGS}:g" \ - -e "/CFLAGS.*=/s:-O[[:digit:]]:${CFLAGS}:g" \ - -e "/CXXFLAGS.*=/s:-O[[:digit:]]:${CXXFLAGS}:g" \ - -e "/.*,--version-script=.*/s:$: ${LDFLAGS} ${LIBS}:g" \ - -e "/\$(CC)/s:\(\$(SHARED)\):\1 ${LDFLAGS} ${LIBS}:" \ - -e 's:\(\$(CC)\):\1 \$(CFLAGS):g' \ + -e "/flags.*=/s|-O[[:digit:]]|${CFLAGS}|g" \ + -e "/CFLAGS.*=/s|-O[[:digit:]]|${CFLAGS}|g" \ + -e "/CXXFLAGS.*=/s|-O[[:digit:]]|${CXXFLAGS}|g" \ + -e "/.*,--version-script=.*/s|$| ${LDFLAGS} ${LIBS}|g" \ + -e "/\$(CC)/s|\(\$(SHARED)\)|\1 ${LDFLAGS} ${LIBS}|" \ + -e 's|\(\$(CC)\)|\1 \$(CFLAGS)|g' \ -e "s/GIT_VERSION\s.=.*$/GIT_VERSION=${custom_libretro_commit_sha}/g" \ -i "${makefile}" || die "Failed to use custom cflags in ${makefile}" done diff --git a/eclass/php-ext-source-r3.eclass b/eclass/php-ext-source-r3.eclass index 385bdb9dae0b..12e4a24facd6 100644 --- a/eclass/php-ext-source-r3.eclass +++ b/eclass/php-ext-source-r3.eclass @@ -366,7 +366,7 @@ php-ext-source-r3_createinifiles() { inidir="${file/${PHP_INI_NAME}.ini/}" inidir="${inidir/ext/ext-active}" dodir "/${inidir}" - dosym "/${file}" "/${file/ext/ext-active}" + dosym "../ext/${PHP_INI_NAME}.ini" "/${file/ext/ext-active}" done done diff --git a/eclass/portability.eclass b/eclass/portability.eclass index c56f03fb8763..1402c0420cb0 100644 --- a/eclass/portability.eclass +++ b/eclass/portability.eclass @@ -67,8 +67,8 @@ seq() { # Screw it, do the output ourselves while :; do - [[ $max < $min && $step > 0 ]] && break - [[ $min < $max && $step < 0 ]] && break + [[ $max -lt $min && $step -gt 0 ]] && break + [[ $min -lt $max && $step -gt 0 ]] && break echo $min : $(( min += step )) done diff --git a/eclass/postgres-multi.eclass b/eclass/postgres-multi.eclass index 48ef79dc2925..49d5c6a9c684 100644 --- a/eclass/postgres-multi.eclass +++ b/eclass/postgres-multi.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 inherit multibuild postgres @@ -9,7 +9,7 @@ EXPORT_FUNCTIONS pkg_setup src_prepare src_compile src_install src_test # @MAINTAINER: # PostgreSQL # @AUTHOR: Aaron W. Swenson -# @SUPPORTED_EAPIS: 5 6 +# @SUPPORTED_EAPIS: 5 6 7 # @BLURB: An eclass to build PostgreSQL-related packages against multiple slots # @DESCRIPTION: # postgres-multi enables ebuilds, particularly PostgreSQL extensions, to @@ -18,7 +18,7 @@ EXPORT_FUNCTIONS pkg_setup src_prepare src_compile src_install src_test case ${EAPI:-0} in - 5|6) ;; + 5|6|7) ;; *) die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}" ;; esac @@ -146,7 +146,7 @@ postgres-multi_src_prepare() { case ${EAPI:-0} in 0|1|2|3|4|5) epatch_user ;; - 6) eapply_user ;; + 6|7) eapply_user ;; esac local MULTIBUILD_VARIANT diff --git a/eclass/postgres.eclass b/eclass/postgres.eclass index ce8b6e3a992d..fd12245bb460 100644 --- a/eclass/postgres.eclass +++ b/eclass/postgres.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2019 Gentoo Authors +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 inherit user @@ -8,7 +8,7 @@ EXPORT_FUNCTIONS pkg_setup # @MAINTAINER: # PostgreSQL # @AUTHOR: Aaron W. Swenson -# @SUPPORTED_EAPIS: 5 6 +# @SUPPORTED_EAPIS: 5 6 7 # @BLURB: An eclass for PostgreSQL-related packages # @DESCRIPTION: # This eclass provides common utility functions that many @@ -18,7 +18,7 @@ EXPORT_FUNCTIONS pkg_setup case ${EAPI:-0} in - 5|6) ;; + 5|6|7) ;; *) die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}" ;; esac diff --git a/eclass/savedconfig.eclass b/eclass/savedconfig.eclass index 8f64c5b8edd0..e90a9b618d6b 100644 --- a/eclass/savedconfig.eclass +++ b/eclass/savedconfig.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2019 Gentoo Authors +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 # @ECLASS: savedconfig.eclass @@ -14,21 +14,21 @@ # so users can modify these config files and the ebuild will take it # into account as needed. # -# @ROFF .nr R 1 1 # Typically you can create your own configuration files quickly by # doing: -# @ROFF .IP \nR 3 -# Build the package with FEATURES=noclean USE=savedconfig. -# @ROFF .IP \n+R -# Go into the build dir and edit the relevant configuration system +# +# 1. Build the package with FEATURES=noclean USE=savedconfig. +# +# 2. Go into the build dir and edit the relevant configuration system # (e.g. `make menuconfig` or `nano config-header.h`). You can look # at the files in /etc/portage/savedconfig/ to see what files get # loaded/restored. -# @ROFF .IP \n+R -# Copy the modified configuration files out of the workdir and to +# +# 3. Copy the modified configuration files out of the workdir and to # the paths in /etc/portage/savedconfig/. -# @ROFF .IP \n+R -# Emerge the package with just USE=savedconfig to get the custom build. +# +# 4. Emerge the package with just USE=savedconfig to get the custom +# build. inherit portability diff --git a/eclass/tests/python-utils-r1.sh b/eclass/tests/python-utils-r1.sh index 279324e163ba..4367890a08a1 100755 --- a/eclass/tests/python-utils-r1.sh +++ b/eclass/tests/python-utils-r1.sh @@ -67,6 +67,8 @@ if [[ -x /usr/bin/python2.7 ]]; then test_var PYTHON_INCLUDEDIR python2_7 /usr/include/python2.7 test_var PYTHON_LIBPATH python2_7 "/usr/lib*/libpython2.7$(get_libname)" test_var PYTHON_CONFIG python2_7 /usr/bin/python2.7-config + test_var PYTHON_CFLAGS python2_7 "*-I/usr/include/python2.7*" + test_var PYTHON_LIBS python2_7 "*-lpython2.7*" fi test_var PYTHON_PKG_DEP python2_7 '*dev-lang/python*:2.7' test_var PYTHON_SCRIPTDIR python2_7 /usr/lib/python-exec/python2.7 @@ -79,6 +81,8 @@ if [[ -x /usr/bin/python3.6 ]]; then test_var PYTHON_INCLUDEDIR python3_6 "/usr/include/python3.6${abiflags}" test_var PYTHON_LIBPATH python3_6 "/usr/lib*/libpython3.6${abiflags}$(get_libname)" test_var PYTHON_CONFIG python3_6 "/usr/bin/python3.6${abiflags}-config" + test_var PYTHON_CFLAGS python3_6 "*-I/usr/include/python3.6*" + test_var PYTHON_LIBS python3_6 "*-lpython3.6*" fi test_var PYTHON_PKG_DEP python3_6 '*dev-lang/python*:3.6' test_var PYTHON_SCRIPTDIR python3_6 /usr/lib/python-exec/python3.6 @@ -91,6 +95,8 @@ if [[ -x /usr/bin/python3.7 ]]; then test_var PYTHON_INCLUDEDIR python3_7 "/usr/include/python3.7${abiflags}" test_var PYTHON_LIBPATH python3_7 "/usr/lib*/libpython3.7${abiflags}$(get_libname)" test_var PYTHON_CONFIG python3_7 "/usr/bin/python3.7${abiflags}-config" + test_var PYTHON_CFLAGS python3_7 "*-I/usr/include/python3.7*" + test_var PYTHON_LIBS python3_7 "*-lpython3.7*" fi test_var PYTHON_PKG_DEP python3_7 '*dev-lang/python*:3.7' test_var PYTHON_SCRIPTDIR python3_7 /usr/lib/python-exec/python3.7 diff --git a/eclass/texlive-module.eclass b/eclass/texlive-module.eclass index 3f31f35e1abb..5c4dec838d77 100644 --- a/eclass/texlive-module.eclass +++ b/eclass/texlive-module.eclass @@ -163,7 +163,11 @@ texlive-module_add_format() { local name engine mode patterns options eval $@ einfo "Appending to format.${PN}.cnf for $@" - [[ -d texmf-dist/fmtutil ]] || mkdir -p texmf-dist/fmtutil || die + + if [[ ! -d texmf-dist/fmtutil ]]; then + mkdir -p texmf-dist/fmtutil || die + fi + [[ -f texmf-dist/fmtutil/format.${PN}.cnf ]] || { echo "# Generated for ${PN} by texlive-module.eclass" > texmf-dist/fmtutil/format.${PN}.cnf; } [[ -n ${TEXLIVE_MODULE_OPTIONAL_ENGINE} ]] && has ${engine} ${TEXLIVE_MODULE_OPTIONAL_ENGINE} && use !${engine} && mode="disabled" if [[ ${mode} = disabled ]]; then diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass index 90f7b68312bb..62520ae92dff 100644 --- a/eclass/toolchain.eclass +++ b/eclass/toolchain.eclass @@ -20,7 +20,7 @@ if tc_is_live ; then # Note that the micro version is required or lots of stuff will break. # To checkout master set gcc_LIVE_BRANCH="master" in the ebuild before # inheriting this eclass. - EGIT_BRANCH="${PN}-${PV%.?.?_pre9999}-branch" + EGIT_BRANCH="releases/${PN}-${PV%.?.?_pre9999}" EGIT_BRANCH=${EGIT_BRANCH//./_} inherit git-r3 fi @@ -192,6 +192,7 @@ if [[ ${PN} != "kgcc64" && ${PN} != gcc-* ]] ; then IUSE+=" systemtap" TC_FEATURES+=(systemtap) tc_version_is_at_least 9.0 && IUSE+=" d" tc_version_is_at_least 9.1 && IUSE+=" lto" + tc_version_is_at_least 10 && IUSE+=" zstd" TC_FEATURES+=(zstd) fi if tc_version_is_at_least 10; then @@ -259,6 +260,10 @@ if tc_has_feature systemtap ; then DEPEND+=" systemtap? ( dev-util/systemtap )" fi +if tc_has_feature zstd ; then + DEPEND+=" zstd? ( app-arch/zstd )" +fi + PDEPEND=">=sys-devel/gcc-config-1.7" #---->> S + SRC_URI essentials <<---- @@ -1273,6 +1278,10 @@ toolchain_src_configure() { ) fi + if in_iuse zstd ; then + confgcc+=( $(use_with zstd) ) + fi + # newer gcc's come with libquadmath, but only fortran uses # it, so auto punt it when we don't care if tc_version_is_at_least 4.6 && ! is_fortran ; then diff --git a/eclass/user.eclass b/eclass/user.eclass index 9bd0b607eab8..b70698356a3a 100644 --- a/eclass/user.eclass +++ b/eclass/user.eclass @@ -68,7 +68,7 @@ user_get_nologin() { # exist. enewuser() { if [[ ${EUID} != 0 ]] ; then - einfo "Insufficient privileges to execute ${FUNCNAME[0]}" + ewarn "Insufficient privileges to execute ${FUNCNAME[0]}" return 0 fi _assert_pkg_ebuild_phase ${FUNCNAME} @@ -94,7 +94,7 @@ enewuser() { if [[ -n $(egetent passwd "${euser}") ]] ; then return 0 fi - einfo "Adding user '${euser}' to your system ..." + elog "Adding user '${euser}' to your system ..." # options to pass to useradd local opts=() @@ -122,7 +122,7 @@ enewuser() { [[ ${euid} -ge 101 ]] || die "${FUNCNAME}: no free UID found" fi opts+=( -u ${euid} ) - einfo " - Userid: ${euid}" + elog " - Userid: ${euid}" # handle shell local eshell=$1; shift @@ -138,7 +138,7 @@ enewuser() { else eshell=$(user_get_nologin) fi - einfo " - Shell: ${eshell}" + elog " - Shell: ${eshell}" opts+=( -s "${eshell}" ) # handle homedir @@ -146,7 +146,7 @@ enewuser() { if [[ -z ${ehome} ]] || [[ ${ehome} == "-1" ]] ; then ehome="/dev/null" fi - einfo " - Home: ${ehome}" + elog " - Home: ${ehome}" opts+=( -d "${ehome}" ) # handle groups @@ -171,7 +171,7 @@ enewuser() { opts+=( -G "${exgroups:1}" ) fi fi - einfo " - Groups: ${egroups:-(none)}" + elog " - Groups: ${egroups:-(none)}" # handle extra args if [[ $# -gt 0 ]] ; then @@ -179,7 +179,7 @@ enewuser() { else local comment="added by portage for ${PN}" opts+=( -c "${comment}" ) - einfo " - GECOS: ${comment}" + elog " - GECOS: ${comment}" fi # add the user @@ -204,7 +204,7 @@ enewuser() { esac if [[ -n ${create_home} && ! -e ${ROOT}/${ehome} ]] ; then - einfo " - Creating ${ehome} in ${ROOT}" + elog " - Creating ${ehome} in ${ROOT}" mkdir -p "${ROOT}/${ehome}" chown "${euser}" "${ROOT}/${ehome}" chmod 755 "${ROOT}/${ehome}" @@ -223,7 +223,7 @@ enewuser() { # can not be assigned. enewgroup() { if [[ ${EUID} != 0 ]] ; then - einfo "Insufficient privileges to execute ${FUNCNAME[0]}" + ewarn "Insufficient privileges to execute ${FUNCNAME[0]}" return 0 fi _assert_pkg_ebuild_phase ${FUNCNAME} @@ -248,11 +248,11 @@ enewgroup() { if [[ -n $(egetent group "${egroup}") ]] ; then return 0 fi - einfo "Adding group '${egroup}' to your system ..." + elog "Adding group '${egroup}' to your system ..." # handle gid local egid=$1; shift - if [[ ! -z ${egid} ]] ; then + if [[ -n ${egid} && ${egid} != -1 ]] ; then if [[ ${egid} -gt 0 ]] ; then if [[ -n $(egetent group ${egid}) ]] ; then [[ -n ${force_gid} ]] && die "${FUNCNAME}: GID ${egid} already taken" @@ -266,7 +266,7 @@ enewgroup() { [[ -n ${force_gid} ]] && die "${FUNCNAME}: -F with gid==-1 makes no sense" egid="next available" fi - einfo " - Groupid: ${egid}" + elog " - Groupid: ${egid}" # handle extra if [[ $# -gt 0 ]] ; then @@ -351,12 +351,12 @@ esethome() { return 0 fi - einfo "Updating home for user '${euser}' ..." - einfo " - Home: ${ehome}" + elog "Updating home for user '${euser}' ..." + elog " - Home: ${ehome}" # ensure home directory exists, otherwise update will fail if [[ ! -e ${ROOT}/${ehome} ]] ; then - einfo " - Creating ${ehome} in ${ROOT}" + elog " - Creating ${ehome} in ${ROOT}" mkdir -p "${ROOT}/${ehome}" chown "${euser}" "${ROOT}/${ehome}" chmod 755 "${ROOT}/${ehome}" @@ -420,8 +420,8 @@ esetshell() { return 0 fi - einfo "Updating shell for user '${euser}' ..." - einfo " - Shell: ${eshell}" + elog "Updating shell for user '${euser}' ..." + elog " - Shell: ${eshell}" # update the shell case ${CHOST} in @@ -476,8 +476,8 @@ esetcomment() { return 0 fi - einfo "Updating comment for user '${euser}' ..." - einfo " - Comment: ${ecomment}" + elog "Updating comment for user '${euser}' ..." + elog " - Comment: ${ecomment}" # update the comment case ${CHOST} in @@ -546,8 +546,8 @@ esetgroups() { fi local opts=( -g "${defgroup}" -G "${exgroups}" ) - einfo "Updating groups for user '${euser}' ..." - einfo " - Groups: ${egroups}" + elog "Updating groups for user '${euser}' ..." + elog " - Groups: ${egroups}" # update the group case ${CHOST} in diff --git a/eclass/vdr-plugin-2.eclass b/eclass/vdr-plugin-2.eclass index 67ccb1e6ab11..ebd1e39e5af6 100644 --- a/eclass/vdr-plugin-2.eclass +++ b/eclass/vdr-plugin-2.eclass @@ -9,7 +9,7 @@ # Joerg Bornkessel # Christian Ruppert # (undisclosed contributors) -# @SUPPORTED_EAPIS: 4 5 6 7 +# @SUPPORTED_EAPIS: 5 6 7 # @BLURB: common vdr plugin ebuild functions # @DESCRIPTION: # Eclass for easing maintenance of vdr plugin ebuilds @@ -78,7 +78,7 @@ # Applying your own local/user patches: # This is done by using the -# (EAPI = 4,5) epatch_user() function of the eutils.eclass, +# (EAPI = 5) epatch_user() function of the eutils.eclass, # (EAPI = 6,7) eapply_user function integrated in EAPI = 6. # Simply add your patches into one of these directories: # /etc/portage/patches/// @@ -87,12 +87,12 @@ # # For more details about it please take a look at the eutils.class. -[[ ${EAPI} == [45] ]] && inherit multilib -[[ ${EAPI} == [456] ]] && inherit eutils +[[ ${EAPI} == [5] ]] && inherit multilib +[[ ${EAPI} == [56] ]] && inherit eutils inherit flag-o-matic toolchain-funcs unpacker case ${EAPI:-0} in - 4|5|6|7) + 5|6|7) ;; *) die "EAPI ${EAPI} unsupported." ;; @@ -355,10 +355,7 @@ vdr-plugin-2_pkg_setup() { # Plugins need to be compiled with position independent code, otherwise linking # VDR against it will fail - # depricated if fi, as we have only >=vdr-2 in the tree, fix me later... - if has_version ">=media-video/vdr-1.7.13"; then - append-cxxflags -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE - fi + append-cxxflags -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE # Where should the plugins live in the filesystem VDR_PLUGIN_DIR=$(pkg-config --variable=libdir vdr) @@ -418,7 +415,7 @@ vdr-plugin-2_src_util() { ;; add_local_patch) cd "${S}" || die "Could not change to plugin-source-directory (src_util)" - if [[ ${EAPI} != [45] ]]; then + if [[ ${EAPI} != [5] ]]; then eapply_user else epatch_user @@ -465,8 +462,8 @@ vdr-plugin-2_src_prepare() { die "vdr-plugin-2_src_prepare not called!" fi - [[ ${EAPI} == [45] ]] && [[ ${PATCHES[@]} ]] && epatch "${PATCHES[@]}" - [[ ${EAPI} != [45] ]] && [[ ${PATCHES[@]} ]] && eapply "${PATCHES[@]}" + [[ ${EAPI} == [5] ]] && [[ ${PATCHES[@]} ]] && epatch "${PATCHES[@]}" + [[ ${EAPI} != [5] ]] && [[ ${PATCHES[@]} ]] && eapply "${PATCHES[@]}" debug-print "$FUNCNAME: applying user patches" -- cgit v1.2.3